Reputation: 11
Sir,
I've a problem regarding Database.
My problem is I've Database script file.When I integtrated the script file in Database.I found all the stored procedure is visible.But tables are not visible.
I wrote the Command as follows: select * from sysobjects where type='p'
Now all the tables is showing but fields are not.
I wrote the Command to get the fields for particular table_name targeted as
select * from table_name .
But a message is Coming like Invalid Object name as table_name.
Please help me out to find the fields of the table ...
Upvotes: 0
Views: 337
Reputation: 77707
You can use the following query to retrieve the columns of the sought-for table:
SELECT *
FROM INFORMATION_SCHEMA.COLUMNS
WHERE TABLE_NAME = 'your table name'
Upvotes: 1