on 11-24-2011 9:10 AM
hi,
in one of my crystal reports i'm invoking a procedure which has begin date and end date as parameters.when trying to run the report it's prompting for both date and time. my requirement is just to prompt for date and time is not required. the option of editing the parameter at the report level has been disabled since the parameters dierctly get invoked form procedure , in which i've declared the datatype as
samp_proc(p_begin_date date,p_end_date date,p_ref_cursor in out).
can someone help me on this.
Thanks,
Sailaja.k
hi waterman,
i need to control the date in the procedure parameters itself rathe rthan in the body for which i cannot use a trunc function in the procedure parameters.
thanks,
Sailaja.k
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi abhilash,
thnx for the quick response . i tried the first step as suggested in your reply by creating a subreport and linking hte formulas with dateime conversion.
the parameters are being displayed as date alone but the results are not beign seen in the main report , but i'm able to see the result in the sub report.
Thanks,
Sailaja.k
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Sailaja,
I'm not sure if this is a known issue or if this a bug, but there are workarounds.
Create a blank report and Insert the original report as a Subreport. Now in the Main report, create a Sttaic parameter of 'Date' type. Create a new Formula called 'Date_conv' and type this:
Datetime({?Date_parameter})
Place this formula on the Report Header and place the subreport on the Report Header too.
Right-click the subreport and select Change Subrpeort Links. Select the formula and move it to the Links to area. Next, from the drop-down on the bottom left select the datetime parameter of the subreport.
You may suppress all the other sections of the main report. The Report should now prompt for a 'Date' instead of the Date time.
Another workaround is by creating a registry key called useDateInsteadOfDateTime. Browse to HKEY_CURRENT_USER\Software\Business Objects\Suite 12.0\Crystal Reports\DatabaseOptions and create a string value called useDateInsteadOfDateTime. Set its value as the Database Server Name or the ODBC DSN name.
I would still recommend using the 1st workaround.
Hope this helps!
-Abhilash
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
If its a SP parameter then you must deal with it in the SP.
If Oracll you could try TRUNC() which converts datetime to date or SQL server 2008 use Cast(yourdatetimefield as date)
Ian
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
88 | |
10 | |
10 | |
9 | |
7 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.