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 -> dbms_sql and bind_variable

dbms_sql and bind_variable

From: <mcdougald_at_water.dnr.state.sc.us>
Date: Wed, 16 Dec 1998 14:16:54 GMT
Message-ID: <758fck$emr$1@nnrp1.dejanews.com>


Hi,

  I've been using dbms_sql to evaluate sql queries containing functions with no problem, but I tried to include bind variables, and got the following error:

select to_char(new_time(observe_date,'GMT',:TimeZone),'yyyy/mm/dd hh24mi'), ucan_id, HEATING_DEGREE_DAYS(TMAX, TMIN) from TD3200_DATA where ucan_id = 17297 and observe_date between to_date('12/01/1998','mm/dd/yyyy') and to_date
('12/17/1998','mm/dd/yyyy') order by ucan_id, to_char(new_time
(observe_date,'GMT',:TimeZone),'yyyy/mm/dd hh24mi') SQL Error: ORA-06552:
PL/SQL: Statement ignored ORA-06553: PLS-201: identifier 'HEATING_DEGREE_DAYS' must be declared

  It works fine if there is no function in the sql statement, and it also works fine with the function with no bind variable. The combination seems to raise the error. does anyone have any idea why I'm getting this error?

Thanks,

John McDougald
SC Dept of Natural Resources

-----------== Posted via Deja News, The Discussion Network ==---------- http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own Received on Wed Dec 16 1998 - 08:16:54 CST

Original text of this message

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