Link to home
Start Free TrialLog in
Avatar of Sriprabha
Sriprabha

asked on

using adodb connection while calling crystal report

Hi All,
    I am having a connection, opened in  my VB project.When i am calling the crystal report,It's loading
very slowly. In The crystal .rpt file,I am calling a stored procedure with maximum of 10 parameters.

     Is it slow,because of the crystal report  connection?.
     If is it so,How can i use the same dsnless
connection in my project?

Thanks in advance
Sri Prabha
ASKER CERTIFIED SOLUTION
Avatar of VBMeera
VBMeera

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Sriprabha
Sriprabha

ASKER

Hi vbmeera,
       Crystal report Parameter field accepts only 255 chars.But I am sending the Query which is Dynamically generated according to the Multiselect listbox in my VB form.It will surely exceed 1500 chars.I can't reduce the no of parameters.
       one more thing.While executing the stored procedure through the query analyzer it's pretty fast only.
       The above one is my requirement.But I am having the
doubt that whether there is a method to use the connection in VB which is already created.Is there any methodfor this.

Thanks for u'r response

Regards
Sriprabha.

hey do one thing,
send me u r SP code which u used thr VB.
i will thing u r creating parameter ,appending it
am i right?
it might conflicting u r datatypes?
send those 4-5 lines where actual call for SP
Thanks for u'r immediate response.

     While Running through the query analyzer it's fast enough only.While calling the stored procedure in the crystal report,during the first time it's slow.I am very much sure that there is no problem in my SP.

     You just tell me that,whether there is a way to use the connection created in vb.

Regards,
Sriprabha

hey ,
i am not telling u that there is pro in ur SP what i am trying to tell u that while calling thr vb u r passing parameter to ur SP and then u r getting O/P as .rpt file.
so do pass parameter u need to creat it and then append that parameter ,isn't it?
design .rpt file is one task and call that rpt file thr vb is different.(this what i
create object connection,command and Recordset object  
and call SP using Command
if u need code tell me
okay.
I know that vbmeera.

    I have created the .rpt file.While creating it,i have opted SQL-ODBC dsn connection.
    I am calling the SP with the command object only.

     Because mine is a multiuser project the connection will open for the every first call of the .rpt file  .This may slow down the SQL sever.
      My argument is that,Already one connection is there.Why can't we use that one?.It will increase the speed of the application.

Thanks for u'r response

Regards
Prabha
I know that vbmeera.

    I have created the .rpt file.While creating it,i have opted SQL-ODBC dsn connection.
    I am calling the SP with the command object only.

     Because mine is a multiuser project the connection will open for the every first call of the .rpt file  .This may slow down the SQL sever.
      My argument is that,Already one connection is there.Why can't we use that one?.It will increase the speed of the application.

Thanks for u'r response

Regards
Prabha