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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Crystal Reports XI SQL/Oracle ODBC Through web using ASP

Status
Not open for further replies.

JasGrand

Programmer
Jan 8, 2003
144
CA
Hello, we are migrating from crystal 7 to crystal XI and it seems the reports are unable to be viewed over the web... I have downloaded the sample Active Server Pages (ASP) applications (aspxmps11.exe) from the business objects site which uses the Report Designer Component (RDC) to demonstrate functionality such as dynamically logging on to a datasource, changing selection criteria, and exporting a report at runtime. I have been able to view a report where the database is located within the same folder (access database) as the report but i am unable to view reports using ODBC connections (i have reports that link to both SQL server and Oracle databases). If anyone has any idea how I can make my reports work... please let me know. I am currently getting the following error: "Error Occurred Reading Records: Logon failed."

I don't see anywhere in the asp sample pages where the report does any connections to the database... so i'm assuming it is now stored within the report itself... Any help is appreciated...

Thanks,


Jason Grandmaison


 
Hi,
Are the DSNs used when you designed the report also configured on the Server running the web pages?




[profile]

To Paraphrase:"The Help you get is proportional to the Help you give.."
 
Hello, thanks for the reply. Yes the dns is setup on the server running the webpages... do you know if the report saves the connection information? it seems that the password isn't saved anywhere in the report... perhaps that could be the problem if all the connection is now handled through the report?

Thanks again,


Jason
 
Hi,
As far as I know, usernames/passwords for the database connection (except when using published reports in Enterprise or Crystal Server) are not saved ( a security feature) unless the DSN allows for it.

If you review the samples there may be info on how to specify the database logon info in youir calling code.



[profile]

To Paraphrase:"The Help you get is proportional to the Help you give.."
 
nope, they don't have anything that deals with connecting to an sql/oracle database... perhaps you have come accross an example?

Thanks,


Jason Grandmaison
 
Hi,
What about the examples shown in
SimpleSetLogonInfo.zip
or
SubreportLogonExample.zip

The code:
Code:
Set mainReportTableCollection = Session("oRpt").Database.Tables


For Each mnTable in mainReportTableCollection
  With mnTable.ConnectionProperties
   .Item("user ID") = "sa"
   .Item("Password") = "sa"
   .Item("DSN") = "Pubs Sample Database"
   .Item("Database") ="pubs"
  End With
Next

seems to be a place to start..




[profile]

To Paraphrase:"The Help you get is proportional to the Help you give.."
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top