[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

Date parameter in select query of the CrysReport

Posted on 2003-12-10
3
Medium Priority
?
545 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 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 1500 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

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I hate sub reports and always consider them the last resort in any reporting solution.  The negative effect on performance and maintainability is just not worth the easy ride they give the report writer.  Nine times out of ten reporting requirements…
Hello everyone, Hope you find this as helpful as we did. We have on the company I work for an application built in Delphi V with Crystal Reports 8. We all know that Crystal & Delphi can be temperamental sometimes and the worst thing is, nearly…
We’ve all felt that sense of false security before—locking down external access to a database or component and feeling like we’ve done all we need to do to secure company data. But that feeling is fleeting. Attacks these days can happen in many w…
Is your data getting by on basic protection measures? In today’s climate of debilitating malware and ransomware—like WannaCry—that may not be enough. You need to establish more than basics, like a recovery plan that protects both data and endpoints.…

649 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