Search
 
SCRIPT & CODE EXAMPLE
 

SQL

oracle list columns schema

-- Depending on connected user grants:
SELECT * FROM USER_TAB_COLS WHERE TABLE_NAME = 'my_table';	-- User tables
SELECT * FROM ALL_TAB_COLS WHERE TABLE_NAME = 'my_table';	-- Available to user
SELECT * FROM DBA_TAB_COLS WHERE TABLE_NAME = 'my_table';	-- All schemas

-- Columns from all tables in a schema (adapt with USER_..., DBA_... or ALL_...):
SELECT c.TABLE_NAME, c.DATA_TYPE FROM ALL_TAB_COLS c
JOIN ALL_TABLES t ON t.OWNER = c.OWNER
WHERE OWNER = 'my_schema';
Comment

oracle list columns in schema

SELECT *
FROM all_tab_cols;
Comment

PREVIOUS NEXT
Code Example
Sql :: How to convert DateTime to VarChar SQL 
Sql :: run sql file in terminal 
Sql :: insert current date sql 
Sql :: phpmyadmin change password 
Sql :: postgresql add column 
Sql :: run postgres docker 
Sql :: compare date mysql 
Sql :: sql only five first row 
Sql :: select into temp table 
Sql :: mysql remove html tag 
Sql :: sql current timestamp table 
Sql :: extract weekday from date in sql 
Sql :: mysql search table in all databases 
Sql :: wildcard in sql 
Sql :: mysql auto increment after delete 
Sql :: t-sql drop function if exists 
Sql :: convert varchar column to int in sql server 
Sql :: eliminate zero from integer mysql 
Sql :: sql delete all values in a column 
Sql :: sum query in sql 
Sql :: sqlite save db 
Sql :: docker create postgresql database 
Sql :: update join sql 
Sql :: mysql get all tables from a specific database 
Sql :: mysql collation for all languages 
Sql :: mysql age by birthdate 
Sql :: how to combine 2 tables in mysql 
Sql :: get week day from date in sql 
Sql :: alter table mysql 
Sql :: get max salary from each department sql 
ADD CONTENT
Topic
Content
Source link
Name
3+3 =