PunyaAK
|
| Posted: 04/18/2005, 1:34 PM |
|
Hi,
I have two search fields: PRODUCT_ID(drop down with Text Column as PRODUCT_NAME) and NAME.
Here is the scenario I'm looking for:
When the user doesn't select anything, it should return all the rows into the EDITABLE GRID.
This works fine if I just use the Builder with Table Data Source.
If I covert the Data Source of the EDITABLE GRID to SQL, it doesn't work this way (of course, it throws an error..I just uncommented the line that caused the error ).
It is explicitly looking for both NAME and PRODUCT_NAME.
Any tips on making the search fields OPTIONAL?
Thanks,
Punya
|
|
|
 |
Nicole
Posts: 586
|
| Posted: 04/19/2005, 2:36 AM |
|
Punya,
when you’re using Table data source type WHERE is built on a fly depending on search parameters passed to a page. I.e. only if certain parameter is passed then corresponding Where parameter is added to WHERE clause.
With SQL data source type WHERE is hard coded by you and all WHERE parameters are always present in WHERE. That’s why you need to assign default values for them.
_________________
Regards,
Nicole |
 |
 |
PunyaAK
|
| Posted: 04/20/2005, 9:38 AM |
|
Thanks Nicole!!
Saw your other posting. Will use 'Before Build Select' to generate the WHERE clause on the fly.
|
|
|
 |
|