473,395 Members | 2,443 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

"WHERE" usage doubt

47
I have a "MainForm" containing a "SubForm", the SubForm is based on a Query and the MainForm has unbound comboboxes and TextBoxes to built filters that I apply to Subform using buttons in MainForm, it works fine, now I'd like to do this same filtering action but using the query criteria , I have done pointing the query design gird criteria fields to the MainForm combos and Text Boxes, it also works , but I'd like to know how to do this from VBA so I can use only one "Main" query and then build different WHERE clauses dependig on what I'm looking for , I have seen some examples but it's not so clear for me , could somebody point me to some examples of how to build this kind of filters / queries ?

Thanks for the help
Mar 26 '12 #1
2 1163
NeoPa
32,556 Expert Mod 16PB
See if you can use the ideas in Example Filtering on a Form to get you going.
Mar 26 '12 #2
Mihail
759 512MB
Or the ideas from http://bytes.com/topic/access/answer...y-filter-query
Mar 27 '12 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

9
by: LRW | last post by:
I'm not exactly sure how to even ask the question, and I know my terminology is not good as I'm a SQL beginner, but, here goes. I need to find a way to make an if statement within an array...or,...
5
by: Rachel Weeden | last post by:
I'm working on an ASP Web application, and am having syntax issues in a WHERE statement I'm trying to write that uses the CInt Function on a field. Basically, I want to select records using...
2
by: Ellen Manning | last post by:
Using A2K. In my table I have the field "Grant" which can have a value or be null. I have a query that counts the number of records and has a Where clause on the Grant field. The query won't...
1
by: Tom Louchbaum | last post by:
Can someonw pls tell me how to reference the Where clause made by the VBA statement DoCmd.OPENREPORT "Report",acviewpreview,,where as a control within the Report itself? Thanks.
13
by: andro | last post by:
Hi everybody! I have several tables from which I want to exract the SAME value (along with other referenced data). All the values are in the same column within the tables. How can I achieve...
5
by: davehansen22 | last post by:
Is there a way to generate a MySQL WHERE clause from a search string like this: "(dave OR hansen) php programmer" I would want to use the generated MySQL clause against a "memo" type field. ...
2
by: santoshsri | last post by:
Hello, Is there any by which I can write a SQL to get the 4th largest salary from a table without using "join" and without using "where" clause. Suppose the table is having two columns :...
1
by: itamar82 | last post by:
I am getting the following error: Microsoft OLE DB Provider for SQL Server error '80040e14' Incorrect syntax near the keyword 'WHERE'. for the sql below: SELECT TourId FROM (SELECT...
1
by: lyealain | last post by:
select * from cbomnew where (comCode= 'PCEC'or comCode='L0X'or comCode='CCEC') expert please help me on this... the comCode after WHERE statement are static(hardcoded).. PCEC,L0X,CCEC ... ...
2
by: dave jones | last post by:
Currently I have where zzz1234 is the encoded id number. If I take the "where" clause off, I get results. If I use the "where" clause, I receive an error>>"ODBC--call failed"
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.