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

Query of a Query DataSheet

I am using MS Office Access 2003 (11.5614). My basic question is can
I run a query of a query datasheet. I want to use more that one
criteria and can not get that query to work. I thought I might be
able to accomplish the results in two steps by using two queries. If
this is possible how can I do it?

Thank you,

Stan Hanna

Sep 29 '07 #1
4 3097
On Sat, 29 Sep 2007 09:39:17 -0700, Stan wrote:
I am using MS Office Access 2003 (11.5614). My basic question is can
I run a query of a query datasheet. I want to use more that one
criteria and can not get that query to work. I thought I might be
able to accomplish the results in two steps by using two queries. If
this is possible how can I do it?

Thank you,

Stan Hanna
You haven't given sufficient information for more than generic help,
but yes, you can use one query as the record source for another query.

You can also use a form in which to enter the parameters. Then
reference the relevant form controls in the query:

forms!FormName!ControlName

As long as the form is open, any query that refers to the form and
it's control will run with the correct criteria.
--
Fred
Please respond only to this newsgroup.
I do not reply to personal e-mail
Sep 29 '07 #2
Stan wrote:
I am using MS Office Access 2003 (11.5614). My basic question is can
I run a query of a query datasheet. I want to use more that one
criteria and can not get that query to work. I thought I might be
able to accomplish the results in two steps by using two queries. If
this is possible how can I do it?

Thank you,

Stan Hanna
You can create a query and then use that query in another query.

If this is related to a form, you can use recordsets. Ex:
Dim r As recordset
DIm r1 As Recordset
set r = Forms!TheForm.Form.Recordsetclone
r.filter = "CustomerID = 1"
r.sort = "DateEntered"
Set r1 = r.OpenRecordset
Sep 30 '07 #3
Stan <st*******@hotmail.comwrote in news:1191083957.648184.270350
@k79g2000hse.googlegroups.com:
My basic question is can
I run a query of a query datasheet. I want to use more that one
criteria and can not get that query to work.
There's no problem in running a query of a query. (But I have no idea of
what you mean when you suggest running a query of a query datasheet).
Regardless, if you have six criteria, will you be happy with running a
query of a query of a query of a query of a query of a query?
And if you are, and the queries are saved queries, and something isn't
quite right, will it be easy for you to investigate just what that is?
And if you share your work, will Uncle Phil be able to figure just what
you are doing or have done there.

Why not ask about "I want to use more that one criteria", the problem
which you actually have?
Everybody should know how to write such a query, and by using your
suggested bypass, you will pass up the opportunity to learn that very
basic skill.
Posting a copy of your effort that doesn't "work" is likely to get a
helpful response quite quickly.
Unless it's ludicrous, of course. Then it will generate multiple
absurdities. Lately 75% of the questions and 85% of the answers here have
been ludicrous, so you'll just fit right in; no need to worry

--
lyle fairfield

Think free Aim Mail is a good deal? 4 gig storage! IMAP too! I have an
account. It has about two thousand messages stored on Aim's server. But I
can't access the account, nor the stored messages nor new messages. Do I
have the username and password right? I'm pretty sure because I can log
into the account with an instant message program like Miranda or
Trillian. And they can tell me I have fifteen new e-mails. But for two
weeks I can't login with the webmail interface, nor with IMAP, nor with
POP. So, be careful with Aim mail. Cuz there seems to be no recourse.
And, yes, I know the terms I agreed to specify AOL has no responsibility
whatever. But maybe this will help you remember those terms are for real
and your e-mail may disappear forever.



Sep 30 '07 #4
On Sep 29, 10:10 pm, lyle fairfield <lylef...@yahoo.cawrote:
Stan <stanha...@hotmail.comwrote in news:1191083957.648184.270350
@k79g2000hse.googlegroups.com:
My basic question is can
I run a query of a query datasheet. I want to use more that one
criteria and can not get that query to work.

There's no problem in running a query of a query. (But I have no idea of
what you mean when you suggest running a query of a query datasheet).
Regardless, if you have six criteria, will you be happy with running a
query of a query of a query of a query of a query of a query?
And if you are, and the queries are saved queries, and something isn't
quite right, will it be easy for you to investigate just what that is?
And if you share your work, will Uncle Phil be able to figure just what
you are doing or have done there.

