Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 10665

Report fails after changing parameter names

$
0
0

Hello,

 

It has been our practice ( using the old asp SDK ) to use a single .asp file to call reports.

 

This scenario works in .asp

* Report based on stored procedure

* stored proc has parameter names like @hospital, @start_date ( all passed in as varchar )

* the parameter name within Crystal Reports XI is changed to @P1, @P2 ( with the order of the params preserved )

* a single asp file processes ALL report calls for the entire application, and passes parameters to the report @p2, @p2 etc

 

I attempting to re-produce this programming with CR4E and Crystal Reports 2005 with a single .jsp file. using JDBC datasources to MSSQL2005.

 

I can get the report to work when i pass in the named parameter, eg:

 

CRJavaHelper.addDiscreteParameterValue(clientDoc, ", "@hospital, "12345");

 

 

 

however, when I change the parameter within Crystal Reports 2001 to @P1 the report calls fail. ( naturally i now use "@P1" in the above line)

The error I get is:

Error
Index: 0, Size: 0

 

It is as if the renamed parameter is still internally mapped to its orginal name or the report loses the mapping between the name of the parameter within the report to the parameter within the stored procedure?

 

Please tell me if this is possible? It is the last obstacle to overcome so I can retire the old asp SDK stuff.

 

Do you have any ideas on how to achieve this? I do not think we can maintain different .jsp files for each report.

 

 

Thanks,

 


Viewing all articles
Browse latest Browse all 10665

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>