Difference between revisions of "MySQL and PowerShell"

Jump to navigation Jump to search
m
Minor reformatting, and Meta
m (→‎Test for NULL: Added additional error example)
m (Minor reformatting, and Meta)
Line 1: Line 1:
To be able to interact with a MySQL database from PowerShell you need to have the MySQL .NET Connector installed first - http://dev.mysql.com/downloads/connector/net/
To be able to interact with a MySQL database from PowerShell you need to have the MySQL .NET Connector installed first on the machine that you're going to run PowerShell from - http://dev.mysql.com/downloads/connector/net/


= Connect =
= Connect =
Line 19: Line 19:
   $conn.Close()
   $conn.Close()
}
}
</source>


# So, for example...
So, for example...
 
<source lang="powershell">
# Connection Variables  
# Connection Variables  
$user = 'myuser'  
$user = 'myuser'  

Navigation menu