Skip to Content
0

Appending a string with param value while passing it to cmd

Oct 05, 2017 at 03:59 AM

34

avatar image
Former Member

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

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

3 Answers

Abhilash Kumar
Oct 05, 2017 at 08:38 AM
0

Hi Dev,

Which database are you reporting against?

-Abhilash

Share
10 |10000 characters needed characters left characters exceeded
avatar image
Former Member Oct 05, 2017 at 03:03 PM
0

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}~%'

Share
10 |10000 characters needed characters left characters exceeded
avatar image
Former Member Oct 05, 2017 at 12:54 PM
0

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

Share
10 |10000 characters needed characters left characters exceeded