azizrasul
Well-known Member
- Joined
- Jul 7, 2003
- Messages
- 1,304
- Office Version
- 365
- 2019
- 2016
- Platform
- Windows
I have a table with a field (Premises) that can contain Null values.
I'm trying to perform Query By Form. On the form I have a combo box that contains all the unique values of [Premises]. The default value of the combo box is *. In the query I have the following in the criteria row: -
Like [forms]![frmSFF Creation]![cboPremises] Or Is Null
If I have * in the combo box, I get all the results including the records that have a Null. This is what I want.
If I choose a particular value from the combo box I get the record I want BUT I ALSO GET THE Null VALUES WHICH I DON'T WANT.
What do I do so that both scenarios work correctly, using the same query? I want to acheive this without using SQL as I have little knowledge of this.
I'm trying to perform Query By Form. On the form I have a combo box that contains all the unique values of [Premises]. The default value of the combo box is *. In the query I have the following in the criteria row: -
Like [forms]![frmSFF Creation]![cboPremises] Or Is Null
If I have * in the combo box, I get all the results including the records that have a Null. This is what I want.
If I choose a particular value from the combo box I get the record I want BUT I ALSO GET THE Null VALUES WHICH I DON'T WANT.
What do I do so that both scenarios work correctly, using the same query? I want to acheive this without using SQL as I have little knowledge of this.