I have been asked to create a report that does the following(greatly simplified below):
Store 1 Store 2 Store 3... Sum
Month Rentals 5 7 8 20
Month Returns 3 4 0 7
Month Deliveries 2 2 5 9
Month Pickups 1 1 2 4
_____________________________________________________
Rental/Returns 2 3 8
Sum Deliveries/PU's 3 3 7
This is GREATLY simplified as I mentioned. The actual report would contain over 319 line items(Month Rentals, Month Returns, etc.) and the various sums calculating across all stores as well as in each store. To further complicate the matter, each stores data may reside in a different database and therefore require a different connection which is unknown at design time.
So, my problem is I know of no way to allow for the report to dynamically grow horizontally(i.e. work for x number of stores where x can be 1 to infinity). As mentioned previously, each of the stores data may reside in a different database so the connection string must be built dynamically also.
Ignoring the fact that the number of stores is unknown, it seems to me the only way to create this in Crystal is for every field for every store be a subreport with its own query string. That or either return some recordset that identifies each row as belonging to a specific store and a row type that tells what type of value it is(i.e. Rentals, Returns, Deliveries, etc.) and then use a computed field to display the value in the correct place.
With hundreds of rows each containing different data, each for a different store, and each needing a sum across all stores and across each store, this already seems too complex to create and maintain. However, add the extra wrinkle of an unknown number of stores and I really have no idea how to begin.
Perhaps Crystal can create subreports/computed fields dynamically based on the return value of a query or the parameters entered by a user? So I could do something like:
1)Query store database(returns 15 records that include connection data for each store)
2)Create a subreport/computed field based on each of the 15 records using the records values to create a datasource for each
3)Update the total computed fields such that they correctly sum all appropriate fields for every store added 1 to x.
The report is currently generated using Excel with a macro that examines each recordset and specifically puts that value in a certain cell based upon the store. Similarly, computed fields are used to calculate the sums by adding A1 + A2. I just don't see a comparable way of doing this in Crystal.
Anyone got any ideas?
Thanks!
Store 1 Store 2 Store 3... Sum
Month Rentals 5 7 8 20
Month Returns 3 4 0 7
Month Deliveries 2 2 5 9
Month Pickups 1 1 2 4
_____________________________________________________
Rental/Returns 2 3 8
Sum Deliveries/PU's 3 3 7
This is GREATLY simplified as I mentioned. The actual report would contain over 319 line items(Month Rentals, Month Returns, etc.) and the various sums calculating across all stores as well as in each store. To further complicate the matter, each stores data may reside in a different database and therefore require a different connection which is unknown at design time.
So, my problem is I know of no way to allow for the report to dynamically grow horizontally(i.e. work for x number of stores where x can be 1 to infinity). As mentioned previously, each of the stores data may reside in a different database so the connection string must be built dynamically also.
Ignoring the fact that the number of stores is unknown, it seems to me the only way to create this in Crystal is for every field for every store be a subreport with its own query string. That or either return some recordset that identifies each row as belonging to a specific store and a row type that tells what type of value it is(i.e. Rentals, Returns, Deliveries, etc.) and then use a computed field to display the value in the correct place.
With hundreds of rows each containing different data, each for a different store, and each needing a sum across all stores and across each store, this already seems too complex to create and maintain. However, add the extra wrinkle of an unknown number of stores and I really have no idea how to begin.
Perhaps Crystal can create subreports/computed fields dynamically based on the return value of a query or the parameters entered by a user? So I could do something like:
1)Query store database(returns 15 records that include connection data for each store)
2)Create a subreport/computed field based on each of the 15 records using the records values to create a datasource for each
3)Update the total computed fields such that they correctly sum all appropriate fields for every store added 1 to x.
The report is currently generated using Excel with a macro that examines each recordset and specifically puts that value in a certain cell based upon the store. Similarly, computed fields are used to calculate the sums by adding A1 + A2. I just don't see a comparable way of doing this in Crystal.
Anyone got any ideas?
Thanks!