Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Creating Report based on Form field as parameter.

Status
Not open for further replies.

cdgeer

IS-IT--Management
Joined
Apr 8, 2008
Messages
133
Location
US
I am trying to use a form field as a parameter to run a select query to be used to generate a specific report. I'm having trouble with the proper SQL syntax. Can anyone please help? If I leave out the WHERE statement it returns all records, but I would like only the records under 1 specific Supervisor.
This is the SQL I tried but returned no results.

SELECT [2008_12_Lawson].Supervisor, [2008_12_Lawson].LastName, [2008_12_Lawson].FirstName, [2008_12_Actuate].ActuateRole, [2008_12_BusObj].BusinessObj_Group
FROM (2008_12_Lawson INNER JOIN 2008_12_BusObj ON [2008_12_Lawson].EEID = [2008_12_BusObj].EEID) INNER JOIN 2008_12_Actuate ON [2008_12_Lawson].EEID = [2008_12_Actuate].EEID
WHERE ((([2008_12_Lawson].Supervisor)=[Forms]![2008_12_Lawson]![Supervisor]));
 
Sorry, Please disregard. I forgot to link the query to the table that the form uses. Duh! Happy New Year!!!!!!!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top