Why not ask about "I want to use more that one criteria", the problem
which you actually have?
Everybody should know how to write such a query, and by using your
suggested bypass, you will pass up the opportunity to learn that very
basic skill.
Posting a copy of your effort that doesn't "work" is likely to get a
helpful response quite quickly.
Unless it's ludicrous, of course. Then it will generate multiple
absurdities. Lately 75% of the questions and 85% of the answers here have
been ludicrous, so you'll just fit right in; no need to worry

--
lyle fairfield

Think free Aim Mail is a good deal? 4 gig storage! IMAP too! I have an
account. It has about two thousand messages stored on Aim's server. But I
can't access the account, nor the stored messages nor new messages. Do I
have the username and password right? I'm pretty sure because I can log
into the account with an instant message program like Miranda or
Trillian. And they can tell me I have fifteen new e-mails. But for two
weeks I can't login with the webmail interface, nor with IMAP, nor with
POP. So, be careful with Aim mail. Cuz there seems to be no recourse.
And, yes, I know the terms I agreed to specify AOL has no responsibility
whatever. But maybe this will help you remember those terms are for real
and your e-mail may disappear forever.
Lyle,
I agree with you, I should learn to do it correctly, with a multi-
criteria query, but if you look at my posting in this discussion group
under "Query Conflict" you will see I have been trying without much
success. Now that I have a Query of a Query working, proving an
immediate answer to my needs, I will go back to working the multi-
criteria query problem. In the interim I thank you and all of the
other responders. I have learned a great deal.

Stan Hanna

Sep 30 '07 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: William Wisnieski | last post by:
Hello Everyone, Access 2000, I have a main unbound form with a bound datasheet subform . The subform is bound to a query that returns records based on criteria in the main form. The user...
1
by: PeteCresswell | last post by:
I've got a query that comes up with a dataset list in < 3 seconds when run just in DataSheet mode...but the same query, when run as intended (Append to an empty table) takes upwards of 30 minutes...
3
by: thomas goodwin | last post by:
I have a query which asks for a parameter value to execute it. To see the results I have to: a) click on the query -- the "Enter Parameter Value" window pops up. b) enter the parameter value c)...
2
by: Simon Pleasants | last post by:
Am something of a newbie at this, so please bear with any stupid questions. I have created a database to track shipments that we import. The information is stored in a table and I have created...
2
by: Dave Burt | last post by:
Hi, Access officionados, I'm new here, so please cut me slack/gently tell me off if I'm out of line or in the wrong place. OK, here's something that seems silly (and is also problematic to...
0
by: Dave Stone | last post by:
Can anyone explain what is happening here? 2 tables tblA and tblB, each with a code column and a full-text column (e.g. C001, "Joe Bloggs"). tblA contains a small subset of the rows in tblB. There...
7
by: deko | last post by:
SELECT tblTxAcct.TxAcctName, tblTxType.TxTypeName, Nz(qryTxAcctListCt.TxCount, 0) AS TxCt FROM (tblTxAcct INNER JOIN tblTxType ON tblTxAcct.TxType_ID=tblTxType.TxType_ID) LEFT JOIN qryTxAcctListCt...
0
by: ET | last post by:
We have two tables... one with primary key ID and second table with secondary key to the ID in the first table... Now, they query pulls records from both tables, looks like this: SELECT...
0
by: ghat12 | last post by:
I have created a search form that displays results in separate datasheet which is launched by specifying the queryname in the OnClick property of a command button on the search form. My problem is...
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: Aftab Ahmad | last post by:
Hello Experts! I have written a code in MS Access for a cmd called "WhatsApp Message" to open WhatsApp using that very code but the problem is that it gives a popup message everytime I clicked on...
0
by: Aftab Ahmad | last post by:
So, I have written a code for a cmd called "Send WhatsApp Message" to open and send WhatsApp messaage. The code is given below. Dim IE As Object Set IE =...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: marcoviolo | last post by:
Dear all, I would like to implement on my worksheet an vlookup dynamic , that consider a change of pivot excel via win32com, from an external excel (without open it) and save the new file into a...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...

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.