Solved

Import text data into existing linked field?

Posted on 2007-11-29
4
622 Views
Last Modified: 2013-11-29
Hi -

I'm trying to import data (using the wizard) from a text file into a table that has a number of linked fields to other tables.

So, in particular, I'm trying to get one field from the text file that's a list of names.  The destination field is a link to another table, so it's data type is actually "number" (although the field it links to is a text field).  When I try to import, I get an "Invalid Argument" error.

Maybe I have to import each field from the text file separately not into the linked fields, but into the other tables that are linked to?  Actually, now that I think about it, this wouldn't work, as the relationships of the links are "many to one".

Can this be done, or am I SOL?  Need more info?

Thanks,
Noah
0
Comment
Question by:noahisaac
  • 2
4 Comments
 
LVL 120

Expert Comment

by:Rey Obrero (Capricorn1)
ID: 20374397
Need more info? Yes
Post the table structures
0
 
LVL 3

Expert Comment

by:incrediblejohn
ID: 20376221
Not sure what you are saying. Am I to assume that you have an MS Access database that has linked tables in it? That is no big deal, Access looks at these tables like they are local.

Can you use code? I can give you the DAO opentable code to open a text file and stick it in a recordset.

you can also just link to the text file so it looks like a table in Access. Then run your stuff from there.
0
 

Author Comment

by:noahisaac
ID: 20376879
Hi incrediblejohn -

> Not sure what you are saying. Am I to assume that you have an MS Access database
> that has linked tables in it? That is no big deal, Access looks at these tables like they are local.

Not exactly.  The "main table" I'm trying to import the data into is comprised of fields that are lookups to fields in other tables in the same database.


> Can you use code?

I'm pretty bad with SQL, but I do know a little.


> I can give you the DAO opentable code to open a text file and stick it
> in a recordset.

That would be most helpful.  Do you need my table structure?


> you can also just link to the text file so it looks like a table in Access. Then run your stuff from there.

Ah, this sounds like a good option.  I just looked this up: Is this a feature of 2007, or can you do it with 2003, too?


Thanks,
Noah
0
 

Accepted Solution

by:
noahisaac earned 0 total points
ID: 20826415
For anyone that may be interested:

Trying to import text was too annoying.  I got ODBC access to the original source of the data.  Now I don't have to do the import at all.
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Overview: This article:       (a) explains one principle method to cross-reference invoice items in Quickbooks®       (b) explores the reasons one might need to cross-reference invoice items       (c) provides a sample process for creating a M…
A simple tool to export all objects of two Access files as text and compare it with Meld, a free diff tool.
In Microsoft Access, learn how to “cascade” or have the displayed data of one combo control depend upon what’s entered in another. Base the dependent combo on a query for its row source: Add a reference to the first combo on the form as criteria i…
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

829 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question