A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Database Design
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

breaking down parts of an electronic feed



 
 
Thread Tools Display Modes
  #1  
Old January 5th, 2006, 10:01 PM posted to microsoft.public.access.tablesdbdesign
external usenet poster
 
Posts: n/a
Default breaking down parts of an electronic feed

I get a comma delimited file that I throw into an Access DB

One filed is a combo of things department, user, group
example:
320 Hurst, T ADM
320 KERNER C PI
320 800 Access TIP
320 POURMAN E MICS

Is there a way to pull the user out of this to create another field that
looks like
Hurst, T
KERNER C
800 Access
POURMAN E
  #2  
Old January 6th, 2006, 03:15 AM posted to microsoft.public.access.tablesdbdesign
external usenet poster
 
Posts: n/a
Default breaking down parts of an electronic feed

well, once you import that text file into a table, you could run an Update
query to add the "pulled out" values to another field in the table, using
the following expression, as

Right(Left(str, InStrRev(str, " ") - 1), Len(Left(str, InStrRev(str, " ") -
1)) - InStr(1, str, " "))

everywhere you see "str", replace it with TableName.FieldName, specifically
the name of the table the text file was imported to, and the name of the
field where the "complete" string is stored.

the above expression assumes that the data you want to extract is *always
all the data* between the first and last spaces in the string.

note that it's an ugly expression, and calls a function redundantly, but it
did work in my test. if it runs very slowly, post back and i'll write it
into a function that removes the redundancy - that may help speed it up.

hth


"Abby Lee" wrote in message
...
I get a comma delimited file that I throw into an Access DB

One filed is a combo of things department, user, group
example:
320 Hurst, T ADM
320 KERNER C PI
320 800 Access TIP
320 POURMAN E MICS

Is there a way to pull the user out of this to create another field that
looks like
Hurst, T
KERNER C
800 Access
POURMAN E



 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Parts Management Meak Database Design 2 November 22nd, 2005 05:58 AM
Message divided into parts! Zrikat General Discussion 1 September 6th, 2005 09:54 PM
Matching parts to model numbers Craig wotdoo General Discussion 4 May 12th, 2005 05:56 AM
Electronic Presentations Jaded Powerpoint 5 April 20th, 2005 02:53 PM
incorrect totals for parts jkendrick75 Setting Up & Running Reports 2 January 31st, 2005 02:57 PM


All times are GMT +1. The time now is 06:04 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.