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

CE10 - Problems with URLs

Status
Not open for further replies.

gav12345

Programmer
Dec 4, 2003
198
GB
Hello,

I'm trying to call a report in CE10 using a URL string and am having a few problems with the promptex command. When I call the report without trying to pass parameters, I'm prompted for the parameter and the report then runs fine and brings back all relevant data, i.e.:
Code:
[URL unfurl="true"]http://0007322/crystal/enterprise10/admin/en/viewrpt.cwr?id=648&apsuser=BBloggs&apspassword=BBloggs&apsauthtype=secEnterprise[/URL]

However, as soon as I add the promptex command, the correct report is returned, but no data appears. i.e.:
Code:
[URL unfurl="true"]http://0007322/crystal/enterprise10/admin/en/viewrpt.cwr?id=648&apsuser=BBloggs&apspassword=BBloggs&apsauthtype=secEnterprise&promptex-Media%20Volume%20Name="Archive001"[/URL]

I've tried various things including adding & removing quotation marks and changing the order of the URL string parameters, but to no avail...

Any suggestions? Cheers.

Gavin
 
You might need to mess around with the encoding of special characters (eg - those double quote marks). You could also switch to non-named prompts.

prompt0=%27Archive001%27


There is a knowledge base article on encoding. I will look around.
 
Thanks pelajhia, I'm getting partial success with your first suggestion (prompt0=%27Archive001%27). - By partial I mean that when I type in the string:
Code:
 [URL unfurl="true"]http://0007322/crystal/enterprise10/admin/en/viewrpt.cwr?id=648&apsuser=BBloggs&apspassword=BBloggs&apsauthtype=secEnterprise&prompt0=%27Archive001%27[/URL]

...I still get no data back. However, if I then change it to:
Code:
[URL unfurl="true"]http://0007322/crystal/enterprise10/admin/en/viewrpt.cwr?id=648&apsuser=BBloggs&apspassword=BBloggs&apsauthtype=secEnterprise&prompt0=Archive001[/URL]

...(i.e. without the '%27's) hey presto, I suddenly get data back. - The problem is, if I then copy and paste the second URL into a freshly opened browser, I'm getting no data again.

Any other suggestions? - If not, thanks for getting me this far anyway.

Gavin
 
It is not clear to me how the url is being pulled in the middle example, where it is actually working.
That is, is it a link on a page? In an email? Run via custom app?
 
Thanks for your comments Lisa and pelajhia. Same problem so far unfortunately. pelajhia, the url is just being typed / pasted directly into the browser address bar (although it will eventually be a hyperlink from a web app.). If its any more help, I've also found the following:

If I use the following link, no data is returned:
Code:
[URL unfurl="true"]http://0007322/crystal/enterprise10/admin/en/viewrpt.cwr?id=648&apsuser=BBloggs&apspassword=BBloggs&apsauthtype=secEnterprise&prompt0=Archive001[/URL]

