I am in the process of creating a report if I use the following select statement I get the desired results
{STOREDGRADES.COURSE_NUMBER} like "*LA*" and
{STOREDGRADES.STORECODE} = {?My Parameter} and
{STUDENTS.LAST_NAME} = {?LastName} and
{STANDARDS.IDENTIFIER} like "*LA*"
However my problem comes in as I need multiple selections of the same data such as the following, so I need LA, Math, Science etc to follow.
{STOREDGRADES.COURSE_NUMBER} like "*MA*" and
{STOREDGRADES.STORECODE} = {?TermID} and
{STUDENTS.LAST_NAME} = {?LastName} and
{STANDARDS.IDENTIFIER} like "*MA*"
I tried creating a sub report, I might be doing something wrong, I ended up getting 160 records back for each subreport as it parsed the database. The code alone works only showing the 2 results which is what I want. However I need multiple instances of the same but different data.
My SQL statement is:
SELECT "STUDENTS"."FIRST_NAME", "STUDENTS"."LAST_NAME", "STUDENTS"."GRADE_LEVEL", "STOREDGRADES"."STORECODE", "STOREDGRADES"."TEACHER_NAME", "STOREDGRADES"."COURSE_NUMBER", "STANDARDSGRADES"."TRANSAVERAGESCORE", "STANDARDS"."NAME", "STANDARDS"."IDENTIFIER"
FROM (("PS"."STUDENTS" "STUDENTS" LEFT OUTER JOIN "PS"."STOREDGRADES" "STOREDGRADES" ON "STUDENTS"."ID"="STOREDGRADES"."STUDENTID") LEFT OUTER JOIN "PS"."STANDARDSGRADES" "STANDARDSGRADES" ON "STUDENTS"."ID"="STANDARDSGRADES"."STUDENTID") LEFT OUTER JOIN "PS"."STANDARDS" "STANDARDS" ON "STANDARDSGRADES"."STANDARDSID"="STANDARDS"."ID"
WHERE "STOREDGRADES"."COURSE_NUMBER" LIKE '%LA%' AND "STOREDGRADES"."STORECODE"='T1' AND "STUDENTS"."LAST_NAME"='SOMELASTNAME' AND "STANDARDS"."IDENTIFIER" LIKE '%LA%'
Maybe I am thinking wrong in trying to use sub reports, any direction would be greatly appreciated.
Thank you
Shawn
Edited by Shawnlo - 27 May 2011 at 5:26am