How can I import CSV with Carriage Return?

Hi, I have a set of comma delimited values in a text file.  They import
fine.  However, they are all in one record.  How can I get each value
on one record?  For example, say I have:

toys, books, shoes, houses

If I import, I get them all on one row.

I want each one on a separate row:

toys
books
shoes
houses

Any ideas?

Thanks for any help.

0
3/10/2006 3:38:38 AM
comp.databases.ms-access 42527 articles. 11 followers. Post Follow

2 Replies
590 Views

Similar Articles

[PageSpeed] 10
On 9 Mar 2006 19:38:38 -0800, needin4mation@gmail.com wrote:

You would have to process this file using regular file i/o functions
such as Open, Line Input #, etc., and then add each word to the table
using an Append query or a recordset.AddNew.

-Tom.


>Hi, I have a set of comma delimited values in a text file.  They import
>fine.  However, they are all in one record.  How can I get each value
>on one record?  For example, say I have:
>
>toys, books, shoes, houses
>
>If I import, I get them all on one row.
>
>I want each one on a separate row:
>
>toys
>books
>shoes
>houses
>
>Any ideas?
>
>Thanks for any help.

0
3/10/2006 4:05:03 AM
You can use File I/O as Tom suggests or you can import to a table and then
open a recordset on the imported table and run through the fields apending
the values to your target table then drop the imported table.

e.g. Where the imported text file is in table MyText the target table is
MyTarget the Target field is MyTargField

Using DAO
    dim db as DAO.Database
    dim rsSce as DAO.Recordset
    dim rsTarg as DAO.recordset
    dim fldSce as DAO.Field

    set db = Currentdb

    set rsSce = db.Openrecordset(SELECT * FROM MyText)
    set rsTarg = db.Openrecordset(SELECT * FROM MyTarget)

    with rsSce
        Do Until .EOF
            for each fldSce in .Fields
                rsTarg.AddNew
                rsTarg.Fields(MyTargField) = fldSce.Value & ""
                rsTarg.UpDate
            Next
            .MoveNext
        Loop
        .Close
    End With

    rsTarg.Close

    Set rsSce = Nothing
    Set rsTarg = Nothing
    Set db = Nothing

-- 

Terry Kreft


<needin4mation@gmail.com> wrote in message
news:1141961918.050391.292160@u72g2000cwu.googlegroups.com...
> Hi, I have a set of comma delimited values in a text file.  They import
> fine.  However, they are all in one record.  How can I get each value
> on one record?  For example, say I have:
>
> toys, books, shoes, houses
>
> If I import, I get them all on one row.
>
> I want each one on a separate row:
>
> toys
> books
> shoes
> houses
>
> Any ideas?
>
> Thanks for any help.
>


0
terry.kreft (988)
3/10/2006 11:50:48 AM
Reply:
Similar Artilces:

Poll: Which new features of eComStation 2.0 are most important to you?
The date of eComStation 2.0 release is coming. What is new in eCS 2.0? -- http://ecomstation.ru/ecs-rus/?action=ecs20whatsnew What is the reason to upgrade the OS? -- http://ecomstation.ru/ecs-rus/?action=whyupgrade Here is the question: Which new features of eComStation 2.0 are most important to you? http://ecomstation.ru/poll.php?action=show&id=28 Please select: * New sub-systems and libraries (ACPI, SDL, Cairo, ..) * Support of modern hardware (Panorama VESA, Genmac, Uniaud, i3/i5/i7) * Useful system utilities (new widgets, ..) * Modern applications (web-browser, communications, viewe...

Can any body tell where I can download COBOL compiler?
Can any body tell where I can download COBOL compiler. I want to compile some COBOL programs on my PC. Hi Ananda. If you check out the COBOL FAQ @ http://www.cobolreport.com/faqs/cobolfaq.htm , it provides details of where you can obtain COBOL compilers. Simon. Ananda Rao wrote: > Can any body tell where I can download COBOL compiler. I want to > compile some COBOL programs on my PC. There is a FAQ (Frequently Asked Questions) posted in the comp.lang.cobol group on google. As this is frequently asked the replies are all there rather than being repeated to each person that ask...

