this is my powershell code :
[void][System.Reflection.Assembly]::LoadFile(\"C:\\DLL\\Oracle.ManagedDataAccess.dll\")
$OracleConnexion = New-Object Oracle.Ma
I would wrap your connection by a using statement. When you're done with your connection then close it before adding the bracket. To be 100% safe I would do something like this:
using(OracleConnexion Con = new OracleConnection (...))
{
Con.Open()
...
Con.Close()
}
Edit:
I added the Con.Close(), because in the past the dispose was not implemented correctly in the ODP.NET. The connection was kept open. We had to force the connection to close manually and that's why in the example, I specify the Close.