Crystal 7.0 & MSS 7.0 stored procedures 
Author Message
 Crystal 7.0 & MSS 7.0 stored procedures

All,

We are developing an application using VB 6.0,
Crystal Reports 7.0 and MS SQL Server 7.0.  All
of our reports are tied to MSS via stored
procedures using the native SQL Server driver.
Our application can access one of three databases
depending on where they are located.  The reports
need to be executed on whichever db they are
connected to.  How can we dynamically set the
database name for these reports ?

Scott.....

Sent via Deja.com http://www.*-*-*.com/
Share what you know. Learn what you don't.



Tue, 05 Feb 2002 03:00:00 GMT  
 Crystal 7.0 & MSS 7.0 stored procedures
You need to use Crystal report automation to set the DSN dynamically.
Essentially create an Cr Application object, set the database location
for the report and its reports. I read this some where in the web.

Sankar


Quote:

> All,

> We are developing an application using VB 6.0,
> Crystal Reports 7.0 and MS SQL Server 7.0.  All
> of our reports are tied to MSS via stored
> procedures using the native SQL Server driver.
> Our application can access one of three databases
> depending on where they are located.  The reports
> need to be executed on whichever db they are
> connected to.  How can we dynamically set the
> database name for these reports ?

> Scott.....

> Sent via Deja.com http://www.deja.com/
> Share what you know. Learn what you don't.

Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.


Wed, 06 Feb 2002 03:00:00 GMT  
 Crystal 7.0 & MSS 7.0 stored procedures
Hi!

You can change the sp location dynamically by doing the following

1. crTestiRapsa.ReportFileName = "W:\Wallstreet\sp_rTiliote.rpt"
 2.crTestiRapsa.Connect = goADOCN

3. crTestiRapsa.DataFiles(0) = "WintraderTesti.dbo.spWS_repTiliote"

 where

2. goADOCN is a global  ADO connection object which is open and active
3. This method tells the cr object where the sp is, basically you can
use this syntax on any legal object on sql
cr.datafile(<index>)="DBNAME.OWNER.OBJECTNAME"

At least it did it for me I am now able to change my reporting database
and sp on fly when ever needed.

ps. If you are using sp_s you can avoid the awkward cr datehandling by
sending the date parameter to the sp as char(8) string and
doing whatever you like with it at the db level.

Quote:

> All,

> We are developing an application using VB 6.0,
> Crystal Reports 7.0 and MS SQL Server 7.0.  All
> of our reports are tied to MSS via stored
> procedures using the native SQL Server driver.
> Our application can access one of three databases
> depending on where they are located.  The reports
> need to be executed on whichever db they are
> connected to.  How can we dynamically set the
> database name for these reports ?

> Scott.....

> Sent via Deja.com http://www.deja.com/
> Share what you know. Learn what you don't.

--
To reply to me remove the  NoSpam from my address
All opinions on this message are mine and mine alone'


Fri, 08 Feb 2002 03:00:00 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. CR8 & VB , Stored Procedures SQL 7.0

2. problem passing data from ASP to a Stored procedure in SQL 7.0

3. SQL 7.0 Stored Procedures and Visual Database Tools 1.0

4. Does MS Access 7.0 support stored procedures?

5. SQL 7.0 Stored Procedures and Visual Database Tools 1.0

6. Using SQL 7.0 stored procedures as record source for report

7. Passing Tabular data to a SQL 7.0 Stored Procedure

8. Visual Foxpro 7.0 stored procedure

9. Sybase Anywhere 7.0 stored procedure call fail

10. Help - SQL 7.0 , ADO 2.5 , Store Procedure , VB6 and MSDataGrid

11. Stored procedures in SQL6.5 and SQL 7.0.

12. VB 4.0 & Access 7.0 Crystal Reports

 

 
Powered by phpBB® Forum Software