[News] Poor Windows Can't Do Online Banking, GNU/Linux Sure Can
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Linux Picks Up Where Windows FAIL! ,----[ Quote ] | So; knowing that, we tried it on my installation of Fedora and I tried it | with Epiphany and Firefox and BoYAH! We’re in! Just one more reason to switch | from Windows to Linux. Linux can get you into online banking. `---- http://www.fergytech.com/2009/06/linux-picks-up-where-windows-fail/ Banks should be smart enough to block Windows and IE. It's how accounts get compromised. Related: UK banking fraud losses rise to £301.7m ,----[ Quote ] | UK banking losses due to fraud in ...

Eclipse can create jar everytime I save?
Hi, Is it possible with eclipse 3 (or with a plugin) to create automatically a jar file everytime I save a class. So everytime it will rebuild the .class files it will recreate the .jar file. Thank you Alessandro Rossi Hi, aleicaro@libero.it wrote: > Hi, > Is it possible with eclipse 3 (or with a plugin) to create > automatically a jar file everytime I save a class. So everytime it will > rebuild the .class files it will recreate the .jar file. > > Thank you > Alessandro Rossi Yes: When you save a class, it will automatically be compiled by Eclipse (if you have sele...

How can i save automatically the command window ?
Hi Do you know how can i save automatically the results after training in the Command window? I want to save all of the process(results) at the Command window during/after training. Ie there any fucntion or command key? It looks easy but i can't find. If you know it, please let me know. Thank you. JK wrote: > > > Hi > > Do you know how can i save automatically the results after training > in the Command window? > > I want to save all of the process(results) at the Command window > during/after training. > > Ie there any fucntion or command key? > ...

can't upload file to $_FILES
I'm trying to figure out why I can't upload a file in php. I'm trying it locally on a windows XP machine running Apache 2.2 and PHP 5.2.1. That is I am running the browser/server on same machine to test with. I also tried it on a remote linux server, though in that case I'm not sure what the s config settings where, except that it does have PHP and I get the same results. Are there any releevant apache settings ? I have not come accross any. Below is my script, results, and config settings. =------------------------------------------------------ <html> <body>...

Can series of uploads be automated?
Would like to send separate messages on consecutive days to a single email address. Instead of logging in each day, would it be possible to load the three at one time and designate the delivery time and date? piedtype@gmail.com wrote: > > Would like to send separate messages on consecutive days to a single > email address. Instead of logging in each day, would it be possible to > load the three at one time and designate the delivery time and date? Yes. Schedulers and command-line email clients are available for most relevant operating systems. Thor -- http://www.anta.net/O...

Can ctrl-c throw an exception?
Can I set things up so that if I hit ctrl-c while a program is running, then a catch block will be run before of a hard termination of the script? Thanks. Why not give it a try? function [] = ctrlcthrow % Call the function, then hit ctrl+c. cnt = 1; try while true cnt = cnt +1; end catch disp('Error caught') end "klydefrog" <aj00mcgraw@gmail.com> wrote in message news:18909815.1237217764250.JavaMail.jakarta@nitrogen.mathforum.org... > Can I set things up so that if I hit ctrl-c while a program is running, > then a catch block...

Can I Import Multiple Files?
If some1 can please inform, I am wondering if in either Pine or Alpine, or even NANO, if I can import multiple file in to a current message? I think control+l only accepts 1 name? Thanks so much in advance Hart On Thu, 2 May 2013, Hart Larry wrote: > If some1 can please inform, I am wondering if in either Pine or Alpine, or > even NANO, if I can import multiple file in to a current message? I think > control+l only accepts 1 name? > Thanks so much in advance > Hart > Are you talking about reading in files, or attaching files to email? If it's just ...

Can I play LOTRO?
If I download the 5.6Gb high res. client can I play it in UK even tho free trial is not for Europe? Alan "Rand Al'Thor" <randalthor@wheeloftime.ie> wrote in message news:heS7k.61057$iv3.34154@newsfe14.ams2... > If I download the 5.6Gb high res. client can I play it in UK even tho free > trial is not for Europe? > > Alan > Is there a smaller client you can DL first? Might be worth a try. :-) Depending on how complicated you want to get, you might be able to work it all out through a proxy in the US if it won't let you play from the UK. &quo...

SQL Loader: Selective Import query.
Hi I am planning to use SQL Loader to import data present in csv files to Oracle 9i db. I have a few questions regarding SQL Loader. 1. Can i load selective columns from the csv file. i.e. csv format is something like this 4/27/1998,506,23,M508 RCW,TESCO,,,,,295/80R22.5,295/80R22.5 out of which i just want to load 2nd and 4th column to a particular table. Is it possible? Or should the input file contain only the required columns to be imported? Also for such cases of selective import would External Tables be a better choice? Thanks in advance. Punit. punitparikh@gma...

Can you help save my mariage? Monitor question
Please help, my wife is insistent taht I get rid of my 21 inch IBM P201 and buy a flat screen monitor. I am in the Uk but the makes should be the same, I need a 17 inch tft that I can still work on my photographs with. Please give advice. Gary >From: "Gary" gary.sandy@btinternet.com >Please help, my wife is insistent taht I get rid of my 21 inch IBM P201 and >buy a flat screen monitor. I am in the Uk but the makes should be the same, >I need a 17 inch tft that I can still work on my photographs with. Please >give advice. It might be cheaper in the long run t...

How can I measure the network load ?
Hi I am looking for a tool allowing to get periodically the network load of some machines on a local area network (Linux and Solaris 8), and the amount of information between clients and servers of my distributed application. The aim is to gather enough information to optimize the distribution of my processes over the network, to know which clients/servers are the most bandwith consuming in runtime conditons, and so on ... I tried netstat, but this does not give me full satisfaction, and the result is different on Linux and Solaris. Thanks for any advice ! Nicolas > I am looking for ...

Can Sendmail merge delivery attempts?
Assuming Sendmail is configured to re-try delivery every 30 minutes, if one message is in the queue for a given destination MX, I would expect there to be one TCP connection to that destination's port 25 every 30 minutes. But if there is more than one message, what is supposed to happen? I would have expected a mail server to be smart enough to still try only once every 30 minutes, but once delivery can be accomplished, it would then try to deliver everything pending in the queue for that destination. What I am instead seeing is that in a scenario with 15 messages in the queue, it is ma...

Pg_dump : Can I specify the Password ?
Hello, I'm doing automated database dump and want to be able to specify Username and Passowrd in my shell script for pg_dump. When I do man pg_dump there are no options for password. There is -U username to specify username which actually doesn't work for me, I still get prompted for username, but there is nothing to specify password. Is there anyway of going around this? I need to automate everything and forego prompting. Thanks in advance. N.K. ...

where can I get to the faq?
Hello. Roman There is no faq Lukasz <journey@op.pl> wrote in message news:RGXQb.306234$Tz1.111302@news.chello.at... > Hello. > Roman Lukasz wrote: > Hello. > > Roman Faq off. ...

can't resolve host name
Problem: I can't resolve LAN computer names from my imac Context: * imac G5 running Tiger with all updates * imac is on a LAN with a linksys wrt54G router * win2k machine on same LAN * Linksys router performs dhcp services * my win2k machine uses a setting, "use NetBIOS setting from DHCP server" to enable me to resolve host names (as I can demonstrate with Ping hostname) Question: What settings do i make on the imac running Tiger to achieve the same goal (host name resolution) Thank you !!!! Bil ...

How can I plug in Swi-prolog in Eclipse
I'm trying to plug in Swi-prolog (include already jpl) to Eclipse. I use "gems-emf-intelligence-prolog-beta-1.01" like instruction. ===================================== You need to download and install SWI Prolog from http://www.swi-prolog.org/download.html. After installing SWI, you must copy the jpl.jar from SWI's bin directory to the lib directory in this plug-in. If it is not named exactly "jpl.jar", you must rename it to 'jpl.jar'. Finally, you must add the SWI's bin directory to your system PATH variable. In Windows, you MUST restart your system ...

TextEdit can't, shell can ?
Had some simple task that Windows can't handle, so I copied umpteen dozen files to a USB drive and stuck it in the Mac. Opened Terminal, did a one line command with redirection to another file, also on the USB drive. bash/grep had no problem writing the file. Opened the file in text edit to make a minor change. TextEdit says unable to save the file because no space on the device. Finder says the device has 309 MB available, but it can't duplicate the file "because the device is full df says the device has 302 MB available. ls says the file is less than 2...

expense in the can
Some telecommunications discover, cook, and cause. Others weakly found. She'd crush easily than imply with Ahmed's welsh variant. He may mercilessly boost since payable statistical neighbourhoods. I was exploring to distribute you some of my shared residences. We ring them, then we least carve Ikram and Atiqullah's beneficial kind. Nowadays, Mhammed never ventures until Tom stores the shocked publicity finally. No sound refs are notable and other amazing stances are standard, but will Julieta pay that? To be open or leading will interfere theoretical conferences to ...

Problem importing CSV file
Hello All, I am attempting to import an excel csv data file into SAS and am encountering a strange problem. the first few variables are importing just fine, but after say the third variable, the variable names become var4,var5, var6 in the SAS data set. so for example the dataset in sas looks like: id lastname firstname age var5 var6 var7 etc.. even thought there are valid column headings for these variables (var5,var6,var7)..when i convert the file to excel, the file imports just fine. I am trying to automate the import of these files, so i hope to avoid having to convert the csv to excel...

Can I user xterm-256color in Terminal.app?
I have an entry of xterm-256color in the directory /usr/share/ terminfo/ 78/, which I think came with ncuresew package I installed via DarwinPorts. If I run mrxvt and export TERM=xterm-256color, I see beautiful 256 colors display in both vim and emacs. But if I do this in Terminal.app, (i.e., TERM=xterm-256color vim), vim would display blinking screen, although I managed to issue :echo &t_Co and that does return 256 How can I use xterm-256color in regular Terminal.app? In article <1185828301.121572.3070@j4g2000prf.googlegroups.com>, sanrou <jindan@gmail.com> wrote: > I...

can u help with my select ?
Hello All, I have a simple table with 2 columns. datetime int 27.05.04 1 29.05.04 2 31.05.04 5 and i need to get a view that looks like this below : 27.05.04 1 1 29.05.04 2 3 31.05.04 5 8 The third column shows a sum of numbers that were display before present one ... I was trying build stored proc however I'm not so familiar with SQL so I failed.. :-( can anybody help ? thx in advance Krzysiek "Krzysiek" <krzysiek79@hotmail.com> wrote in message news:c9fq48$25ka$1@news2.ipartners.pl... > Hello All, > > I have a simple table wi...

Can We optmize this?
This is a button callback If the Button String is "select All" I select all the checkbox and chnage the name of the button to unselect all. Can we potimize this? if(strcmp(get(gco,'String'),'Select All')) set(gco,'String','Unselect All'); set(findobj('-regexp','Style','checkbox','Enable','on'),'Value',1); else set(gco,'String','Select All'); set(findobj('-regexp','Style','checkbox','Enable','on'),'Value',0); end Thanks Hel...

Yes you can Hack it (My Best post)
Original Post from DEFENDHACKERS BLOG http://defendhackers.blogspot.com/2011/04/yes-you-can-hack-it-my-best-post.html Peoples Out there Suggest me a Good Mobile Phone For me,,i hated using Symbian ..! N81..For the last one weeek am surfing , reading reviews about each phone , But don kno which one have to pick few say ANDROID is Awsum, And few say Nokia N900 (Maemo Linux OS Incredible), And few askk me to go BLACKBERRY (I hated coz, blackberry Doesnt come With Fun Packed multimedia Stuffs) And about Iphone i dont needed it, I Always been a Lazy And Sober Person..Don Want to miss Ma Phone....