I have a very odd grouping problem that I can't seem to figure out.....This report I've been using year after year, now they want it sorted by homeroom teacher, while still having the child's name. Every time I switch the first group from parent name to Homeroom teacher name, it puts only a few set of students in on the report and gives them all the same homeroom.....there is something in the formulas that is doing this and I can't seem to find the fix.......they seem easy to me, but i'm going in circles.
Group 1 - parent name
group 2 - student name
Formulas:
siblings name:
WhilePrintingRecords;
StringVar Student1;
StringVar Student2;
StringVar Student3;
StringVar Student4;
StringVar Student5;
NumberVar Sibling;
If NumberVar Sibling = 1 then Student1 := {StsSt.StsSt_Nickname} + " (" + IF {StsStHrT.StsStHrT_Lastname} = "Centeno" then Left ({StsStHrT.StsStHrT_Nickname},1 ) + ". " + {StsStHrT.StsStHrT_Lastname} + ")" else
if {StsStHrT.StsStHrT_Lastname} = "Meese" then "Meese/Gonzales" + ")" else
if {StsStHrT.StsStHrT_Lastname} = "School" then "Middle School" + ")"
else {StsStHrT.StsStHrT_Lastname} + ")" else
If NumberVar Sibling = 2 then Student2 := {StsSt.StsSt_Nickname} + " (" + IF {StsStHrT.StsStHrT_Lastname} = "Centeno" then Left ({StsStHrT.StsStHrT_Nickname},1 ) + ". " + {StsStHrT.StsStHrT_Lastname} + ")" else
if {StsStHrT.StsStHrT_Lastname} = "Meese" then "Meese/Gonzales" + ")" else
if {StsStHrT.StsStHrT_Lastname} = "School" then "Middle School" + ")"
else {StsStHrT.StsStHrT_Lastname} + ")" else
If NumberVar Sibling = 3 then Student3 := {StsSt.StsSt_Nickname} + " (" + IF {StsStHrT.StsStHrT_Lastname} = "Centeno" then Left ({StsStHrT.StsStHrT_Nickname},1 ) + ". " + {StsStHrT.StsStHrT_Lastname} + ")" else
if {StsStHrT.StsStHrT_Lastname} = "Meese" then "Meese/Gonzales" + ")" else
if {StsStHrT.StsStHrT_Lastname} = "School" then "Middle School" + ")"
else {StsStHrT.StsStHrT_Lastname}+ ")" else
If NumberVar Sibling = 4 then Student4 := {StsSt.StsSt_Nickname} + " (" + IF {StsStHrT.StsStHrT_Lastname} = "Centeno" then Left ({StsStHrT.StsStHrT_Nickname},1 ) + ". " + {StsStHrT.StsStHrT_Lastname} + ")" else
if {StsStHrT.StsStHrT_Lastname} = "Meese" then "Meese/Gonzales" + ")" else
if {StsStHrT.StsStHrT_Lastname} = "School" then "Middle School" + ")"
else {StsStHrT.StsStHrT_Lastname} + ")" else
If NumberVar Sibling = 5 then Student5 := {StsSt.StsSt_Nickname} + " (" + IF {StsStHrT.StsStHrT_Lastname} = "Centeno" then Left ({StsStHrT.StsStHrT_Nickname},1 ) + ". " + {StsStHrT.StsStHrT_Lastname} + ")" else
if {StsStHrT.StsStHrT_Lastname} = "Meese" then "Meese/Gonzales" + ")" else
if {StsStHrT.StsStHrT_Lastname} = "School" then "Middle School" + ")"
else {StsStHrT.StsStHrT_Lastname} + ")"
student name:
{StsSt.StsSt_Nickname} + " (" + IF {StsStHrT.StsStHrT_Lastname} = "Centeno" then Left ({StsStHrT.StsStHrT_Nickname},1 ) + ". " + {StsStHrT.StsStHrT_Lastname} + ")" else
if {StsStHrT.StsStHrT_Lastname} = "Meese" then "Meese/Gonzales" + ")" else
if {StsStHrT.StsStHrT_Lastname} = "School" then "Middle School" + ")"
else {StsStHrT.StsStHrT_Lastname} + ")"
studnet 2,3,4:
WhilePrintingRecords;
StringVar Student2;
Group 1 - parent name
group 2 - student name
Formulas:
siblings name:
WhilePrintingRecords;
StringVar Student1;
StringVar Student2;
StringVar Student3;
StringVar Student4;
StringVar Student5;
NumberVar Sibling;
If NumberVar Sibling = 1 then Student1 := {StsSt.StsSt_Nickname} + " (" + IF {StsStHrT.StsStHrT_Lastname} = "Centeno" then Left ({StsStHrT.StsStHrT_Nickname},1 ) + ". " + {StsStHrT.StsStHrT_Lastname} + ")" else
if {StsStHrT.StsStHrT_Lastname} = "Meese" then "Meese/Gonzales" + ")" else
if {StsStHrT.StsStHrT_Lastname} = "School" then "Middle School" + ")"
else {StsStHrT.StsStHrT_Lastname} + ")" else
If NumberVar Sibling = 2 then Student2 := {StsSt.StsSt_Nickname} + " (" + IF {StsStHrT.StsStHrT_Lastname} = "Centeno" then Left ({StsStHrT.StsStHrT_Nickname},1 ) + ". " + {StsStHrT.StsStHrT_Lastname} + ")" else
if {StsStHrT.StsStHrT_Lastname} = "Meese" then "Meese/Gonzales" + ")" else
if {StsStHrT.StsStHrT_Lastname} = "School" then "Middle School" + ")"
else {StsStHrT.StsStHrT_Lastname} + ")" else
If NumberVar Sibling = 3 then Student3 := {StsSt.StsSt_Nickname} + " (" + IF {StsStHrT.StsStHrT_Lastname} = "Centeno" then Left ({StsStHrT.StsStHrT_Nickname},1 ) + ". " + {StsStHrT.StsStHrT_Lastname} + ")" else
if {StsStHrT.StsStHrT_Lastname} = "Meese" then "Meese/Gonzales" + ")" else
if {StsStHrT.StsStHrT_Lastname} = "School" then "Middle School" + ")"
else {StsStHrT.StsStHrT_Lastname}+ ")" else
If NumberVar Sibling = 4 then Student4 := {StsSt.StsSt_Nickname} + " (" + IF {StsStHrT.StsStHrT_Lastname} = "Centeno" then Left ({StsStHrT.StsStHrT_Nickname},1 ) + ". " + {StsStHrT.StsStHrT_Lastname} + ")" else
if {StsStHrT.StsStHrT_Lastname} = "Meese" then "Meese/Gonzales" + ")" else
if {StsStHrT.StsStHrT_Lastname} = "School" then "Middle School" + ")"
else {StsStHrT.StsStHrT_Lastname} + ")" else
If NumberVar Sibling = 5 then Student5 := {StsSt.StsSt_Nickname} + " (" + IF {StsStHrT.StsStHrT_Lastname} = "Centeno" then Left ({StsStHrT.StsStHrT_Nickname},1 ) + ". " + {StsStHrT.StsStHrT_Lastname} + ")" else
if {StsStHrT.StsStHrT_Lastname} = "Meese" then "Meese/Gonzales" + ")" else
if {StsStHrT.StsStHrT_Lastname} = "School" then "Middle School" + ")"
else {StsStHrT.StsStHrT_Lastname} + ")"
student name:
{StsSt.StsSt_Nickname} + " (" + IF {StsStHrT.StsStHrT_Lastname} = "Centeno" then Left ({StsStHrT.StsStHrT_Nickname},1 ) + ". " + {StsStHrT.StsStHrT_Lastname} + ")" else
if {StsStHrT.StsStHrT_Lastname} = "Meese" then "Meese/Gonzales" + ")" else
if {StsStHrT.StsStHrT_Lastname} = "School" then "Middle School" + ")"
else {StsStHrT.StsStHrT_Lastname} + ")"
studnet 2,3,4:
WhilePrintingRecords;
StringVar Student2;