locked
Unnamed Parameters RRS feed

  • Question

  • Hi im using Reporting Services 2008 connecting to Oracle with an Oracle OLE DB.

    The problem im having is how to reuse a unnamed parameter?

    For eg,

    SELECT a, COALESCE(b, ? ), c FROM tblDetails

    WHERE DATE(Trans_Date) BETWEEN ? and ?

     

    The first parameter is actually suppose to be the same with the second parameter where by for any selected row without a date in the date column, put in the first day of the range of date set in the WHERE clause.

     

    However, I cant find a way to reuse the first parameter or either make the first parameter and the second parameter to be equal to each other so that the users only have to key in 2 parameters in total instead of 3.

    Any ideas?

    Thanks in advance

    Dave

    Wednesday, March 9, 2011 4:18 PM

Answers

  • Hi Dave,

    Here your issue is relevant to Oracle query language and you didn't give your dataset's structure, just based on your Query, I think you could create a store procedure with two parameters(Named:Para1,Para2), then give Para1's value to the first? and second? in your query.

    Actually, there is no need for you to return parameter's value to dataset from your query, you could get all the parameters' value on your report completely when you need.

    Thanks,


    Challen Fu [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    • Marked as answer by Challen Fu Thursday, March 17, 2011 9:57 AM
    Thursday, March 10, 2011 6:12 AM