1
Answer

Vb.net to Mysql

Photo of ramesh babu

ramesh babu

15y
5.4k
1
I written coding below it display error
"Fatal error encountered during command execution."
How can i rectify

Coding is....
MyTrans = Myconn.BeginTransaction()
Mycmd = New MySqlCommand()
Mycmd.Connection = Myconn
Mycmd.CommandText = "DELIMITER $$ " & _
" CREATE PROCEDURE `Sp_example`(in Name varchar(45)) BEGIN " & _
" declare _output int; " & _
" select count(id) from name " &_
" where createdby=_Userid " &_
" into _output; " &_
" select _output; " _
" END $$ " & _
" DELIMITER ; "
Mycmd.CommandType = CommandType.Text
If Myconn.State <> ConnectionState.Open Then Myconn.Open()
Mycmd.ExecuteNonQuery()
MyTrans.Commit()

Answers (1)

Next Recommended Forum