Skip to Content

Appending a string with param value while passing it to cmd

I need to achieve the following query for My cmd.

Select a.Name

From table-A a

Where a.msg like '%{?param}&"~"%'

Crystal report processes the query without syntax error but does not return any records.

The table has records in the msg column like g130~Mfger~

I am getting my user to input g130 through the prompt.

Could some one help me with the syntax pleas

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

3 Answers

  • Oct 05, 2017 at 08:38 AM

    Hi Dev,

    Which database are you reporting against?

    -Abhilash

    Add comment
    10|10000 characters needed characters exceeded

  • Oct 05, 2017 at 03:03 PM

    I solved the problem by dropping the "&" sign now the report returns the exact # of records from the table. Modified where condition:

    Where a.msg like '%{?param}~%'

    Add comment
    10|10000 characters needed characters exceeded

  • Oct 05, 2017 at 12:54 PM

    Thanks for your reply ,It's SQL 2012and crystal report is cr2013!

    Add comment
    10|10000 characters needed characters exceeded