473,385 Members | 1,588 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,385 software developers and data experts.

Many query criteria located in a linked table.

The problem I am having is setting up some code to query a table(Tbl_Table1_ContainsLotsOfData)
using criteria in another table(Tbl_Table2_ContainsCriteria),
then appending the result to an existing table(Tbl_WantedResult).


Tbl_Table1_ContainsLotsOfData
SerialNumber PartName PartModel
0000000001 PartA ModelOFfPartA
0000000002 PartB ModelOFfPartB
0000000003 PartC ModelOFfPartC
0000000004 PartD ModelOFfPartD
0000000005 PartE ModelOFfPartE



Tbl_Table2_ContainsCriteria
SerialNumber
0000000002
0000000004



Tbl_WantedResult
0000000002 PartB ModelOFfPartB
0000000004 PartD ModelOFfPartD

I do need to use some sort of function on this one. The system I am working with does not allow unqualified searches so JOIN is out of the question.

The query works fine if I use
“0000000002” Or “0000000004”
as search criteria on Tbl_Table1_ContainsLotsOfData in an append query pointing to Tbl_WantedResult


But the search criteria I need to use is over 200 entries, is dynamic and is located in a linked table.

Any help you can give me with this would be greatly appreciated.
Jun 6 '07 #1
1 1418
Rabbit
12,516 Expert Mod 8TB
The problem I am having is setting up some code to query a table(Tbl_Table1_ContainsLotsOfData)
using criteria in another table(Tbl_Table2_ContainsCriteria),
then appending the result to an existing table(Tbl_WantedResult).


Tbl_Table1_ContainsLotsOfData
SerialNumber PartName PartModel
0000000001 PartA ModelOFfPartA
0000000002 PartB ModelOFfPartB
0000000003 PartC ModelOFfPartC
0000000004 PartD ModelOFfPartD
0000000005 PartE ModelOFfPartE



Tbl_Table2_ContainsCriteria
SerialNumber
0000000002
0000000004



Tbl_WantedResult
0000000002 PartB ModelOFfPartB
0000000004 PartD ModelOFfPartD

I do need to use some sort of function on this one. The system I am working with does not allow unqualified searches so JOIN is out of the question.

The query works fine if I use
“0000000002” Or “0000000004”
as search criteria on Tbl_Table1_ContainsLotsOfData in an append query pointing to Tbl_WantedResult


But the search criteria I need to use is over 200 entries, is dynamic and is located in a linked table.

Any help you can give me with this would be greatly appreciated.
What do you mean that it doesn't allow unqualified searches? Why can't you just join?

If you can't join, try a subquery.
Jun 6 '07 #2

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

Similar topics

2
by: Larry R Harrison Jr | last post by:
The database is located at this link: http://www.angelfire.com/az/larrytucaz/tmp/db1.zip This database has a query which sometimes screens to leave out "OCB" in the last field in the query. It...
2
by: Kelly Bowles | last post by:
I am doing something wrong, but I fail to see it. Access 2002 is what I am using. I have struggled with this for over two weeks. PurchaseOrder table/form linked to InventoryTransaction...
6
by: Martin Lacoste | last post by:
Ok, before I headbutt the computer... don't know why when I add criteria in a query, I get an 'invalid procedure call'. I also don't know why after searching the help in access, the various access...
2
by: JM | last post by:
Hello, I've created a Querydef in a Form_Load() sub. The form is a subform that no longer has linked child fields. The form is bound to this querydef. When I open the form, the fields are...
5
by: CC | last post by:
Dear, I have a form that is opened using a sql statement: Part of the table structure: ----------------------------------------- TbGeneral: PK - dsr_id TbDossierSample:
6
by: lesperancer | last post by:
SELECT distinct b.t_orno, b.t_pono FROM tblMonthlyBooking AS b, tblFilterDate, tblFilterDate AS tblFilterDate_1 WHERE (((b.t_yearMonth) Between . And .)); tblMonthlyBooking is a sql server...
10
by: Daniel | last post by:
In Microsoft Access I can write a query that includes the criteria: Between Date()-7 And Date() to retrieve the records from a table that fall within the last week. I'm trying to write a...
6
by: gerbski | last post by:
Hi all, I am relatively new to ADO, but up to now I got things working the way I wanted. But now I've run into somethng really annoying. I am working in MS Access. I am using an Access...
2
by: john | last post by:
This must be simple but I can't figure it out. Table 1 1xM to table 2: Table 1 IDfield 1 2 Table 2 IDfield CriteriaField 1 Criteria value 1 2 Criteria value 1 2 ...
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...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
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
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
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...

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.