Search
 
SCRIPT & CODE EXAMPLE
 

SQL

get all tables with column name sql

SELECT      c.name  AS 'ColumnName'
            ,t.name AS 'TableName'
FROM        sys.columns c
JOIN        sys.tables  t   ON c.object_id = t.object_id
WHERE       c.name LIKE '%MyName%'
ORDER BY    TableName
            ,ColumnName;
Comment

how to get all table names in sql query

BY LOVE SINGH

SELECT TABLE_NAME
FROM INFORMATION_SCHEMA.TABLES
WHERE TABLE_TYPE = 'BASE TABLE' AND TABLE_CATALOG='YOUR_Database_name'
Comment

mssql get all table names

SELECT name from sysobjects where type = 'U'
Comment

Get all table names in SQL

SELECT name, crdate FROM SYSOBJECTS WHERE xtype = 'U';
-- or 
SELECT * FROM INFORMATION_SCHEMA.TABLES
-- or 
SELECT * FROM databaseName.INFORMATION_SCHEMA.TABLES;
Comment

get all tables with column name sql

Get table containing given field
Comment

PREVIOUS NEXT
Code Example
Sql :: select dba users oracle 
Sql :: mysql loop insert 
Sql :: sqlite insert row 
Sql :: group_concat limit mysql 
Sql :: command line mysql import 
Sql :: postgres extract number from string 
Sql :: show all tables in oracle 
Sql :: update mysql centos 
Sql :: pyodbc connect to sql server 
Sql :: mysql remove ubuntu 
Sql :: sql like variable 
Sql :: mssql reset auto increment 
Sql :: sql server 2012 query history 
Sql :: how to check database size mysql 
Sql :: console output pl sql 
Sql :: sql beginning of previous month 
Sql :: postgres get timestamp 
Sql :: mysql change root password ubuntu 
Sql :: host is not allow to connect to this mysql server 
Sql :: rename table in mysql 
Sql :: sql output inserted id 
Sql :: mysql breakline on string 
Sql :: oracle apex list connected users 
Sql :: sql random decimal 
Sql :: postgresql if null then 0 
Sql :: v$session table or view does not exist 
Sql :: reset auto increment in mysql 
Sql :: adding a check statement in sql 
Sql :: alter table in mysql 
Sql :: create mysql user 
ADD CONTENT
Topic
Content
Source link
Name
7+8 =