..but if I then change the parameter value (from 'Archive001' to 'Archive002' and hit enter, data is returned, i.e.
Code:
[URL unfurl="true"]http://0007322/crystal/enterprise10/admin/en/viewrpt.cwr?id=648&apsuser=BBloggs&apspassword=BBloggs&apsauthtype=secEnterprise&prompt0=Archive002[/URL]

- I hasten to add that there is definitely data there, because if I then change the parameter back to the original value ('Archive001') and hit enter, I get data. - Pasting that 'working' link into a new browser again brings back no data.

Feel I'm missing something fairly basic/fundamental, but can't think what....

Thanks guys.
 
Sounds like you are seeing some odd manifestation of a refresh problem, now that you are managing to pass the parameter. The first time it takes it, the second time...not (which I find odd).
To test this you can switch to Archive002, and try it twice. If it fails the second time, you might try something like this -
I was given this 'always refresh' url parameter to insert if I had reports which ALWAYS need to be refreshed. Just see if it helps at all:

&connect=1

example:

Not entirely sure this will help, and I think it only works on the latest CE versions.
 
ps - I meant to say, I was given this parameter by crystal support folks. It helped my problem, but it wasn't exactly what you are seeing.
 
pelajhia, thanks again for all your help. Unfortunately I'm still having no luck. I've exhausted almost every setting I can think of. I've tried messing around with the Crystal server cache settings, internet explorer settings, setting rights for all users to Full Access, setting up the CMS audit database (for clues!), changing viewer types (since dhtml uses the RAS server) and restarting all the servers numerous times with no success. The last thing I'm going to try is setting up CE10 on a Windows 2000 server (its using XP Pro just now, which the documentation seems a bit ambiguous about), see if that makes any difference. I'd welcome any other suggestions, but otherwise cheers for your help and I'll post if I have any success. Gavin
 
Well, I would let it go, but you did not mention whether you did the test I suggested. Do both urls fail upon a 2nd retry?
Also I am assuming that the connect=1 did not work, but you did not list that in your last note as something you attempted.
Assuming those are both 'yes', another OS does sound like a good idea. Good luck!

 
Hi pelajhia, thanks for your persistence! - Yes, I meant to mention that I did try your suggestions. In summary, whatever I try, I can never bring back data on the first attempt (immediately after typing / pasting the URL string into a new browser window and hitting Enter).

If I then change the parameter in the URL string to another valid value and hit enter, I will get back data. If I refresh the same page, I will get data back again, and so on. If I then change the parameter back to the original value (which did not bring back data at the first attempt), I will then get my data.

If I go back and paste the 'working' string into a fresh browser address bar, I'm back to square 1 with no data.

I did try your 'connect=1' suggestion, which had the result of me never getting back any data, however many refreshes / different values I tried.

I've also just installed CE10 on Win2000 Server O/S, but am having exactly the same problem.

Any other ideas? Cheers again, Gavin
 
What browser/version are you using?
Is CE installed using the default MSDE or another db type? Is the apsuser a concurrent access user, or named?
Just trying to fill in some details...
 
What type of data source is the report pulling from? Do you have any other reports running against same datasource? Same problem with these, or not? Do you have other reports accessing different data source? Same problem with these or not?
If you don't have these other reports, you might consider building them for testing to help localize the problem.
 
Hi pelajhia,

Very strange! - The report(s) I've tried are running against an Oracle database. Very simple test reports, just one column and one parameter. I've set up a trace on the database (which I should have done ages ago really) and whats happening is this:

When I first enter the URL string, crystal queries the Oracle database for all values for the relevant report field (i.e. it ignores the input parameter altogether). This first query takes a long while to run. If you then try the URL string for a different parameter value, Crystal seems to be querying against a cache of the data it retrieved last time, but this time it does use the parameter value to bring back data (and as a result of using the cached data, also brings a the data back far quicker). Seems bizarre, any ideas why its doing this?!

No, I haven't yet tried running parameterised reports agaist a different data source, but will try that just now. I also thought it might be a Crystal reports version problem (using 8.5 for the test reports), so am going to try the same reports in V's 9 and 10.

Thanks again, Gavin
 
I still think you need quotes around your parameter value. All the URL's that I use require them to work correctly, no matter what the datatype. I am on 9 now but they have been that way since 10.

I would think it should look something like:


I also never had very good luck using the prompt0, prompt1 and had better luck using the promtex-paramname=..


Lisa
 
Finally working! - I tried running the same report saved as a CR9 report and it worked first time. I guess CR8.5 and CE10 don't always go all that well together. Thanks for all your help guys, very much appreciated. - Can finally start the work what I was supposed to be doing on Monday! Gavin
 
(using 8.5 for the test reports) - oops, definitely a question we all should have thought of a while back! Glad it's finally working. Yes, CR 8.5 is not supposed to be used via either CE 9 or 10.
 
Hi,
Sorry, but I have several dozen CR 8.5 Reports published just fine to CE 10 and even a few unmanaged ones that use the URL-type invocation..No problems yet.

CE10 is compatible with most earlier versions of Crystal Reports ( at least since v7, I think)

Just my 2c
[profile]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top