Bruce Harrison
Posts: 0
Joined: Mon Apr 27, 2015 2:32 am

where parameter in a query service using local storage variable giving "Incorrect query" error

Hi,
I am trying to test a query Database service with a where parameter using local storage variable and it is giving me Incorrect query error.

This is what I have as value for my where parameter...
var myCity = localStorage.getItem('localcity'); return '{'"city":"'+myCity+'"'}';

localcity is the local storage variable. Please find the attached image.

Image

What is the mistake that I am doing?
Any help on this from anyone appreciated.
-Bruce

Serhii Kulibaba
Posts: 150
Joined: Tue Aug 27, 2013 1:47 pm

where parameter in a query service using local storage variable giving "Incorrect query" error

Hello Bruce,

It is not allowed to use JS on the test service page. You can use it only on service mapping: https://devcenter.appery.io/documenta...

Bruce Harrison
Posts: 0
Joined: Mon Apr 27, 2015 2:32 am

where parameter in a query service using local storage variable giving "Incorrect query" error

But Sergiy,
How do I get the the string that have in my local storage assigned to the where parameter of a query service ?

Please let me know.

-Bruce

Bruce Harrison
Posts: 0
Joined: Mon Apr 27, 2015 2:32 am

where parameter in a query service using local storage variable giving "Incorrect query" error

Hi Sergiy,
I got that where parameter taken care. I am good with that..

Now, I am getting objects from the GET service and I want to map it to a select component. How do I do that? Is there a step-by-step document that you can point me to?

-Bruce.

Bruce Harrison
Posts: 0
Joined: Mon Apr 27, 2015 2:32 am

where parameter in a query service using local storage variable giving "Incorrect query" error

Hi Sergiy,
Got that taken care as well. I am all set now :)

-Bruce

Return to “Issues”