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

Use a row of data twice in a group

Status
Not open for further replies.

Squeaks

MIS
Apr 25, 2003
18
GB
Hi

I produce a timetable by grouping rows of data into 'slots' within a matrix - it looks a little like a cross-tab.

e.g. data looks like this:

PERIOD, DAY, NAME, NOTES
1,Mon,Monday 1,1
1,Tue,Tuesday 1,1
2,Mon,Monday 2,3
6,Fri,Friday 6,6

I group the data by PERIOD (max value 7, headers suppressed), suppress the detail but use a formula to see if DAY value is true, and use the group footer to display 'max of' the NAME.

the above sample data will look like this

Mon Tue Wed Thu Fri

1 Monday 1 Tuesday 1
2 Monday 2
3
4
5
6 Friday 6
7

Now to the question. Occasionally one of these rows of data will have a value in the notes field which differs from PERIOD, meaning the timetabled event should appear in BOTH areas of the matrix, the above example, using the same 4 rows of data now displays as...

Mon Tue Wed Thu Fri

1 Monday 1 Tuesday 1
2 Monday 2
3 Monday 3
4
5
6 Friday 6
7

anybody know a way of doing this? essentially calculating the 'slot' for each row of data and then returning and calculating again if the notes field is different.

any help appreciated
Les
 
If the notes field constitutes additional rows, I would approach this using the database if possible.

This would require that you learn your software version, the database and connectivity used, and post it, something that should be included with any post in ant forum.

You might be able to emulate this simple matrix using arrays though.

So a formula would read the data and populate an array from the data AND the notes field.

Might be worthwhile to replace your dba with an espresso machine, they'll both keep you up late but the latter will at least be pallatable.

-k
 
Cheers Synapse
I did have the same thought, the db is oracle, the report generation is done via third party software which makes it straightforwared to select and link objects - but I've no idea how to force a row of data to be repeated.

I've not tried my hand with arrays so if that's the only other approach it's going to take me a great deal of time to find a solution..IF I can make sense of it! I'll search the web for some info though (I don't even have Help installed with Crystal Reports 8.5).
 
If you the notes field shows a maximum of two different day values, you could link the table to itself and use one table to capture the first notes value, and the second table to capture the second. This probably wouldn't make sense if there can be more than two values though.

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top