Hi! Can someone please help me figure out why and how this query works? I can't understand the logic behind it. Thanks so much
Img of Problem — TASK: Separate the location field into two columns for latitude and longitude Location Field: (37.709725805163, -122.413623946206) — QUERY: SELECT location, TRIM(leading ‘(‘ FROM LEFT(location, POSITION(‘,’ IN location) – 1)) AS latitude, TRIM(trailing ‘)’ FROM RIGHT(location, LENGTH(location) – POSITION(‘,’ IN location) ) ) AS longitude FROM tutorial.sf_crime_incidents_2014_01 — PROBLEM: I want to… Read More Hi! Can someone please help me figure out why and how this query works? I can't understand the logic behind it. Thanks so much