Creating tables with an ST_Geometry column

In this example, two tables are created. One table, sensitive_areas, stores data about schools, hospitals, and playgrounds. The ST_Geometry data type is used to store the location of the sensitive areas in a column named zone.

The other table, hazardous_sites, stores locations of hazardous waste sites as points in an ST_Geometry column named location.

  1. Use the SQL CREATE TABLE statement to create the two tables: sensitive_areas and hazardous_sites as shown here:

    CREATE TABLE sensitive_areas (area_id integer, name varchar(128), 
    area_size float, type varchar(10), zone sde.st_geometry);
    CREATE TABLE hazardous_sites (row_id integer NOT NULL, site_id integer, 
    name varchar(40), location sde.st_geometry);