Tag Info

New answers tagged

1

Set lower_case_table_names=1 on the Linux server before importing, this will convert all databases to lower case and new queries will use lower case, too. You can see it here. Your problem arises from the fact that the default value on Mac is 2 (names are not case sensitive when queried, but they are when stored) but 0 on Unix/Linux (names are always case ...


1

The --single-transaction option of mysqldump does not do FLUSH TABLES WITH READ LOCK;. It causes mysqldump to setup a repeatable read transaction for all tables being dumped. From your question, you stated that the mysqldump's SELECT for the db_external_notification table is holding up hundreds of INSERT command to that same table. Why is this happening ? ...


1

If you know the time from where you need to start the backup then you can use mysqldump with --where clause like below to get the type of backup you are looking for mysqldump --user=username --password=password db_name table_name --where=date_pulled > '2014-07-21 16:25:00' > backup.sql You can also do like SELECT * FROM table_name WHERE ...


-1

You can use the below query to dump the database particular tables mysqldump -u root -p test data > data.sql test is database name data is table name data.sql is the o/p file name


1

There wouldn't be anything broken , mysqlworkbench is a pretty mature software. You just need to watch the filesystem of the storage where you are going to store the file. ntfs would be fine, but fat32 will limit you to around 4GB. However, if you are just looking for an exporter with UI, Navicat Premium is more comfortable in my opinion. Hope it helps.


0

Assuming you're using Unix of some sort, I would use sed. Using your data INSERT INTO MyTAble VALUES ('data_1','data_2', 'date_3'); and putting this line into a file called testfile. Run this sed -i s/"INSERT INTO MyTAble VALUES ("//g testfile sed -i is inplace. more testfile 'data_1','data_2', 'date_3'); Then sed -i s/);//g testfile sed ...


1

You need to collect all the database names into a space delimited list. Use that for mysqldump MYSQL_USER=root MYSQL_PASS=rootpassword MYSQL_CONN=""-u${MYSQL_USER} -p${MYSQL_PASS} # # Collect all database names except for # mysql, information_schema, and performance_schema # SQL="SELECT schema_name FROM information_schema.schemata WHERE" SQL="${SQL} ...


1

This looks interesting and might (just might) be a solution to your issue. It shows how a 4.1 server can simulate Stored Procedures (SPs - not available till version 5 of the MySQL server) using the Federated storage engine. Basically, it shows that a 5.x server can access data on a 4.x server and even update that data. It also shows that you can use 5.x to ...


0

I am a big fan of dump, edit and insert. but you do not have to open the text file (dump file) to change it (this is especially usefull when it is several milion lines long). if you want to dump the database MYDATABASE. mysqldump MYDATABASE > mydump.sql then use sed to replace the old database name with new one like this sed -i ...


0

It would make more sense in my opinion to do a backup by table instead of by database. Here is a script I use to make backups of databases that contain MyISAM and InnoDB tables. #!/bin/bash USER="some_user_account" STAMP=$(date +"%d-%m-%y-%H:%M:%S") PASSWD="some_password" HOST="some_host" db="some_database" FILE="/some_directory/some_file-$STAMP.sql.gz" ...


1

According to the MySQL Documentation on innodb_file_format The file format to use for new InnoDB tables. Currently, Antelope and Barracuda are supported. This applies only for tables that have their own tablespace, so for it to have an effect, innodb_file_per_table must be enabled. The Barracuda file format is required for certain InnoDB features such ...


0

In my case this command give me an error mysqldump: Got error: 23: "Out of resources when opening file ' I had the --single-transaction option to resolve this error. And if youy only want the routine, you can add --no-create-info to avoid the create table statement.



Top 50 recent answers are included