This topic is locked

Where condition in lookup

12/16/2011 8:25:49 AM
ASPRunnerPro General questions
A
admin author

Hi,
Can anybody guide me why following in where condition of lookup not working.
----------------------------------------------------------------------------------------------------------------------

"Month_Code> (select max(Fee_month) from T_Fee_Inv_Processed where Session_Year= '" & values("Session_Years") & "' )"

----------------------------------------------------------------------------------------------------------------------
' " & values("Session_Years") & " ' is one of the field from current screen.
Sami

Sergey Kornilov admin 12/16/2011

You cannot use values() array in WHERE clause. You can save the value of this field in session variable though and then use this session variable in WHERE clause.
To save field value in Session variable use ProcessValues event:

http://xlinesoft.com/asprunnerpro/docs/process_record_values.htm
The only downside is that it's not going to work on the Add page since there is no data yet.