On Tue, May 25, 2010 at 4:41 AM, Jen <[email protected]> wrote: > Is there a way that we can populate new fields in shapefile attribute > table with python? > > Or can we populate the new field in csv first, then convert the csv to > dbf. Finally replace the old dbf of the shapefile with the new dbf? > > I'd appreciate any advice you might give me. > > Sincerely > > Jen >
You can hack the .dbf (XBase) file using almost any software as long as you keep the rows synchronized with the shape records in the .shp file. Here's a link to a solution using only stdlib modules http://indiemaps.com/blog/2008/03/easy-shapefile-loading-in-python/ -- Sean
