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: about SYSDATE function

Re: about SYSDATE function

From: Sybrand Bakker <postbus_at_sybrandb.demon.nl>
Date: Fri, 30 Mar 2001 09:40:24 +0200
Message-ID: <tc8dvaqnjtkl38@beta-news.demon.nl>

Sysdate is a pseudo function, it is NOT a column and you can't use it in any table as it is a reserved word.
You may rest assured the type of sysdate is DATE and nothing else. Please check your Oracle documentation.

Hth,

Sybrand Bakker, Oracle DBA

<" srcnckpc"@hotmail.com> wrote in message news:3AC3E169.82AF1B6E_at_hotmail.com...
> Hello: I get an error: (PLS-00302: component 'SYSDATE' must be declared)
> when I run my code.
>
> --What is the datatype of v_dateA?
> --Do I declare sysdate as a record? Can I declare it against any
> table,e.g,
> v_sysdate emp.sysdate%TYPE;
>
>
>
> set serveroutput on
> ACCEPT p_char PROMPT 'Enter a specific date: '
>
> DECLARE
> v_date varchar2(25) := '&p_char';
> v_sysdate students.sysdate%TYPE;
> v_dateA ------------???
>
>
> BEGIN
> SELECT sysdate
> INTO v_sysdate
> FROM students;
>
> SELECT months_between(v_date, v_sysdate)
> INTO v_dateA
> FROM students;
>
>
> END;
>
>
> Thanks so much for helping a newbie.
>
Received on Fri Mar 30 2001 - 01:40:24 CST

Original text of this message

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