Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: SQL2K migration

Re: SQL2K migration

From: Howard J. Rogers <howardjr2000_at_yahoo.com.au>
Date: Mon, 18 Nov 2002 06:41:02 +1100
Message-ID: <R8SB9.78560$g9.221382@newsfeeds.bigpond.com>


create table test(
col1 date default sysdate,
col2 number default 1000,
col3 varchar2(20) default 'This is a default');

Insert into test (col2) values (45);
Commit;
Select * from test;

COL1                COL2                    COL3
----------           ------------             ------------------------------
------
18/11/02          45                        This is a default

Regards
HJR "Frank Ashley" <frank.ashley_at_ntlworld.com> wrote in message news:mgMB9.521$5R.18830_at_newsfep3-gui.server.ntli.net...
> I've got to migrate a SQL2K DB to Oracle9i.
>
> With MS SQL I can create a default value then bind that value to a column.
> The idea being that if a value isn't supplied in an insert for that column
> then the default value will be applied.
>
> eg
> create default MAXDATE as '99991231 12:00:00'
>
> EXEC sp_bindefault 'DBO.MAXDATE', 'XXX_UNIT.UNT_EXPIRED'
>
> Can anybody help?
>
>
>
Received on Sun Nov 17 2002 - 13:41:02 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US