LOV in Reports with filter using where [message #88450] |
Sat, 07 September 2002 03:35 |
Meghna
Messages: 6 Registered: November 2001
|
Junior Member |
|
|
Hello,
I have defined a parameter :item. On this basis
I want to select vendors in another LOV like
select a.vend_cd,vend_name from vendor a,vend_item b
where item_cd=:item(???) and a.vend_cd=b.vend_cd
but giving error. Also i am using :item as source in field itemcode with sucess. I got the answer but not able to understand. here it is:
While setting a simple parameter for use in defining the select statement, such as a date, bill_period_id etc. is simple, there are times when you may wish to allow a user to add any "where" statement they wish. However, if you create a varchar user variable and try to reference it as an SQL condition ( e.g. Select * from account where :usercondition) you will get an error. The secret is that the variable must be initialized to a valid SQL condition before the Data Model will accept it. This is done in the "Initial Value" spot on the variable's properties form. The usual default is "1 = 1" which simply means all rows meeting whatever other conditions are included in the select statement will pass this condition if the user does not change it in the parameter form.
please help.
meghna
meghna1998@rediffmail.com
|
|
|
|