Here is a fix for DATES and 2000
From: Gary Assa <gsa_at_li.net>
Date: 1996/08/16
Message-ID: <4v1r66$brq_at_linet01.li.net>#1/1
You could do something like this in the When-Validate-Item trigger: BEGIN
END; This should get oracle to assume the current century if none is specified
Date: 1996/08/16
Message-ID: <4v1r66$brq_at_linet01.li.net>#1/1
I don't remember which solution worked, but one of these did.
You could do something like this in the When-Validate-Item trigger: BEGIN
IF (:block.datefield IS NOT NULL) THEN IF (TO_NUMBER(TO_CHAR(:block.datefield, 'yyyy')) BETWEEN 0 AND 100) THEN :block.datefield := TO_DATE(TO_CHAR(:block.datefield, 'mm/dd/yy'), 'mm/dd/yy'); END IF; END IF;
END; This should get oracle to assume the current century if none is specified
DECLARE
dDate date;
vDate varchar2(9);
BEGIN
- Have a varchar2 date string with 2 digit year. vDate := '01-MAY-96';
- Do conversion on server side, as client side (D2000) stuffs up 'RR' format select to_date(vDate, 'DD-MON-RR') into dDate from dual;
- dDate should now hold 01-MAY-1996
END;
-- ========================================================= http://www.li.net/~gsa/index.html This is my signature file, not part of this mail message.Received on Fri Aug 16 1996 - 00:00:00 CEST