How do I test if a geo-location field is empty?

Options

How do I test if a geo-location field is empty? I have tried the following tests with no luck: "isNull( location )", "location == null", "location", "isLocation( location )", etc.

Tagged:

Comments

  • is working for me on the latest build of CMS but not on the production version. I'll file a ticket to see if we can't get this fixed in the upcoming release. In the meantime, testing against individual fields seems to work, e.g.

    That (or some variant of that) might be enough to get you unstuck for now.

  • Bruce Keilin:

    is working for me on the latest build of CMS but not on the production version. I'll file a ticket to see if we can't get this fixed in the upcoming release. In the meantime, testing against individual fields seems to work, e.g.

    That (or some variant of that) might be enough to get you unstuck for now.

    Never mind. A location property is actually a collection of name/value pairs. When the author did not select a particular address, then none of the names have any values, but the location property collection is still not null (it's just empty.) That means that there is no simple way to test to see if all of the location properties are empty. You need to explicitly test the individual properties.

Categories