I am using mysql on local machine and not on server. I want to know can I take backup of database with data ?
What OS are you running it on, windows, linux..? You can use a gui tool, like PhpMyAdmin to export your database(s), you just need to install it, that differs though on the OS you are using.
You can choose a MySQL GUI tool to export your database as RHS-Chris suggested or use command line utility mysqldump. The syntax to export your DB with mysqldump will be (run this on command line) mysqldump database_name > path_to_file/backup.sql Code (markup):