Monday, March 12, 2012

Nested Groups with Two datasources? Noob design approach question.

I've got these two tables

FileLog:

ProcessKey

Filename

EventLog:

ProcessKey

Eventtype

Date

Both tables can be related by Processkey key, but there data does not

relate. Anwhere from 5 to 10 Filelog rows per ProcessKey.

Anywhere from 5 to 200 Eventlog rows per ProcessKey.

Filelog contains Filenames that make up a Process Key batch, and Eventlog contains rows of events for that ProessKey Batch.

I'd like a report where Filelog enteries are in my group header by

Process Key, followed by details with Enventlog by ProcessKey..

something like this:

ProcessKey1:

filename1,filename2,filename3

filename4 (wraping and growing a cell)


Eventtype Date


Eventtype Date


Eventtype Date


Eventtype Date

ProcessKey2:

filename4,filename5,filename6

filename7 (wraping and growing a cell)


Eventtype Date


Eventtype Date


Eventtype Date


Eventtype Date


How do I do this? If the grid only allows for one datasource?

Nested Groups? Two grids with an expression connecting them?

Thanks for any help or information.

The only way to nest two independent query is via subreports. However, why can't you simply join the filelog and event log in the same query?

The one thing you can't do is the concatenated file name. This would be considered a custom aggregate. You could probably create this string in your query.

|||

I thought about joining the tables in a view or on the report, but it would be kindof an ugly join with up 20 files per Processid and up to 200 entries in the event log per Processid. I'm not sure a join make sense .. every filelog entry under the processid would be the header for for all events under that process id.

Question about subreports, Can I have a subreport that serves as the header for my eventlog group? Can that subreport use processid from the group break?

Thanks.

No comments:

Post a Comment