Select to view content in your preferred language

Esearch - Error 1009

4606
29
Jump to solution
08-28-2012 07:18 AM
Scott_Russell
Regular Contributor
Hello,

I posted a question similar to this in the Flex API forum yesterday.  I am attempting to perform a SQL query for a TEXT field that is in our Valves feature class.  The field is an ID number field but also contains letters. I'd like the user to have the ability to type in a valve number and successfully select it.  Here is what I have so far:

<configuration>
    <layers>
        <layer>
            <definitionexpression/>
            <enableexport>true</enableexport>
            <name>Valves</name>
            <url>http://valhalla:6080/arcgis/rest/services/WebMap/MapServer/9</url>
            <expressions>
                <expression alias="Valve ID Search" textsearchlabel="Search Valve ID:">
                    <values>
                        <value prompt="Example:100">FACILITYID = '[value]'</value>
                    </values>
                </expression>
            </expressions>
            <graphicalsearchlabel>Use one of the graphical search tools to select Valves</graphicalsearchlabel>
            <spatialsearchlayer>true</spatialsearchlayer>
            <titlefield>FACILITYID</titlefield>
            <fields all="true"/>
            <links/>
            <zoomscale usegeometry="true" zoompercent="2"/>
        </layer>

Keep in mind that although this is a field used for IDs and most values are numeric, the field is a TEXT field which contains letters in some cases.

When I attempt to perform the above action I receive Error #1009.  What am I doing wrong?  I have confirmed that FACILITYID is the field alias within the table.  I determined the URL by clicking on the Valves layer link in the REST services URL in ArcGIS Server.

Thanks,
Scott

EDIT: I'd like to point out that FACILITID = '[value]' yields results in the default Search widget in the Flex Viewer.
Tags (2)
0 Kudos
1 Solution

Accepted Solutions
RobertScheitlin__GISP
MVP Emeritus
Scott,

   As mentioned in the couple of post above there is a bug when not specifying a dateformat in the eSearchWidget.xml and because you choose to use fields all = "true" you ended up encountering this error. I will have this fixed in version 3.0.8 along with some other great little additions. So make sure you stay current with the releases of this widget.

Don't forget to click the Mark as answer check on this post and to click the top arrow (promote).
Follow the steps as shown in the below graphic:

View solution in original post

0 Kudos
29 Replies
RobertScheitlin__GISP
MVP Emeritus
Scott,

   What version of the eSearch are you using? If you are at Flex Viewer 3.0 than you need to be using the latest eSearch Widget Version 3.0.7. To check which version of eSearch you are using launch the viewer and the eSearch widget and hold the alt key and click on the "Enhanced Search" widget title.
0 Kudos
Scott_Russell
Regular Contributor
Scott,

   What version of the eSearch are you using? If you are at Flex Viewer 3.0 than you need to be using the latest eSearch Widget Version 3.0.7. To check which version of eSearch you are using launch the viewer and the eSearch widget and hold the alt key and click on the "Enhanced Search" widget title.


Looks like I am using version 3.0.6.  Well, this turned out to be embarrassing!!

Thank you very much for your speedy reply and great widgets that you have available!!

Thanks,
Scott
0 Kudos
Scott_Russell
Regular Contributor
Hello Robert,

I removed the Widget from the 3.0 Flex Viewer.  I re-downloaded the eSearch widget from the following location:

http://www.arcgis.com/home/item.html?id=5d4995ccdb99429185dfd8d8fb2a513e

After implementing eSearch again, I verified the version and it still says 3.0.6, Build date 8/15/2012.  Is the download link pointing to the wrong file?  I am still having the same problem with error #1009.  I apologize for the mix-up, I should have replied earlier and tested this right away.

Any ideas? In the 'Manage Customer Widgets' interface, the eSearch widget is listed as version 3.0.7.
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Scott,

   I just downloaded form that link and get 3.0.7... The fact that the widget reports as 3.0.7 in App Builder leads me to believe you are good. Can you attach your eSearchWidget.xml file? Maybe you deleted something that you should not have.
0 Kudos
RhettZufelt
MVP Notable Contributor
Hello, 

I posted a question similar to this in the Flex API forum yesterday. I am attempting to perform a SQL query for a TEXT field that is in our Valves feature class. The field is an ID number field but also contains letters. I'd like the user to have the ability to type in a valve number and successfully select it. Here is what I have so far: 

<values> 
<value prompt="Example:100">  FACILITYID = '[value]'</value> 
</values> 
  
EDIT: I'd like to point out that   FACILITID = '[value]' yields results in the default Search widget in the Flex Viewer.


are you sure you have the item spelled correctly? In your two examples, one that works, one that doesn't, you have different spelling. not sure if that is just a typo in the email or in your expression as well.

R_
0 Kudos
Scott_Russell
Regular Contributor
are you sure you have the item spelled correctly?  In your two examples, one that works, one that doesn't, you have different spelling.  not sure if that is just a typo in the email or in your expression as well.

R_


Yikes!! Thanks for pointing that out, but it was a typo on my end when I was quickly editing my post.  I double checked and the value is the same on my end.  Thank you for that!!



Scott,

   I just downloaded form that link and get 3.0.7... The fact that the widget reports as 3.0.7 in App Builder leads me to believe you are good. Can you attach your eSearchWidget.xml file? Maybe you deleted something that you should not have.


OK Robert, attaching .xml file to this post.  I attached the eSearch.zip that I am pointing to from the Flex Viewer.  Let me know if you need me to extract and send only the .xml. Thank you!!

Scott
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Scott,

   No I need the eSearchWidget.xml where you have changed it to point to your data.
0 Kudos
Scott_Russell
Regular Contributor
Scott,

   No I need the eSearchWidget.xml where you have changed it to point to your data.


I only edited one small section at the beginning.  I copy/pasted the xml code into Notepad++ to work with it.  I saved that file, it is attached to this post.  I had to zip it to get it under the size requirement.  I left the default settings for most of the functionality, since I'm not sure exactly what I'll do with it yet.

Thanks,
Scott
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Scott,

   Do you happen to have the ObjectID and/or Shape fields hidden for this layer in the MXD?
0 Kudos