Luis Lopes
November 22nd, 2004, 12:41 PM
First of all:
Thanks for the time lost in trying to resolve my problems,
I have 2 Diferent Databases and N Tables in each one.
----------------------------------------------
Database1 - TableA
CliCod --- CliName --- SalesMan
(…) (…) (…)
----------------------------------------------
----------------------------------------------
Database2 - TableA
UniqueKey --- CliName --- Value
(…) (…) (…)
----------------------------------------------
My problem is not to create the SQL Statement but where to put it (implement it).
Select a.*
From database2.TableA A
Inner join Database1.TableA B ON A.CliName == B.CliName
Where A.SalesMan= @Input String from User.
Please ber with me :(
All the examples I found are for 1 database - N Tables.
I want ->2<- databases - N tables
I think the best choice is to use the Push Model, so that I create a dataset to pass to crystal report, (and crystal report viewer).
But how can I create a dataset from 2 databases when the data adapter connectionString wants just one database to connect to.
How can I cross reference two Tables in different Databases into the same DataSet, so that I can pass this dataset into the Crystal Report.
I will be very grateful you could help me, because I can not find an example doing this any where.
The SQL statement would look something like this:
Thanks for your time.
Thanks for the time lost in trying to resolve my problems,
I have 2 Diferent Databases and N Tables in each one.
----------------------------------------------
Database1 - TableA
CliCod --- CliName --- SalesMan
(…) (…) (…)
----------------------------------------------
----------------------------------------------
Database2 - TableA
UniqueKey --- CliName --- Value
(…) (…) (…)
----------------------------------------------
My problem is not to create the SQL Statement but where to put it (implement it).
Select a.*
From database2.TableA A
Inner join Database1.TableA B ON A.CliName == B.CliName
Where A.SalesMan= @Input String from User.
Please ber with me :(
All the examples I found are for 1 database - N Tables.
I want ->2<- databases - N tables
I think the best choice is to use the Push Model, so that I create a dataset to pass to crystal report, (and crystal report viewer).
But how can I create a dataset from 2 databases when the data adapter connectionString wants just one database to connect to.
How can I cross reference two Tables in different Databases into the same DataSet, so that I can pass this dataset into the Crystal Report.
I will be very grateful you could help me, because I can not find an example doing this any where.
The SQL statement would look something like this:
Thanks for your time.