Select to view content in your preferred language

Query data without a map Help

2580
3
Jump to solution
01-20-2016 07:48 PM
MeganWirth
Frequent Contributor

Trying to add my own map service to the provided example but having no luck getting it to work. any help would be appreciated. I really just need a few fields from my service returned. i.e. Name, Docket_Number, PRM_Pre_App_Meeting

esri example https://developers.arcgis.com/javascript/jssamples/query_nomap.html

my map service http://services1.arcgis.com/1vlgiUCSf9FiT4I0/arcgis/rest/services/Subdivisions_Proposed/FeatureServe...

Thanks in advance

Tags (2)
0 Kudos
1 Solution

Accepted Solutions
KousikM
Occasional Contributor

Ryan,

You need to add Where property on Querying your map service. I have added your map service and I pointed the field Name from your service like,

query.where = "Name = '" + dom.byId("stateName").value + "'";

I have added that sample.

View solution in original post

3 Replies
KousikM
Occasional Contributor

Ryan,

You need to add Where property on Querying your map service. I have added your map service and I pointed the field Name from your service like,

query.where = "Name = '" + dom.byId("stateName").value + "'";

I have added that sample.

MeganWirth
Frequent Contributor

Thank you Sir! I see what you did there. I am obviously ignorant when it comes to js, but I am trying to change that. thanks again.  

0 Kudos
MeganWirth
Frequent Contributor

Sorry if i am over reaching. Is there a simple way to display the date fields in the query result as a an actual calendar type date?

0 Kudos