bcgov / smk-cli

The Command Line Interface enables users to rapidly create and edit SMK map configuration, including data consumption via OGC and Esri ReST data access services and local data files.

Home Page:https://bcgov.github.io/smk-cli

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

CSV format specs

qqnluaq opened this issue · comments

The CSV file importer is not implemented yet. What are the customary formats for geo-CSVs?

Must include LATITUDE and LONGITUDE columns/values.

any other variations? LIke a GEOMETRY/SHAPE column with WKT in it... Or multiple lat/long columns?

@bruce-tonkin - any thoughts on what should or could be acceptable as an uploadable spatial CSV file in SMK?

I believe there are a few fields that are mandatory, with some optional:
Define the projection (lat or long by default, otherwise pick the projection)
Header row (optional) to define fields (show a check box to include)
Key or ID (optional)
Lat and Long and/or z or
x(long) and y(lat) and/or z.
Other fields are optional
Use preview to view data, then do an upload.
Capture

See iMap for an example (https://maps.gov.bc.ca/ess/hm/imap4m/):
geometry,Well Tag Number,Well ID Plate,Well Status,License Status,Detailed Well Record,Artesian Flow Indicator,Artesian Flow,Artesian Flow Units,Artesian Pressure (ft),Well Class,Intended Water Use,Street Address,Finished Well Depth (ft),Diameter (in),Water Depth (ft),Bedrock Depth (ft),Well Yield,Yield Units,Aquifer Number,OBJECTID
"X: -13787769.2489604, Y: 6285053.80126365, Z: NaN",116033,54975,New,Unlicensed,https://apps.nrs.gov.bc.ca/gwells/well/116033,N,,usGPM,,Water Supply,Irrigation,3159 ADSHEAD ROAD,16,6,2,,40,Gallons per Minute (U.S./Imperial),,18860935

i think we need to be careful and keep CSV support as straightforward as possible. A user of SMK that is uploading CSV is likely not a Spatial Power User and/or is seeking to make a very simple map, quickly. The Spatial Power User calibre of user knows of and uses other formats or data services. The intent of this feature is for folks that want to visualize there spreadsheet without knowing how to convert to geoJSON, for example. We tell them to include columns for X&Y or LATITUDE/LONGITUDE and maybe a SRID and we load it.

A geometry column as defined in previous comment is more for a Spatial Power User, in my opinion.

1.0.0-beta.5

added support for CSVs with lat & long columns.. If there are any other variations to be be supported, please add a new ticket for the format, with a sample data.