Skip to Content
Former Member
Aug 26, 2009 at 11:28 AM

where condition with optional fields in a select statement



I have 7 optional fields on the selection screen of a Report. While fetching the data from database table, how do we include those optional fields in WHERE condition of the select query?

If I use AND in WHERE condition of the select query: If I do not enter any values for the optional fields ,it will not fetch any data.

If I use OR : It will fetch wrong(unwanted) entries.

Please help me to sovle this.

Thanks in advance,