views:

82

answers:

3

If we export the table into another DB then does its all triggers also gets exported along with it?

Update

In context of Randy Minder's reply

is it possible to transfer the schema table from one DB to another?

UPDATE In context of MATT's Reply

But What should I do If i have to script this export? as in this case I have to change the trigger_Schmea every time.

A: 

I think not. You could try to export on table into .sql file and see what scripts are written into it.

Riho
A: 

Generally an "export" only deals with data. So the answer would be no. But if you script out your source database schema, and execute the script against the target database, all the triggers should come with it, assuming they were scripted as part of the schema.

Randy Minder
+1 See updated Question
OM The Eternity
+2  A: 

Pass --triggers to the mysqldump command if you're not getting triggers already (you should.. it's default)

Matt
When I Click Export o table structure in phpmyadmin, I can see the mysqldump, where i found the --Triggers "table_name", but when I copied the whole part and pasted in other DB I cannot find the triggers copied.. What could be the reason
OM The Eternity
@OM The Eternity - I haven't used phpMyAdmin in years. To my knowledge it does not use `mysqldump`. In either case I suggest running the `mysqldump` command directly.
Matt
No Issues, I found It, I just have to change the name of trigger_schema inside the mysqldump of phpmyadmin
OM The Eternity
See Updated Question
OM The Eternity