Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

How to display results from two different data sources in one tablix report? Expand / Collapse
Author
Message
Posted Thursday, May 16, 2013 7:19 AM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Tuesday, April 15, 2014 3:30 PM
Points: 17, Visits: 38
I'm trying to display results from a query against a DB2 datasource as well as a query from a sql data source in the same table (report). Is this even possible? I'm trying to compare data to see if there are errors from the sql data source which inserts data into the DB2 accounting database.
Post #1453515
Posted Thursday, May 16, 2013 8:51 AM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Today @ 7:57 AM
Points: 159, Visits: 466
Any given tablix can only be associated with one dataset at a time, but there are two ways to accomplish your goal that I can think of.

First, you could create two identical tables side-by-side that are designed to pull related data from each dataset together in the same order. When you run the report, if the data are synchronous between the two tables, you can visually confirm that there are no errors. If they appear out of sync, there is a problem to investigate.

Second, you can use the LookupSet function to pull related data from a secondary dataset into the context of a tablix associated with a the dataset. By using a Split function and by concatenating a vbCRLF as a delimiter for the string created by the Split function, you can create a set of "rows" that can mimic a table within a table.
Post #1453595
Posted Thursday, May 16, 2013 9:20 AM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Tuesday, April 15, 2014 3:30 PM
Points: 17, Visits: 38
Thanks!

I'll investigate the lookup function. I was pretty sure that only 1 dataset per tablix was allowed.
Post #1453625
Posted Friday, May 17, 2013 12:16 PM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Tuesday, April 15, 2014 3:30 PM
Points: 17, Visits: 38
Can the secondary dataset be from a completely separate Data Source? My first dataset comes from a SQL Server Data source while my second dataset comes from a DB2 Data Source.
Post #1454163
Posted Friday, May 17, 2013 3:09 PM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Today @ 7:57 AM
Points: 159, Visits: 466
I don't know why not, though I have not tested that particular arrangement. But once the data are in datasets, I think the report would see it all the same.
Post #1454195
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse