#8805 closed defect (fixed)
Pluging: opendata. "No data found" in simple CSV file
Reported by: | brycenesbitt | Owned by: | Don-vip |
---|---|---|---|
Priority: | minor | Milestone: | |
Component: | Plugin opendata | Version: | |
Keywords: | Cc: |
Description
I tried to import various versions of this simple CSV file, but always got "No data found" from the plugin:
Address,lon,lat,geo_accuracy
"1422 PERALTA AVE BERKELEY CA 94702",-122.2877712,37.8809038,residential
"1578 HOPKINS ST KENSINGTON CA 94707",-122.2816511,37.8816759,coffee
"1302 VIRGINIA ST BERKELEY CA 94702",-122.288276419623,37.874054643623,house
It asks for the projection, and after selecting WGS84, I get the error.
Attachments (1)
Change History (4)
by , 12 years ago
comment:1 by , 12 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
comment:2 by , 12 years ago
While you're in there, it would be nice if you added a hint on the load screen:
latitude and longitude are expected in columns named "lat" and "lon"
Or whatever it is. It is kind of murky now.
comment:3 by , 12 years ago
The problem was linked to the way I parsed files with commas as separator instead of semicolons.
I cannot add such a message because the plugin is able to recognize a large number of potential combinations for the wording of "latitude" and "longitude":
/** * Coordinates fields */ public static final String X_STRING = "X|LON|LONGI|.*LONGITUDE.*|EASTING"; public static final String Y_STRING = "Y|LAT|LATI|.*LATITUDE.*|NORTHING"; // The list of all ProjectionPatterns (filled at each constructor call) public static final Collection<ProjectionPatterns> PROJECTIONS = new ArrayList<ProjectionPatterns>(); public static final ProjectionPatterns PRJ_WGS84 = new ProjectionPatterns("GPS|WGS84|°décimaux", Projections.getProjectionByCode("EPSG:4326")); public static final ProjectionPatterns PRJ_LAMBERT_93 = new ProjectionPatterns("LAMB93|L93", Projections.getProjectionByCode("EPSG:2154")); public static final ProjectionPatterns PRJ_LAMBERT_CC_9_ZONES = new LambertCC9ZonesProjectionPatterns("LAMBZ|CC(42|43|44|45|46|47|48|49|50)"); public static final ProjectionPatterns PRJ_LAMBERT_1972 = new ProjectionPatterns("LAMB72|LAMB1972", Projections.getProjectionByCode("EPSG:31370")); public static final ProjectionPatterns PRJ_LAMBERT_2008 = new ProjectionPatterns("LAMB08|LAMB2008", Projections.getProjectionByCode("EPSG:3812")); // Must always be declared last public static final ProjectionPatterns PRJ_UNKNOWN = new ProjectionPatterns("");
Fixed in [o29666]. Thanks for the bug report :) While you're here, can you please answer my questions in #8788 ? Thanks.