Re: How to implement dynamic SQL in Forms?

From: Andy Hardy <Andy.Hardy_at_camk.demon.co.uk>
Date: Wed, 16 Dec 1998 16:35:27 +0000
Message-ID: <S+E6wTAPF+d2MwZu_at_camk.demon.co.uk>


In article <74pu3p$dfq3_at_news.hk.linkage.net>, Big John <johnnyngan_at_yahoo.com> writes
>Hi,
>
> I would like to reuse the :system.last_query as a sub_query in a forms
>procedure, so that I can count some number like the followings:
> select count(col1) from table_a
> where exists (select col1 from table_b where ......)
>and the :system.last_query is exactly the sub-query statement. But forms
>does not accept the syntax if I replace the sub-query to :system.last_query.
>So what can I do?
>
>Best Regards,
>John
>
>
>
John,

Maybe you can use dbms_sql package for dynamic SQL or maybe you could create a block and programmatically change the the default_where clause?

Andy

-- 
Andy Hardy
Senior IT Systems Engineer, Alstom Automation
Tel: +44 1908 696200
Fax: +44 1908 696225
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Opinions are mine and do not necessarily reflect those of Alstom Automation
Received on Wed Dec 16 1998 - 17:35:27 CET

Original text of this message