Hello, I'm utterly new here and to Oracle technologies.
I've been using Microsoft PowerShell together with ODP.NET to communicate with Oracle databases. So far, so good.
Previously, my use cases has been read-only, so I've been using the following general lines of code to read records:
[Reflection.Assembly]::LoadFile("C:\oracle\product\12.1.0\client32_1\ODP.NET\bin\2.x\Oracle.DataAccess.dll")
$ConnectionString = "User Id=someusername;Password=somepassword;Data Source=somedatasource"
$ConnectionObject = New-Object Oracle.DataAccess.Client.OracleConnection($ConnectionString)
$ConnectionObject.Open()
$SQLQuery = "SELECT * FROM SOME_TABLE"
$SQLCommand = New-Object Oracle.DataAccess.Client.OracleCommand($SQLQuery,$ConnectionObject)
$SQLReader = $SQLCommand.ExecuteReader()
However, now I have need to run an UPDATE SQL command against this same database, obviously followed by a COMMIT.
I'm assuming I don't use the "ExecuteReader" for this? I can't find an equivalent "ExecuteWriter" method in the ODP.NET for running queries that UPDATE the database.
I realise this is a real n00b question, but if anyone can advise me how I proceed to invoke queries that make changes to the database, I'd be so grateful.