Data Connectivity
 Crystal Reports Forum : Crystal Reports for Visual Studio 2005 and Newer : Data Connectivity
Message Icon Topic: .NET with more than one database Post Reply Post New Topic
Author Message
toekneel
Newbie
Newbie


Joined: 25 Apr 2008
Location: United States
Online Status: Offline
Posts: 6
Quote toekneel Replybullet Topic: .NET with more than one database
    Posted: 06 Aug 2008 at 3:28pm
I've been deploying Crystal Reports with .NET web applications for over five years now, and this is the first time that I have a group of reports pulling from multiple data sources.  The reports are built and run just fine, but when I attempt to deploy them through the applications, I can't get the logon information passed to the individual tables of the different sources.  I end up passing all of the logon information to the last datasource that is processed.
 
Can anyone pass along a sample of code where more than one datasource is used for a non-embedded report?
 
Thanks!
toekneel
ABQ, NM
IP IP Logged
BrianBischof
Admin Group
Admin Group
Avatar

Joined: 09 Nov 2006
Online Status: Offline
Posts: 2458
Quote BrianBischof Replybullet Posted: 09 Aug 2008 at 4:56pm

I don't know what code you are using to set the login info, but you can loop through the table collection and assign different login credentials to each table. Of course, you would need an If-Then logic to determine which table is currently being evaluated and set the approprieat login credentials based on that.

Please support the forum! Tell others by linking to it on your blog or website:<a href="http://www.crystalreportsbook.com/forum/">Crystal Reports Forum</a>
IP IP Logged
toekneel
Newbie
Newbie


Joined: 25 Apr 2008
Location: United States
Online Status: Offline
Posts: 6
Quote toekneel Replybullet Posted: 14 Aug 2008 at 9:16am
Hi Brian-
 
That is essentially what I'm trying to do, but the problem is that I can't figure out a way to indicate which tables are in which database.  What happens is that whatever the last item is that loops through, those credentials are applied to the table, even if it is for the wrong database.
 
Make sense?
 
Thanks!
 
 
toekneel
ABQ, NM
IP IP Logged
Post Reply Post New Topic
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum



This page was generated in 0.031 seconds.