Lisbox does not populate all records from SQL Statment

Manos39

Registered User.
Local time
Today, 06:51
Joined
Feb 14, 2011
Messages
248
Hello
I have a form (listafrm) in my DB that uses a lisbox to return values depending on an sql statement which uses
8 unbount textboxes in the same form. The sql stetment i built is the same in stucture as another query i have in my DB
(Qrsearch). Yet strangely that query instead of returning 131 records like (Qrsearch) returns only 34! Tryed many times
seting up the query with its criteria for the texboxes in the begining in my form show up 131 records in the listbox, then
suddenly only 34! I suspected the null values in some records, so i made the criteria to hold null values,
yet no luck the same again.

I would much appreciate some help
I upload my DB for this odd by me result
 

Attachments

The SQL statement is substantially different to the Query in that it includes a number of expressions based on unbound text boxes on the form.

Perhaps the sample posted here is the sort of thing you are looking for, it should give you some pointers, at the very least.
 
John it is kind the same, or isnt it i mean if i bind the listbox to a query excactly like my sql statement would that affect for the better?
 
Your query is simply returning all the records, whilst the SQL you are currently using to populate the listbox has a number of expressions that are taking criteria from the unbound text boxes on you form.

I'm guessing that what you are trying to achieve is similar in concept to what is being demonstrated in the sample I linked to in my previous post. Have a look at the structure of the query I have used in that sample, along with the code.
 
I think it could be done whith some other criteria in the SQL statment.. Thank you John i shall try your way..
 
You can certainly do it using the SQL you just need to structure it correctly.
 
i say i agree with you and i need help to do that
 
The sample has step by step instructions, you should be able to work through them and figure out what is going on.

Once you've done that come back and ask specific questions. I can't read you mind and figure out what it is you need help with.
 

Users who are viewing this thread

Back
Top Bottom