Instruction
Perfect! As expected, the query in the previous exercise failed. What can we do in this situation? The answer is: casting to geometry, just like we did before:
SELECT
ST_Area(ST_Transform(
boundaries::geometry,
26910))/1000000
FROM usa_states
WHERE name = 'Alaska';
As usual, remember about to use the right SRID!
Exercise
Write a query that will make a single polygon around all US states. Use casting to geometry to obtain the correct result.
Stuck? Here's a hint!
Cast boundaries to ::geometry.
In the ST_Transform() function, use the SRID for the whole world – 4326.



