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!

Authentication carrying to Subreport?

Status
Not open for further replies.

omninews

Programmer
May 8, 2003
10
0
0
US
I am using Crystal Report8.0. I created a Report with several subreports in it. I used IIS set up a web server with "Anonymous Access" off. So it use the UserID/Password to authenticate the users who tried to read the report. Once the user logged in, the user can view the main report. However, to view any of the subreports, the user has to enter UID/PWD the first time (within the session life time )for each of the subreports.
My question is , is there any way that we could carry the authentication from the main report to the subreports? So the user does not have to enter the UID/PWD for evey subreport.
Thank you!

OmniNews
 
Assuming you are using unmanaged reports, that means without CE. And what the popup asked for? If that is Database password, you can stored the password in registry.
If not, then what is the id/password used for?

Gook luck.
 
I am not using Crystal Enterprise Edition. The UID/PWD is Database UID/PWD.I do want the user to enter the UID/PWD for every major report. But once the user entered the major report, click on the subreport, the user does not like to enter the same UID/PWD again.
How do I use the regitry soted password? Do I have to write any script to do that?
Thank you!
 
Hi,
The subreport(s) need to be 'told' what the UID/PWD is..
user0@subreportname = and
password0@subreportname =
can be passed to the report when calling it( preferably
as a hidden form field in asp).

IIRC, the docs seem to say that if the same connection info is used for the subs, it should not prompt..But I cannot remember for that version...

[profile]
 
I am using Crystal Management Console to publish the reports. I define the login and passwords for the two databases. I also UNcheck the "Prompt the user for new value(s) when viewing" checkbox (reports are in a secured environment).
Once published the user is still asked for the login and password

In the asnwer by Turkbear, would I "link" these formulae from the main to subreport?

Any help will be appreciated
 
Hi, when publishing, did you specify the default user/pass combo and choose to use these on all reports that access those databases?

The answer I gave you was for 'unmanaged' reports, not published ones..For unmanaged ones, the @subreportname part handles the 'link' to the subreport...

( If the user supplies the username/password when prompted, does the report run correctly?)

[profile]
 
I can run the report locally (using Crystal report) but have never been able to get by the login and password requests. It keeps asking even as I supply the correct input
 
Meant to say

Cannot get by the login and password requests once I publish the report using CMC
 
Usually that means that the report cannot find the database
in order to authenticate the user/password.

What database is the source and can you connect to it when at the CE Server?

[profile]
 
You got it figured out for me. I did a "verify database" and on of the views was ill-defined.
Thanks for your help
 
Hi,
Glad it helped..The 'verify database' choice can be a lifesaver when odd things start to happen..It is one of the first things I use when debugging a previously working report....

[profile]
 
Response to Turkbear:
"IIRC, the docs seem to say that if the same connection info is used for the subs, it should not prompt..But I cannot remember for that version..."

Some patches got this issue fixd. I think it is CR 8.5. And so does CE 8.5. Shouldn't be prompted for database login again for those subreports if they are same connection info. Even if different...for CE 8.5, on the CMC database tab, supplying the correct connection information..should be fine. Try the latest CR 8.5 and CE 8.5 common patches.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top