Re: Need Meaning of Make-Table Query Code
- From: EarlCPhillips <EarlCPhillips@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Tue, 18 Dec 2007 11:49:01 -0800
The SQL is:
SELECT Q_GenericpullKiKPrePostData.Date AS Expr1,
Q_GenericpullKiKPrePostData.Host AS Expr2, Q_GenericpullKiKPrePostData.Name
AS Expr3, Q_GenericpullKiKPrePostData.PrePost AS Expr4,
(Q_GenericpullKiKPrePostData![4]+Q_GenericpullKiKPrePostData![5])*-1 AS BC
INTO PrePostMilk
FROM Q_GenericpullKiKPrePostData;
and the SQL for Q_GenericpullKiKPrePostData is:
SELECT tblOldKIKPrePostTest.dtmDate AS [Date],
tblSessAttendance.chrPgmHostName AS Host, tblOldKIKPrePostTest.chrSessNbr AS
Sess, tblOldKIKPrePostTest.chrParticiName AS Name, tblOldKIKPrePostTest.bln1a
AS bln1a, tblOldKIKPrePostTest.bln1b AS bln1b, tblOldKIKPrePostTest.bln1c AS
bln1c, tblOldKIKPrePostTest.bln1d AS bln1d, tblOldKIKPrePostTest.bln1e AS
bln1e, tblOldKIKPrePostTest.bln2 AS bln2, tblOldKIKPrePostTest.bln3 AS bln3,
tblOldKIKPrePostTest.bln4 AS bln4, tblOldKIKPrePostTest.bln5 AS bln5,
tblOldKIKPrePostTest.bln6 AS bln6, tblOldKIKPrePostTest.bln7a AS bln7a,
tblOldKIKPrePostTest.chrQues8Comments AS Ques8Comments,
tblOldKIKPrePostTest.chrPrePost AS PrePost, tblOldKIKPrePostTest.bln7b AS
bln7b, tblOldKIKPrePostTest.bln7c AS bln7c, tblOldKIKPrePostTest.bln7d AS
bln7d, tblOldKIKPrePostTest.chrComments AS Comments
FROM tblOldKIKPrePostTest INNER JOIN tblSessAttendance ON
(tblOldKIKPrePostTest.chrSessNbr = tblSessAttendance.chrSessNbr) AND
(tblOldKIKPrePostTest.chrParticiName = tblSessAttendance.chrParticiName)
GROUP BY tblOldKIKPrePostTest.dtmDate, tblSessAttendance.chrPgmHostName,
tblOldKIKPrePostTest.chrSessNbr, tblOldKIKPrePostTest.chrParticiName,
tblOldKIKPrePostTest.bln1a, tblOldKIKPrePostTest.bln1b,
tblOldKIKPrePostTest.bln1c, tblOldKIKPrePostTest.bln1d,
tblOldKIKPrePostTest.bln1e, tblOldKIKPrePostTest.bln2,
tblOldKIKPrePostTest.bln3, tblOldKIKPrePostTest.bln4,
tblOldKIKPrePostTest.bln5, tblOldKIKPrePostTest.bln6,
tblOldKIKPrePostTest.bln7a, tblOldKIKPrePostTest.chrQues8Comments,
tblOldKIKPrePostTest.chrPrePost, tblOldKIKPrePostTest.bln7b,
tblOldKIKPrePostTest.bln7c, tblOldKIKPrePostTest.bln7d,
tblOldKIKPrePostTest.chrComments
HAVING (((tblOldKIKPrePostTest.dtmDate) Between
[Forms]![frmReportsPage]![txtStartDate] And
[Forms]![frmReportsPage]![txtStopDate]));
I am inclined to believe it is the fifth and sixth fields added together and
multiplied by -1. Since the fields are boolean, the checked value is -1, so
two added together would be -2 if both were checked, times -1 would make it a
value of 2.
--
Trying To Feed The Hungry
"John Spencer" wrote:
As a guess they are referrng to fields named 4 and 5 in a query named.
Q_GenericpullKiKPrePostData. The other possibility is that this is
referring to the 5th and 6th field in the query.
If you could post the entire SQL for the make table query and
Q_GenericpullKiKPrePostData it might be easier to decipher.
--
John Spencer
Access MVP 2002-2005, 2007
Center for Health Program Development and Management
University of Maryland Baltimore County
..
"EarlCPhillips" <EarlCPhillips@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:A00B3C4D-D0F3-4581-BB73-36D5C7C3455F@xxxxxxxxxxxxxxxx
I have taken over an old Nutrition Services tracking system developed by
someone else. One of the old Make-Table queries has code for a field as
follows:
BC: (Q_GenericpullKiKPrePostData![4]+Q_GenericpullKiKPrePostData![5])*-1
where Q_GenericpullKiKPrePostData is a query extracting data from files of
test data recorded for the "Kids in the Kitchen" program Pre or Post test
results to teach nutrition and cooking skills to young disadvantaged kids.
The file contains: ID, SessNbr, Name, bln1a (boolean answer to question
1a),
bln1b, bln1c, bln1d, bln1e, bln2, bln3, bln4, bln5, bln6, bln7a, bln7b,
bln7c, bln7d, Comments, PrePost (whether it is a "pre" or "post" class
test),
Date.
The query it is drawing from has the following field order: Date, Host
(org.
that sponsored class), Session, Name, bln1a, bln1b, bln1c, bln1d, bln1e,
bln2, bln3, bln4, bln5, bln6, bln7a, Ques8Comments, PrePost, bln7b, bln7c,
bln7d, Comments.
The objective is to measure progress (BC or Behavior Change) in nutrition
knowledge to justify grant money for future programs.
What does the construct "Q_GenericpullKiIPrePostData![4]" or
"Q_GenericpullKiIPrePostData![5]" refer to? What would be the expected
value
in BC?
EarlCPhillips
Ex-Mainframer Learning Access To Help
Harvesters Food Network feed more
hungry people with the same staff
--------
Trying To Feed The Hungry
- Follow-Ups:
- Re: Need Meaning of Make-Table Query Code
- From: HatesIT
- Re: Need Meaning of Make-Table Query Code
- References:
- Re: Need Meaning of Make-Table Query Code
- From: John Spencer
- Re: Need Meaning of Make-Table Query Code
- Prev by Date: Re: Code doesn't work on some computers
- Next by Date: Export each page of report as a separate file
- Previous by thread: Re: Need Meaning of Make-Table Query Code
- Next by thread: Re: Need Meaning of Make-Table Query Code
- Index(es):
Relevant Pages
|