Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Reports running against SQL server

Status
Not open for further replies.

shortstuff2212

Programmer
Apr 12, 2002
35
0
0
GB
I am currently using Crystal Reports version 7 and I have customers who use access 97 and sql server. I currently have to desing 2 seperate reports, is there a later version of Crystal report which allows me to define a report that will run against Access97 and SQL Server without doing two reports?
 
If you want to run against both, I though that you could do so in 7 (though the performance will be bad), unless you're trying to report on Access OR SQL Server, for that, you'd have to cheat.

One option is to:

You can import either the Access data into SQL Server, or import (or link might be the best) the SQL Server data into Access to provide a single datasource.

Provide a little more specific information about what you mean by use both, is this both as a single data source, or one or the other depending upon the client.

You might be able to cheat the latter using a parameter and either suppressed sctions or subreports.

-k kai@informeddatadecisions.com
 
We cannot use both as a single data source because different customers use different databases. Some use Access97 and others use SQL Server.
 
Can't you create the report in one version and then convert the database drivers to make it work for the other version?

Christine
Crystal Training and Consulting
crosenbaum@Strafford.com
 
I have already done that, but it involves having two sets of reports, one for Access and one for SQL. With two sets of reports it is difficult to maintain version control and I just wondered if it was possible to keep just one set of reports which will work on any db
 
Yes, you can but your difficulty is that the tables must be identical in both cases. You can do what you want by using "Set Location" to point at a different database but unless the tables map perfectly you will asked by Crystal to make adjustments Jim Broadbent
 
An ugly way would be to maintain the 2 different reports as subreports, with a parameter to suppress the report that isn't applicable for the user.

It still requires 2 reports, but it would present itself as a single report, and the maintenance would be done within a single report, albeit twice in most cases.

The only way I can think of otherwise is to use code (such as VB).

-k kai@informeddatadecisions.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top