Skip to Content (Press Enter)
OutSystems.com
Personal Edition
Community
Support
Training
Training
Online Training
Developer Schools
Boot Camps
Certifications
Tech Talks
Documentation
Documentation
Overview
ODC
O11
Forums
Forge
Get Involved
Get Involved
Jobs
Ideas
Members
Mentorship
User Groups
Platform
Platform
ODC
O11
Search in OutSystems
Log in
Get Started
Back to Forums
prashanth charl
4
Views
5
Comments
search functionality not working
Question
Hi All,
I have a Testwebscreen_List screen where i have search input widget and search,reset buttons.I am assigning the search value entered in input widget to a session variable of type text and calling an stored procedure by using Advanced Query.Based on fileterd value entered in input search widget I am getting the result set and able to show it in RecordList in output screen.But problem is when i search with a text that has an single empty space in search keyword (Ex:Server Connectivity) then i am getting an error shown below.I have verified the stored procedure by executing in my database and it is working fine with searchinput that has single empty space in between the searchinput.
Error in advanced query TestSP in Preparation in Testwebscreen_List in MainFlow in [dbo].[usp_TestSP_SearchParam] @SearchParam): Incorrect syntax near 'Connectivity'
Thanks,
Prashanth
J.
MVP
please provide an oml.
what database are you using?
how does the adv. query looks like
how are the input parameters defined?
1 reply
13 Mar 2013
Show thread
Hide thread
prashanth charl
Statler & Waldorf
wrote:
please provide an oml.
what database are you using?
how does the adv. query looks like
how are the input parameters defined?
Hi,
The database is:SQLServer 2008.For more details please find the attached doc.Waiting for your help.
Thanks,
Prashanth
Issue Advanced Query.docx
J.
MVP
erm, should you not enclose the parameter with single-quotes? thus something like EXEC spName '@parameter'
if you have a space with quotes, sql-server prolly thinks you got 2 parameters provided and then it goes *poof* because your SP only has 1 parameter
1 reply
13 Mar 2013
Show thread
Hide thread
prashanth charl
Statler & Waldorf
wrote:
erm, should you not enclose the parameter with single-quotes? thus something like EXEC spName '@parameter'
if you have a space with quotes, sql-server prolly thinks you got 2 parameters provided and then it goes *poof* because your SP only has 1 parameter
Hi,
You mean i need to enclose the searchparameter in single quote like this: EXEC spName '@Searchparameter' in advanced query?
I tried above syntax but it is not working.If i enclose the searchparameter in single quote i am not able to see anything in output screen.So what i did is for SearchParamter we have property called :ExpandInline.By default its value is
Yes
.I set it to
No
then everything is working fine now without enclosing the @SearchParameter in single quote.Please correct me if my understanding is wrong.
Thanks
Prashanth
J.
MVP
All I was trying to say was that if you don't enclose it with quotes the sql might think of it as 2 parameters or some weird behaviour.
https://www.outsystems.com/help/servicestudio/7.0/default.htm#Using_Data/Advanced_Query_Parameter_Properties.htm
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting.
See the full guidelines
Loading...