Limit query output

  • Thread starter Thread starter Harmannus
  • Start date Start date
H

Harmannus

Hallo,

Hallo,

I have a subform "fsubScandata" with the field "SID" on it and a Graph Chart
under a Tab. How can i limit the output of this Graph Chart to SID.

I now hardcode the SID ;-( (((qselGraph.SID)=8))

Unbound Object Frame row source:
TRANSFORM Count(*) AS [Count] SELECT qselGraph.Scan FROM qselGraph WHERE
(((qselGraph.SID)=8)) GROUP BY qselGraph.Scan PIVOT qselGraph.Status;


Thanx for any suggestions!

Regards,
Harmannus
 
I assume the subform is filtered by some value on the outer form - the Link
Master Fields setting of the subform. If you're using the Graph Applet,
remove the WHERE clause in your row source and set the Link Master and Link
Child properties identical to the subform.

--
John Viescas, author
"Microsoft Office Access 2003 Inside Out"
"Running Microsoft Access 2000"
"SQL Queries for Mere Mortals"
http://www.viescas.com/
(Microsoft Access MVP since 1993)
 
Do you want to just type the SID, or do you want to grab it from a control on a
form, OR ????
Assuming you want to get it from a control on an open form, then your SQL
statement would look like the following

PARAMETERS Forms!FormName!SomeControl Long;
TRANSFORM Count(*) AS [Count]
SELECT qselGraph.Scan
FROM qselGraph
WHERE (((qselGraph.SID)= Forms!FormName!SomeControl))
GROUP BY qselGraph.Scan
PIVOT qselGraph.Status;
 
Hallo John,

Link Master and Link Child did the trick ;-)

Thanx for the help!

Regards,
Harmannus


John Viescas said:
I assume the subform is filtered by some value on the outer form - the Link
Master Fields setting of the subform. If you're using the Graph Applet,
remove the WHERE clause in your row source and set the Link Master and Link
Child properties identical to the subform.

--
John Viescas, author
"Microsoft Office Access 2003 Inside Out"
"Running Microsoft Access 2000"
"SQL Queries for Mere Mortals"
http://www.viescas.com/
(Microsoft Access MVP since 1993)
Harmannus said:
Hallo,

Hallo,

I have a subform "fsubScandata" with the field "SID" on it and a Graph Chart
under a Tab. How can i limit the output of this Graph Chart to SID.

I now hardcode the SID ;-( (((qselGraph.SID)=8))

Unbound Object Frame row source:
TRANSFORM Count(*) AS [Count] SELECT qselGraph.Scan FROM qselGraph WHERE
(((qselGraph.SID)=8)) GROUP BY qselGraph.Scan PIVOT qselGraph.Status;


Thanx for any suggestions!

Regards,
Harmannus
 
Back
Top