Changes

Jump to: navigation, search

Coordinate display rules

579 bytes added, 17:29, 24 November 2014
no edit summary
</pre>
This query identifies coordinates where the ''userenteredcoord'' does '''not''' contains 4 ''':''' when coordformat is ''Degrees:Minutes:Seconds'' OR ''Degrees:Decimal Minutes''
<pre>
SELECT
geopoint.longitude,
geopoint.latitude,
geopoint.coordrefsys,
geopoint.userinputformat,
geopoint.coordformat,
geopoint.userenteredcoord,
LENGTH(userenteredcoord) - LENGTH(REPLACE( userenteredcoord, ':', '')) AS occ
 
FROM
geopoint
WHERE
geopoint.userenteredcoord LIKE '%:%' and
LENGTH(userenteredcoord) - LENGTH(REPLACE( userenteredcoord, ':', '')) <> 4
and coordformat = 'Degrees:Minutes:Seconds'
</pre>
 
This query identifies coordinates where the ''userenteredcoord'' does '''not''' contains 2 ''':''' when coordformat is ''Degrees:Decimal Minutes''
<pre>
ELECT
geopoint.coordrefsys,
geopoint.userinputformat,
geopoint.coordformat,geopoint.userenteredcoord,LENGTH(userenteredcoord) - LENGTH(REPLACE( userenteredcoord, ':', '')) AS occ 
FROM
geopoint
WHERE
geopoint.userenteredcoord NOT LIKE '%:%'andAND LENGTH(coordformat = userenteredcoord) - LENGTH(REPLACE( userenteredcoord, 'Degrees:Minutes:Seconds' OR , '')) <> 2and coordformat = 'Degrees:Decimal Minutes')
</pre>
{{NavBox Upgrade}}
[[Category:NoPublic]]
[[Category:SQL Queries]]
6,632
edits

Navigation menu