SQL Expression in PARAMETER?

Posted on 2006-04-05
Last Modified: 2008-02-26
I have the following SQL Expression in my report. Is it possible to use this in a PARAMETER in order to use the PARAMETER in my SELECT CRITERIA? I don't see it as a data element to use, althought I am able to use it in the actual SELECT CRITERIA????

SELECT min([Applicable Date])


Question by:MIKE
    LVL 8

    Expert Comment

    Hi Mike, I've never tried to pass in the entire sql expression to parameter so I am not sure is there a way.
    But I would suggest you to alter the formula for select expert in runtime instead of pass in as parameter, this is the property you could you to alter your select expert's formula:


    LVL 8

    Expert Comment

    Sorry my mistake, what you are talking is SQL Expression but not select expert. Just ignore my suggestion.

    LVL 17

    Author Comment

    Actually Dylan, I just used the MIN of the actual date field [APPLICABLE DATE] for the report. I just wanted to display the TO FROM REPORTING DATES in the header. I WAS using the parameter to do this, but had to change this. The paramter WAS a SQL Expression.l

    I hope I'm making sense, but anyway thanks for the input....I just did a MIN(APPLICABLE DATE] for the FROM and a MAX[APPLICABLE DATE] for the TO date.

    LVL 26

    Accepted Solution

    Hi Mike,

    You can't use Formulas or Parameters within a SQL Expression.  You can only use true database fields, database functions are are available through your DB and method of connectivity (ODBC, for example) and true SQL recognized by your database.

    You can, however, refer to a SQL Expression from within a formula or the record selection criteria.


    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Highfive Gives IT Their Time Back

    Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

    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. …
    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…
    In this sixth video of the Xpdf series, we discuss and demonstrate the PDFtoPNG utility, which converts a multi-page PDF file to separate color, grayscale, or monochrome PNG files, creating one PNG file for each page in the PDF. It does this via a c…
    Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…

    737 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

    20 Experts available now in Live!

    Get 1:1 Help Now