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

Home -> Community -> Usenet -> c.d.o.misc -> invalid identifier. function in where clause wrapped by to_char

invalid identifier. function in where clause wrapped by to_char

From: jobs <jobs_at_webdos.com>
Date: Thu, 08 Nov 2007 15:36:35 -0800
Message-ID: <1194564995.344818.161670@i38g2000prf.googlegroups.com>


perhaps tthis select will be very slow and terrrible, but I get invalid identifier on this line right on the function monthsfirstattempt.

I know the function works. Any reason I can't do this? I get the error here:

 and
to_char( monthsfirstattempt(o.account_number,'200710'),'yyyymm' )='200710'

select
 main_ani(o.account_number) ANI,

 u.creation_date ,
 u.nombre,
 u.apellido,
 o.address,
 o.city,
 o.st,
 o.zip,
 o.validation_date CHARGEDATE,

 monthsfirstattempt(o.account_number,'200710') FirstAttempt,  o.amount
from orders o, users u
 where o.account_number=u.account_number  and ( to_char(o.validation_date,'yyyymm')='200710'   or to_char(o.validation_date,'yyyymm')='200711')  and
to_char( monthsfirstattempt(o.account_number,'200710'),'yyyymm' )='200710'  and o.account_number
   not in
 (select m.account_number from mcmlinea m where m.cdani like '30571799%')
order by o.validation_date

Thanks in advance for any help or information. Received on Thu Nov 08 2007 - 17:36:35 CST

Original text of this message

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