Do you have a question? Post it now! No Registration Necessary. Now with pictures!
- Posted on
August 4, 2005, 10:31 pm
rate this thread
enables some optimizations.
One of those optimizations is to use single insert statements, instead
of separate insert statements, each on their own lines.
I'm also aware of the --skip-opt / -e / --skip-extended-insert
But what I'd like is a combination of having a single insert statement,
but with each record in its own line, like so:
INSERT INTO `article` (`id`, `title`, `text`) VALUES
(1, 'test', 'this is a test'),
(2, 'test2', 'also a test');
--skip-opt or --skip-extended-insert isn't it, because that'll give me:
INSERT INTO `article` (`id`, `title`, `text`) VALUES (1, 'test', 'this
is a test');
INSERT INTO `article` (`id`, `title`, `text`) VALUES (2, 'test2', 'also
If this can't be done with mysqldump, does anyone know of an
alternative command-line runnable utility? Thanks in advance!
Re: mysqldump, entire table in one insert, but multiple lines, how?
Bill Karwin wrote:
Thanks for the feedback. I was hoping that mysqldump could do this
built in, but piping to a script is ok I guess. Your script works,
except if one of the strings contains a ),( it would break it.
Is is possible to enhance the script to detect if it's inside a string?
- » Pre-approved Application #36864DQ Fri, 05 Aug 2005 22:25:06 -0800
- — Next thread in » MySQL Database Forum
- » Americanas.com SALDO de TVs Com at 80% de Desconto (29798)
- — Newest thread in » MySQL Database Forum
- » ssh on command line: force using a group size (prime size) of 1024 (and no...
- — The site's Newest Thread. Posted in » Secure Shell Forum