Home » Developer & Programmer » Reports & Discoverer » How to use user_parameter to order by in REPORTS 6i
How to use user_parameter to order by in REPORTS 6i [message #90220] Sun, 12 December 2004 22:08 Go to next message
TMoore
Messages: 1
Registered: December 2004
Junior Member
Hi

i have query like this:

select name, start_date, end_date from

test

where start date between :start_d and :end_d

order by :sort

--

:sort is list 'start_date' and 'end_date'.

So when I choose start_date report doesn't sort by start_date. I change it to list '2' and '3' - 2nd an 3rd column and it still doesn't work.

How to solve this??
Re: How to use user_parameter to order by in REPORTS 6i [message #90225 is a reply to message #90220] Mon, 13 December 2004 23:33 Go to previous message
ashish
Messages: 107
Registered: December 2000
Senior Member
You will have to use Lexical parameter for that.

In the query, write select ....
from ....
where ...
&p1
The parameter will get created automatically.
In After Parameterform trigger, write :

:p1 := 'ORDER BY '||':p1';

Hope this answers your question.

Regards,
Ashish
Previous Topic: generate text file from a group above report
Next Topic: reports in multilingual
Goto Forum:
  


Current Time: Mon Nov 25 18:41:34 CST 2024