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 Wanet Telecoms Ltd on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Difficulting Grouping by 2 different fields.......

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
I have 2 different fields on a report that return names of someone who does a job. They could do Job 1 or Job 2.these two fields are in 2 seperate fields in the DBS.

the first line JOB 1 was done by JOHN and JOB 2 was done by PETER.....
The second line JOB 1 was done by STEVE and JOB 2 was done by JOHN.....

I want to know how to group by JOHN.???...how can i do this when he is in the JOB1 the first time and JOB2 the second???? so if these were the only 2 lines of the report i should have 3 groups 1 for PETER 1 for STEVE and 2 for JOHN.....i can't figure out how to do this with out using a paramater.....i don't want to be able to enter inforamtion at run-time to use to group......please help...any little bite of info will be awesome....thanks
 
Insert a formula, say "UserNameGroup" set the value equal to Job1 field. Then insert a group which is group by "UserNameGroup"

Insert Three more formula, say "WhoDoJob1", "WhoDoJob2"
and "DisplayIt"
set "WhoDoJob1" value to
if Job1 = UserNameGroup then "Job1" else ""
set "WhoDoJob2" value to
if Job2 = UserNameGroup then "Job2" else ""
set "DisplayIt" value to
WhoDoJob1 + WhoDoJob2

Put "DisplayIt" in details section, put other fields such as date time field in details as well.

Let me know if it does, or doesn't work !

Hope this can help

Kan

 
nopes...I don't think that will work...since Job1 and Job2 are probably in the same record...you cannot flip/flop on the fly like that.

It is possible to group on Job1 and Job2 separately and through formulas separate/display the data you are looking for...

regards Jim
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top