Take perfect backup with mysqldump

If you want to take a full backup i.e., all databases, procedures, routines, and events without interrupting any connections: mysqldump -u [username] -p -A -R -E –triggers –single-transaction > full_backup.sql -A For all databases (you can also use –all-databases) -R For all routines (stored procedures & triggers) -E For all events –single-transaction Without locking the … Read more

Export MySQL database with triggers and procedures?

mysqldump will backup by default all the triggers but NOT the stored procedures/functions. There are 2 mysqldump parameters that control this behavior: –routines – FALSE by default –triggers – TRUE by default so in mysqldump command , add –routines like : mysqldump <other mysqldump options> –routines > outputfile.sql See the MySQL documentation about mysqldump arguments.

How to convert a postgres database to SQLite?

I found this blog entry which guides you to do these steps: Create a dump of the PostgreSQL database. ssh -C [email protected] pg_dump –data-only –inserts YOUR_DB_NAME > dump.sql Remove/modify the dump. Remove the lines starting with SET Remove the lines starting with SELECT pg_catalog.setval Replace true for ‘t’ Replace false for ‘f’ Add BEGIN; as … Read more

Best (easiest) way to make a SQL Server dump and import that dump in another SQL Server

An easy way would be to use SQL Server Management Studio, in the Object Explorer right click on the database you want to export, select Tasks -> Back Up, then select a destination and file name in the Destination box at the bottom of the dialog. You can play around with the various settings, but … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)