[GRASS-user] v.in.ascii: Error Needs Explanation
micha at arava.co.il
Thu Mar 3 15:11:35 EST 2011
On 03/03/2011 08:10 PM, Rich Shepard wrote:
> I have a 3-column table with 110,337 rows. The first column is the
> key to a postgres attribute table, the second column is the longitude,
> the third column is the latitude. Based on the manual page I made the
> separators the pipe '|'. However, I have a syntax error and I don't
> understand what it's telling me.
> First few table lines:
> The command line is:
> GRASS 6.5.svn (Nevada-ll):~/grassdata > v.in.ascii -bt
> in=/home/rshepard/GIS/data/Nevada/nv_wells.txt out=water_wells
> fs='|' skip=1 columns='well_log varchar(6), x double precision, y double
> precision' x=2 y=3 z=0 cat=0
> Scanning input for column types...
> Maximum input row length: 29
> Maximum number of columns: 3
> Minimum number of columns: 1
> ERROR: x column number > minimum last column number
> (incorrect field separator?)
> The manual page says:
> Number of column used as x coordinate (points mode)
> First column is 1
> Default: 1
> so I specified it as column 2, the y value as column 3, and nothing
> for the
> primary key column. Should that be considered the cat column? Where is my
> command syntax incorect?
Worked for me on those few rows. My guess is that somewhere down among
those 100,000 rows there's one that's either missing the '|' character.
or missing the actual digits or some such.
BTW, if you're specifying the '-t' option to *not* create the attrib
table, I suppose there's no need to give the column header names and
types for a table that's not going to be created.
> While I'm learning how to do this, does it matter if there are multiple
> 'well_log' values at the same location? I guess that multiple wells were
> drilled in essentially the same place so they have the same long/lat
> but different row keys in the postgres table.
> grass-user mailing list
> grass-user at lists.osgeo.org
> This mail was received via Mail-SeCure System.
Arava Development Co. +972-52-3665918
More information about the grass-user