Collections:
Show All Columns in an Existing Table in Oracle
How To View All Columns in an Existing Table in Oracle?
✍: FYIcenter.com
If you have an existing table and want to know how many columns are in the table and how they are defined, you can use the system view USER_TAB_COLUMNS as shown in the following tutorial exercise:
SQL> COL data_type FORMAT A12; SQL> SELECT column_name, data_type, data_length FROM user_tab_columns WHERE table_name = 'EMPLOYEES'; COLUMN_NAME DATA_TYPE DATA_LENGTH ------------------------------ ------------ ----------- EMPLOYEE_ID NUMBER 22 FIRST_NAME VARCHAR2 20 LAST_NAME VARCHAR2 25 EMAIL VARCHAR2 25 PHONE_NUMBER VARCHAR2 20 HIRE_DATE DATE 7 JOB_ID VARCHAR2 10 SALARY NUMBER 22 COMMISSION_PCT NUMBER 22 MANAGER_ID NUMBER 22 DEPARTMENT_ID NUMBER 22
⇒ Recover a Dropped Table in Oracle
⇐ Delete a Column in an Existing Table in Oracle
2019-05-14, 3245🔥, 0💬
Popular Posts:
How To View Data Files in the Current Database in Oracle? If you want to get a list of all tablespac...
How To Recover a Dropped Index in Oracle? If you have the recycle bin feature turned on, dropped ind...
How To List All Stored Procedures in the Current Database in SQL Server Transact-SQL? If you want to...
How To Start the Command-Line SQL*Plus in Oracle? If you Oracle server or client installed on your w...
How To Connect to a MySQL Server with a Port Number in MySQL? If you want to connect a MySQL server ...