----- Original Message ----- From: "DL Neil" <[EMAIL PROTECTED]> Date: Tue, 20 Aug 2002 21:51:24 +0100 To: "Joseph Grundy" <[EMAIL PROTECTED]>, <[EMAIL PROTECTED]> Subject: Re: insert command
> Joseph, > > > I need to know if there is a way to do a simple insert from a .txt file, > using insert and only populate one column. Its a streamline db and I want to > enter only a few of the columns. > > > > I have exported all data into txt files at this point. I can not find any > mention on mysql's site other than doing all rows or leaving /n spots with > 3000 records and 35 columns can take a bit of time > > > Are you trying to limit: > - columns (first para) > - rows (second para), or > - both. > > The manual (6.4.9 LOAD DATA INFILE) says "If you wish to load only some of a > table's columns, specify a field list" > > Alternatively, load the lot into a table, then ALTER the table to drop > unneeded columns - the 'extra' loading time will be unlikely to be > noticeable. > > Regards, > =dn > > > > --------------------------------------------------------------------- > Before posting, please check: > http://www.mysql.com/manual.php (the manual) > http://lists.mysql.com/ (the list archive) > > To request this thread, e-mail <[EMAIL PROTECTED]> > To unsubscribe, e-mail <[EMAIL PROTECTED]> > Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php > > Another way to say it I have an old DB with 30 columns in it. I want to remove a few columns of data from that one and insert it into the new db. I have exported the columns needed into txt files The question is populating the new db with to the proper columns, the empty colums will be taken care of at a later time and info is updated. Only a few is needed at the moment. Thanks Joseph -- __________________________________________________________ Sign-up for your own FREE Personalized E-mail at Mail.com http://www.mail.com/?sr=signup --------------------------------------------------------------------- Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail <[EMAIL PROTECTED]> To unsubscribe, e-mail <[EMAIL PROTECTED]> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php