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 -> help with cursors

help with cursors

From: Lenny <non.te_at_la.dico>
Date: Fri, 17 Sep 2004 10:29:13 GMT
Message-ID: <Z%y2d.336761$5D1.14987864@news4.tin.it>


I'm a newbie with oracle.
anyone can help me with these cursors?

I'm trying to port some queries written in VBA to oracle.

how can I set the second cursor "passaggi" dynamically taking a value from the first cursor?
(I cannot use just one cursor joining the tables.)

see line:
where psd_pv = clienti.upv_cod

thanks.
Luca

cursor clienti is
select cli_cod, upv_cod, cli_tigi, upv_agg, upv_trd, cli_int, cli_udat, upv_aff1
from vega.clienti,vega.unopv
where cli_cod = upv_trd
order by cli_cod;

cursor passaggi is
select psd_pv, psd_teo,psd_dat, psd_flg, psd_age from vega.pasdst
where psd_pv = clienti.upv_cod and

psd_dat >= trunc(sysdate-720) and
psd_dat <= trunc(sysdate) and
psd_teo > 0

order by psd_pv, psd_dat; Received on Fri Sep 17 2004 - 05:29:13 CDT

Original text of this message

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