Append Geocode Data from Text File (via Query) Not Working

D

Dana F. Brewer

I have a table that I create using a query (sql below) that I need to be able
to import a text file into. When I manually do the import into a new table
on the fly everything works fine. When I try to append to the table I
created beforehand the geocode number fields get truncated and don't import
correctly. I would like to be able to automate this task as much as possible
using create table and drop table so that I do not have to babysist the
process. Please help me.

Here is all the information:

TEXT FILE FORMAT:
38.709601,-121.339298,1234 anywhere,yourcity,yourstate,11111

TABLE FORMAT:
CREATE TABLE tblGeocoded (GeoCodeID COUNTER CONSTRAINT PrimaryKey PRIMARY
KEY, Latitude LONG, Longitude LONG, Address TEXT, City TEXT, State TEXT, Zip
LONG) NOTE: Zip imports just fine.


I could really use your help here. Thanks in advance.

....Dana
 
G

Gina Whipp

Dana,

Try using a Double instead of a Long for Longitude and Latitude. As for Zip
I always use text as it can start with a zero and *real* numbers do not
start with zero.

--
Gina Whipp
2010 Microsoft MVP (Access)

"I feel I have been denied critical, need to know, information!" - Tremors
II

http://www.regina-whipp.com/index_files/TipList.htm
 
D

Dana F. Brewer

Hi Gina. I should have said that I have tried double, long, etc. I resolved
the problem myself by creating an input spec and changing the . in Decimal to
another character so the process wouldn't get tripped up on the "." in the
numbers.

Thanks anyway. :)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top