The AskTOM team is taking a break over the holiday season, so we're not taking questions or responding to comments. Please have a happy and safe festive season and as always, thanks for being a member of the AskTOM community.
Thanks for the question, Karthik.
Asked: December 05, 2016 - 9:13 pm UTC
Last updated: December 06, 2016 - 9:30 am UTC
Version: 11
Viewed 10K+ times! This question is
SQL> create table t ( y int, x date default sysdate ); Table created. SQL> SQL> insert into t (y) values (1); 1 row created. SQL> insert into t values (2, date '2000-01-01'); 1 row created. SQL> insert into t values (3,null); 1 row created. SQL> insert into t values (4,default); 1 row created. SQL> SQL> select * from t; Y X ---------- --------- 1 06-DEC-16 2 01-JAN-00 3 4 06-DEC-16
Joseph Charpak, December 06, 2016 - 4:38 pm UTC
create table t ( y varchar2(100), z number default ON NULL 42 ); insert into t (y,z) values ( 'inserting null but expecting to see 42', null ); select * from t; Y Z ————————————————————— ———— inserting null but expecting to see 42 42
Share and learn SQL and PL/SQL; free access to the latest version of Oracle Database!
Classes, workouts and quizzes on Oracle Database technologies. Expertise through exercise!