Select to view content in your preferred language

Problem using multiple expressions in eSearch 3.1

2296
16
Jump to solution
01-28-2013 06:09 AM
JustinFultz
Regular Contributor
I am trying to upgrade my flex application to 3.1 and am having problems with the eSearch widget. I have a multiple expression search that worked fine at 2.5. When I upgraded to 3.1 and the newest eSearch widget the multiple expression automatically runs when I fill in the first value and I never have the oppurtunity to select the second value. I have tried all different combinations of isvaluerequired, all with the same result. Below is the config for this particular expression. Any help would be appreciated.

<expression alias="Tie Lines" textsearchlabel="Select TO's to display tie lines..." isvaluerequired="true">      <values>       <value prompt="Select Area..." isvaluerequired="true" userlist="AECI,AEPW,AMMO,CLEC,EES,EMDE,GMO,GRDA,INDN,KACY,KCPL,LAFA,LAGN,LEPA,LES,MEC,MIDW,NPPD,OKGE,OMPA,OPPD,SPRM,SPS,SUNC,SWPA,WAPA,WERE,WFEC"> UPPER(SDE.SPP_TIE_LINES.TIE_NAM) LIKE UPPER('%[value]%')</value>       <value prompt="Select Area..." isvaluerequired="true" userlist="AECI,AEPW,AMMO,CLEC,EES,EMDE,GMO,GRDA,INDN,KACY,KCPL,LAFA,LAGN,LEPA,LES,MEC,MIDW,NPPD,OKGE,OMPA,OPPD,SPRM,SPS,SUNC,SWPA,WAPA,WERE,WFEC" operator="AND"> UPPER(SDE.SPP_TIE_LINES.TIE_NAM) LIKE UPPER('%[value]%')</value>      </values>      </expression>
Tags (2)
0 Kudos
1 Solution

Accepted Solutions
RobertScheitlin__GISP
MVP Emeritus
Guys,

Version 3.1.7 - 1/30/2013
* Fixed issue with required fields and dropdownlist executing search before all required fields are completed.
* Re-use a map layer token from the identify manager if the same layer is configured for a search.
* Honor gridfield and gridhyperlinkfield order set in the eSearchWidget.xml (add in order specified).

View solution in original post

0 Kudos
16 Replies
RhettZufelt
MVP Notable Contributor
Justin,

Could you clarify a little?  What do you mean by not having the opportunity to fill in the second value?  Are you saying that as soon as you "click" in the second box it is executing the search?

Of course, in your example the "AND"  expression is the same thing as the first one so it is redundant.  basically, the way I read it is says if a=b AND a=b, then.....  Possibly doing an AND on the same criteria is confusing it?

R_
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Justin,

   Just to add to what Rhett has already said. You also do not need to use a like SQL expression (actually better not to) if you are using a userlist.
Your SQL should be:
SDE.SPP_TIE_LINES.TIE_NAM = '[value]'
0 Kudos
JustinFultz
Regular Contributor
So let me explain a the situation a little better and maybe you can provide alternates for performing this operation.

First, the query is performed as soon as I select a value in the first dropdown list. I never have the oppurtunity to have any interaction with the tool or keyboard after that.

The reason the queries are the same and use "LIKE" is because the field is a concatenated field from the owner fields. In the table there is OWNER_1, OWNER_2, and TIE_NAM which is the concatenation of the two owner fields. TIE_NAM could have a value of AEPOGE or OGEAEP, either of which is a tie line between AEP and OGE. The only way to pull either combination is using "LIKE".

Also, I now tested by performing a similar operation using different expressions with an = sign and still get the same behavior so I don't think it is necessarily related to the way the expressions are designed. However, I am open to any suggestions.



Thanks for your help!!!

Additional infromation from further testing:

This only occurs when using a dropdown selection, regardless of if I define the values or if it uses unique values from a field. Immediately after selecting a value in either dropdown, the query runs. The tool functions properly when user is forced to enter values.
0 Kudos
AnthonyGiles
Honored Contributor
Robert,

I am having the same issue. Basically if you have more than one field set up to search against using drop down lists as soon as you change the value in one list the query executes. You then have to go back to the text search window to select a value in the second list, and so on if you have many fields.

The desired effect that is required is that if there are multiple drop downs is that the query doesn't execute until you click the search button.

I have looked at your sample site and you do not have any queries set up this way, so you may not have noticed the issue.

Hope that makes sense

Regards

Anthony
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Guys,

   Thanks for reporting. As I have begun to use GitHub more (and esri has too), it would help me if you log issues/bugs there in the future for the eSearch Widget. https://github.com/rscheitlin/eSearch

This issue will be addressed in Version 3.1.7
0 Kudos
RhettZufelt
MVP Notable Contributor
Robert,

I have no problem using GitHub (in fact I just did ), but won't that make it difficult for us to give you your check marks for answering?

R_
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Rhett,

     You are correct it may eliminate some MVP points I would have gotten, but it will definitely help me to track issues better. So may be people can do both.
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Guys,

Version 3.1.7 - 1/30/2013
* Fixed issue with required fields and dropdownlist executing search before all required fields are completed.
* Re-use a map layer token from the identify manager if the same layer is configured for a search.
* Honor gridfield and gridhyperlinkfield order set in the eSearchWidget.xml (add in order specified).
0 Kudos
JustinFultz
Regular Contributor
Thanks Robert! Seems to work perfect now.
0 Kudos