Go Back   Access World Forums > Microsoft Access Discussion > Tables

 
Reply
 
Thread Tools Rate Thread Display Modes
Old 01-18-2007, 04:12 AM   #1
Haynesey
Registered User
 
Join Date: Dec 2001
Location: Derby, England
Posts: 190
Thanks: 0
Thanked 0 Times in 0 Posts
Haynesey
Angry Import file Problem

Hi,

I m really struggling now with this problem.

I am importing a csv file with addresses and Post Codes on into a Properties Table. However, when I import the csv file, there is another field in the table called Area. I want the import routine to somehow use a lookup table that will contain all Post Codes and what Area they are in and then insert the relevant Area in each record in the properties table. I have tried using DLOOKUP in an update query but this just inserts the first Area in the lookup table into all records in the Property Table.

Any help would be much appreciated.

Lee

Haynesey is offline   Reply With Quote
Old 01-18-2007, 04:29 AM   #2
Bat17
Newly Registered User
 
Join Date: Sep 2004
Location: Maidstone, Kent. UK
Posts: 1,687
Thanks: 0
Thanked 6 Times in 5 Posts
Bat17 is on a distinguished road
link the 2 table together in the update query and just drop in the relevant fields.
Better yet, don't bother! just link the lookup table to the main table in a normal query and use that to base your forms/reports on. When the post offfice decides to change their postcodes you just need to update the look up table and not have to chase around trying to find what has changed!
That is the beauty of a relational DB

Peter
Bat17 is offline   Reply With Quote
Old 01-18-2007, 05:11 AM   #3
Haynesey
Registered User
 
Join Date: Dec 2001
Location: Derby, England
Posts: 190
Thanks: 0
Thanked 0 Times in 0 Posts
Haynesey
Thanks

Hi,

Thanks for this.

At the moment however, ther are no forms. I am just updating the data in a table. Is it not possible without forms?

Cheers

Lee

Haynesey is offline   Reply With Quote
Old 01-18-2007, 05:53 AM   #4
The_Doc_Man
Happy Retired Curmudgeon
 
Join Date: Feb 2001
Location: Suburban New Orleans, LA, USA
Posts: 14,675
Thanks: 93
Thanked 1,701 Times in 1,574 Posts
The_Doc_Man is a splendid one to behold The_Doc_Man is a splendid one to behold The_Doc_Man is a splendid one to behold The_Doc_Man is a splendid one to behold The_Doc_Man is a splendid one to behold The_Doc_Man is a splendid one to behold The_Doc_Man is a splendid one to behold
It is very possible without forms.

Don't ever do a DLookup from an already-resident table if a JOIN is possible. Saves storage time and is dynamic - in case something gets redesignated via a new area name or a change of post-code boundaries.

The_Doc_Man is offline   Reply With Quote
Reply

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Appending an Excel file to an Access table adrian.stock22 General 7 12-12-2008 02:47 PM
Cache problem on web-based Excel file PearlGI Web Design and Development 0 08-17-2006 04:41 AM
Create an import specification on a variable text file??? NJudson General 8 11-22-2004 08:15 PM
[SOLVED] Import text file ERROR mrabrams General 4 03-27-2003 11:19 AM




All times are GMT -8. The time now is 10:24 AM.


Microsoft Access Help
General
Tables
Queries
Forms
Reports
Macros
Modules & VBA
Theory & Practice
Access FAQs
Code Repository
Sample Databases
Video Tutorials

Featured Forum post


Sponsored Links


Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
(c) copyright 2017 Access World