What is query of display the all tables in SQL server ?
Editorial / Best Answersantanukd
Just replace "[your-schema-name-here]" in the following query with your schema name. Hope it comes handy to some of you out there.
Select 'TABLE' as OBJECT_TYPE, TABLE_NAME as OBJECT_NAME, TABLE_SCHEMA as OBJECT_SCHEMA from information_schema.VIEWS
Select 'VIEW' as OBJECT_TYPE, TABLE_NAME as OBJECT_NAME, TABLE_SCHEMA as OBJECT_SCHEMA from information_schema.VIEWS
Select 'INDEX[Type:Name:Table]' as OBJECT_TYPE, concat(CONSTRAINT_TYPE,' : ',CONSTRAINT_NAME,' : ',TABLE_NAME) as OBJECT_NAME,TABLE_SCHEMA AS OBJECT_SCHEMA from information_schema.TABLE_CONSTRAINTS
Select 'Procedure/Functions' as OBJECT_TYPE, ROUTINE_NAME as OBJECT_NAME, ROUTINE_SCHEMA as OBJECT_SCHEMA from information_schema.ROUTINES
Showing Answers 1 - 16 of 16 Answers
- Bmc remedy ticketing tool
- SQL to retrieve the 5th record only
- What is dns server ?
- How do http server knows if it is static request or dynamic request.?
- Write a program to display all files containing demo in their name in QTP
- Websphere application server qeustion
- How do you install print server in windows 2008 /2008 r2 server core?
- Question on array
- Create a report on single query to display year wise sales in chart and current month in table in webi
- How to tune plugin-configuration file in websphere application server
- Display the employee details who joined before 5 days.
- SQL query to find the department (id) wise counts in the company
- Select the even and odd records
- Query to display employee hike details
- Better performance collection
- C drive space
- SAP question regarding sales order data
- Which one of the following in not a client-server?
- What is use of sharepoint and which is supported client os and server os.
- What is memory in server and types of it(paged/non paged)