Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
jbchurchill
Creator
Creator

Invalid Geometries - Match function in Data Load is breaking my map

I'm trying to do a find and replace type of thing using the match function.

Why does this (in the Data Load Editor) break my map?

 

 

if(match(county, county = 'St. Mary' & chr(39) & 's'), 'Saint Mary' & chr(39) & 's') as Modified.county,

 

 

The map shows a message saying this:

[Modified.county] - Area Layer

The data contains invalid geometries that could not be shown on the map. Review your data for errors and try again.

Labels (2)
1 Solution

Accepted Solutions
jbchurchill
Creator
Creator
Author

I may have been using poor (or incorrect) syntax. It validates in the data load editor and in running the data load process but does produce the error in the map that I described. I changed it slightly to this. 

 

    if(match(county, 'St. Mary' & chr(39) & 's'), 'Saint Mary' & chr(39) & 's',
    if(match(county, 'Baltimore City'), 'City of Baltimore',
    county)) as Agronomy.county,

 

I also discovered (from a contractor working for us to help w/ Qlik) that this works too. 

    if(county = 'St. Mary''s', 'Saint Mary''s',
    if(county = 'Baltimore City', 'City of Baltimore',
    county)) as Agronomy.county,

 

View solution in original post

1 Reply
jbchurchill
Creator
Creator
Author

I may have been using poor (or incorrect) syntax. It validates in the data load editor and in running the data load process but does produce the error in the map that I described. I changed it slightly to this. 

 

    if(match(county, 'St. Mary' & chr(39) & 's'), 'Saint Mary' & chr(39) & 's',
    if(match(county, 'Baltimore City'), 'City of Baltimore',
    county)) as Agronomy.county,

 

I also discovered (from a contractor working for us to help w/ Qlik) that this works too. 

    if(county = 'St. Mary''s', 'Saint Mary''s',
    if(county = 'Baltimore City', 'City of Baltimore',
    county)) as Agronomy.county,