Re: SQL*FORMS 3.0 PROBLEM: USING SYSTEM VARIABLE TO QUALIFY A FIELD

From: <ballpe_at_cnb07v.hhcs.gov.au>
Date: 15 May 93 15:23:28 +1000
Message-ID: <1993May15.152328.1_at_cnb07v.hhcs.gov.au>


In article <1993May13.171728.18215_at_ncrcae.ColumbiaSC.NCR.COM>, sanju_at_churchill.ColumbiaSC.NCR.COM (Sanjeev.Agrawal) writes:
>
> I have 3 blocks having same base table. Depending on different
> conditions I want to save different values in one field which
> is again present in all the three blocks(base table column).
> Therefore I need to qualify it with the block name.
>
> Can I somehow use SYSTEM.CURSOR_BLOCK to qualify the field ?
>
> Something similar to this:
>
> :SYSTEM.CURSOR_BLOCK.field1 := 'FLAG';
>
> When I tried to use it it gave me following error
>
> PL/SQL Check #20609. Please inform your Oracle Representative.
>
> Any way around ???
>
> If possible please e-mail.
>
> Thanks in advance !

There is a way around, and it has been used extensively by my co-workers (I'm not smart enough to come up with this on my own ;-) ).

Try using the copy packaged procedure like such:

   copy('FLAG', :system.cursor_block||'.field1')

This copies the value 'FLAG' into a field created by concatenating the block name with the field name (and a separating ".", of course).

I'm still not sure why you have three blocks with the same base table though. To each their own...

-- 

    /\       Peter Ball                 (ballpe_at_hhcs.gov.au)
   /  \      Systems Development Officer
  /    \     Dept Health, Housing, Local Govt and Community Services
 /      \    Brisbane, Queensland, Australia
/   /    \   "The views expressed above are mine and mine alone"
\  / /   /
 \/ / / /    Telephone : (07) 360 2637
  \/ / /     Postal    : Information Services Section
   \/ /                  GPO Box 9848
    \/                   Brisbane QLD 4001
                         Australia
Received on Sat May 15 1993 - 07:23:28 CEST

Original text of this message