此查询工作正常:
INSERT
INTO I#journal
(
Type_,
Mndnr,
Obj,
Status,
Reason,
Date_
)
VALUES
(
'CHECK_TRX',
'1047',
'123123123',
'NEW',
'',
To_Date('10-04-2013 14:35:07', 'dd-mm-yyyy hh24:mi:ss')
);
但我想自动插入当前日期而不是To_Date('10-04-2013 14:35:07', 'dd-mm-yyyy hh24:mi:ss')
所以我尝试了Now()
INSERT
INTO I#journal
(
Type_,
Mndnr,
Obj,
Status,
Reason,
Date_
)
VALUES
(
'CHECK_TRX',
'1047',
'werwerwer',
'NEW',
'',
Now()
);
但我得到一个错误:
Error at Command Line:18 Column:5
Error report:
SQL Error: ORA-00904: "NOW": недопустимый идентификатор
00904. 00000 - "%s: invalid identifier"
*Cause:
*Action: