Solved

Date parameter in select query of the CrysReport

Posted on 2003-12-10
3
485 Views
Last Modified: 2006-11-17
Hi,
How do I use the Date parameter field in a report in the select query of the same  report.
ie,
I am calling the report from VB. Yes the parameter passes and I can get it in the report.

My SQL Query of the crystal report should look something like:
select <records> where accDate = <parameter field>

Thanks,
Ram
0
Comment
Question by:Cuddalore
  • 2
3 Comments
 
LVL 12

Expert Comment

by:DRRYAN3
ID: 9918106
Assuming your parameter is named dateparm, you refer to the entire parameter as {?dateparm} in formulas.

To pass the date to SQL, you may need to parse the parameter which is of date/time type to be of date type only using datevalue({?dateparm}).  Your version os SQL may also require that the date appear as a string, in which case your where clause would be

"...where accDate = '" + totext({?dateparm},"mm/dd/yyyy")

0
 

Author Comment

by:Cuddalore
ID: 9918402
Thanks Drryan3.
0
 
LVL 12

Accepted Solution

by:
DRRYAN3 earned 500 total points
ID: 9919909
Cuddalore

Did that clear things up for you?  If so, please take a moment and close this question.  If you need help with that, click on the Help link at your left.

0

Featured Post

Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

Join & Write a Comment

Crystal Reports: 5 Tests for Top Performance It is complete, your masterpiece report.  Not only does it meet your customer’s expectations, it blows them out the water, all they want is beautifully summarised and displayed in a myriad of ways. …
Hot fix for .Net Crystal Reports 10.2.3600.0 to fix problems with sub reports running on 64 bit operating systems ISSUE: Reports which contain subreports fail with error "Missing Parameter Value" DEPLOYMENT SERVER OS: Windows 2008 with 64 bi…
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now