Socrata was acquired by Tyler Technologies in 2018 and is now the Data and Insights division of Tyler. The platform is still powered by the same software formerly known as Socrata but you will see references to Data & Insights going forward.

The SELECT Clause

The SELECT clause operates much as it does in SQL. It allows expressions and aliases, as well as aggregations when using GROUP BY.

For example, to retrieve only the location and magnitude fields for our earthquakes, use SELECT to choose their field names, separated by a comma (,):

You can also create column aliases just like you could do in SQL. For example, to alias magnitude to richter, provide a select of magnitude AS 'richter':

You can also use SoQL functions and operators to modify the output of a SODA query. For example, to convert the depth from meters to feet, by multiplying it by 3.28:

For a full listing of the functions available by datatype, check out the datatype-specific documentation.