Hi, I want to make a logfile where i store all tables, collnames and values of a specified database. Which statement can I use in SQLserver or Oracle? I already found the following statements:
Oracle:
select * from all_tables
select * from user_tables
SQLserver:
select * from sysobjects where type'='U'
So getting the tablenames isn't the problem. The question is how the get the matching columns with their type and value.
Tnx.try this one
select sysobjects.name as Table_Name,syscolumns.name as Column_Name,systypes.name as Data_Type from sysobjects
join syscolumns on sysobjects.id=syscolumns.id
join systypes on syscolumns.xtype=systypes.xtype and systypes.status=typestat
where sysobjects.type='u'
Originally posted by kixer
Hi, I want to make a logfile where i store all tables, collnames and values of a specified database. Which statement can I use in SQLserver or Oracle? I already found the following statements:
Oracle:
select * from all_tables
select * from user_tables
SQLserver:
select * from sysobjects where type'='U'
So getting the tablenames isn't the problem. The question is how the get the matching columns with their type and value.
Tnx.|||Thanx! ;) Now I know the objectnames. All I have to do now is to make a nice treeview with the generated values, so i can log some sort of a dictionary.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment