Hi @Brian Melvin
All you need to do is import the sqlServer powershell module and make sure your sql server is accessible externally.
Here is a nice blog about the subject.
execute mysql script from azure automation powershell runbook
Brian Melvin
1
Reputation point
I have a mysql dump file (essentially a mysql sql script file) which i need to run against an azure mysql database
How do I do this within a powershell script in an azure automation runbook?
I've used azure cloud shell to do it before and the mysql.exe program seemed to be available out of the box, but the max timeout is too short so i'm trying to do this in azure automation instead.
When i tried it i got the message:
The term 'mysql' is not recognized as the name of a cmdlet, function, script file, or operable program.
thanks in advance
1 answer
Sort by: Most helpful
-
amon 126 Reputation points Microsoft Employee
2021-02-25T16:08:02.603+00:00