--view system time
select sysdate from dual;
--view charset
select userenv('language') from dual;
select to_char(sysdate,'yyyy-mm-dd hh24:mi:ss') from dual;
select 1+2 from dual;
create sequence aaa increment by 1 start with 1;
select aaa.nextval from dual;
select aaa.currval from dual;
--view table dll
SELECT DBMS_METADATA.GET_DDL('TABLE',u.table_name) FROM USER_TABLES u where u.TABLE_NAME='AAATEST';
--view all table include a Column
select table_name from user_TAB_COLUMNS where COLUMN_NAME='DESCRIPTION';
-- select * from USER_TABLES
--oracle query all table and Index include some column
select * from user_TAB_COLUMNS where COLUMN_NAME='DESCRIPTION'
--oracle query all table include some column
select col.table_name from user_TAB_COLUMNS col,USER_TABLES tab where col.COLUMN_NAME='DESCRIPTION' and col.table_name=tab.table_name
select sysdate from dual;
--view charset
select userenv('language') from dual;
select to_char(sysdate,'yyyy-mm-dd hh24:mi:ss') from dual;
select 1+2 from dual;
create sequence aaa increment by 1 start with 1;
select aaa.nextval from dual;
select aaa.currval from dual;
--view table dll
SELECT DBMS_METADATA.GET_DDL('TABLE',u.table_name) FROM USER_TABLES u where u.TABLE_NAME='AAATEST';
--view all table include a Column
select table_name from user_TAB_COLUMNS where COLUMN_NAME='DESCRIPTION';
-- select * from USER_TABLES
--oracle query all table and Index include some column
select * from user_TAB_COLUMNS where COLUMN_NAME='DESCRIPTION'
--oracle query all table include some column
select col.table_name from user_TAB_COLUMNS col,USER_TABLES tab where col.COLUMN_NAME='DESCRIPTION' and col.table_name=tab.table_name