Below are the examples showing use of GeoTAX Location operation with different Formats.
- Performing GeoTAX Location operation in Snowflake
environment:
create or replace table geotax_test_1 as select ID,addressline1,city,state,zip, object_construct( 'addressId', iff(ID is not null, ID,''), 'addressLines', array_construct(iff(ADDRESSLINE1 is not null, ADDRESSLINE1,'')), 'admin1', state, 'city', city, 'postalCode', zip ) as geotaxObject , geotax_address(geotaxObject) as geotaxResponse from GEOTAX_LOCATIONS; create or replace table geotax_test_2 as select ID,addressline1,city,state,zip, object_construct( 'addressId', iff(ID is not null, ID,''), 'longitude', longitude , 'latitude', latitude ) as geotaxObject , geotax_location(geotaxObject) as geotaxResponse from GEOTAX_LOCATIONS;