vote up 0 vote down star

I need to execute from mysql shell an SQL file based on a condition like mysql> source @var where @var contains the filename

flag

1 Answer

vote up 0 vote down

this is not possible. "source" is a command that is recognized and executed locally by the mysql client program. variables exist on the server so the client has no idea what @variable means.

link|flag

Your Answer

Get an OpenID
or
never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.