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

Issue with Use DSN Default Properties

Status
Not open for further replies.

inspi

Technical User
May 24, 2006
50
US
I have a crystal report which uses a Stored Procedure as data source(which has 4 IN parameters). when I run this from designer in dev environment it works fine. At this time if we go to set data source location "Use DSN Default Properties:" set to "False" and under procedure properties "Overridden Qualified Table Name:" is blank. Now I would like to change this properties to "Use DSN Default Properties: True" and "Overridden Qualified Table Name:give procedure name(PROC_NAME)".But if I change this properties report is giving error while running, it is saying "failed to retrieve data from the database" "wrong number or types of arguments in call to "Procedure Name". When I checked the show sql query it is trying to pass 8 parameters instead of 4 like this {CALL PROC_NAME('abc', {ts '2010-04-01 14:07:46'}, {ts '2010-04-28 14:07:49'}, 'def', NULL, NULL, NULL, NULL)} which is wrong. I am not understanding why is it passing NULL values at the end.when I changed the properties to "Use DSN Default Properties: False" and "Use DSN Default Properties:" to blank it is running fine and it is passing only 4 parameters as expected like {CALL PROC_NAME('abc', {ts '2010-04-01 14:07:46'}, {ts '2010-04-28 14:07:49'}, 'def'}. But I need those properties to set like as I mentioned above because whenever I deploy this report on any environment whose report server pointing to any database has the same DSN name which we have in the rpt then no need of updating procedure in the rpt with the procedure in the new environment DB that is simply no need of changing/updating rpt..we can directly deploy it on any environment wherever we have tables/procedures/views on that DB which we used in rpt. I don't have this problem wherever I used tables in the rpt instead of procedure. It seems problem is with procedure as datasource. There is no problem with the procedure at all, this executes fine on DB and even in crystal if I don't change those properties.
Any help appreciated. Thanks!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top