VS 2005 NET connector commandtext and parameters
Posted by: Frank Puigdemont
Date: February 09, 2007 12:19PM

Frank

My program execute de normal query with command params,

//Example:
Dim mySelectQuery As String = "SELECT OrderID, CustomerID FROM Orders WHERE OrderID = ?1"
Dim myConnection As New MySqlConnection(myConnString)
Dim myCommand As New MySqlCommand(mySelectQuery, myConnection)
mycommand.parameters.add("?1",202)

myConnection.Open()
Dim myReader As MySqlDataReader
myReader = myCommand.ExecuteReader()


I would like to write in log file the full commandtext, with params values (SELECT OrderID, CustomerID FROM Orders WHERE OrderID = 202).

As I can obtain string?

Thanks

Options: ReplyQuote


Subject
Written By
Posted
VS 2005 NET connector commandtext and parameters
February 09, 2007 12:19PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.