Hi Alexey...
I am having some problem with Update command of Mysqldataadapter of Mydirect.Net.
I am updating a row in which a field contains 3 mb data.
Data type of this field is LONGTEXT.
Now when i insert this row,It gives error message as below.
"Lost connection to MySQL server during query"
CoreLab.MySql.MySqlException
errorcode:2013
I searched and changed some variables in Mysql server as below.
wait_timeout
max_allowed_packet
write_timeOut
read_timeout
I set all this field to proper amount of time.
--->I saw a property of Mysqladapter named "UpdateBatchtime".Do i need to change this property???
Thanks
Amish
Error at Update time
-
- Posts: 729
- Joined: Thu 13 Dec 2007 10:24
Hi..
I tried using MysqlCommand.commandtimeout property as you suggested but it didnt work....
Below is the stack trace which gives exception when i use command.executenonquery
at CoreLab.MySql.a5.d(Byte[] A_0, Int32 A_1, Int32 A_2)
at CoreLab.MySql.a5.b(Byte[] A_0, Int32 A_1, Int32 A_2)
at CoreLab.MySql.b.a(at A_0, Byte[] A_1, Int32 A_2, Boolean A_3)
at CoreLab.MySql.b.a(Byte[] A_0, Int32 A_1, Boolean A_2)
at CoreLab.MySql.ab.e()
at CoreLab.MySql.ab.o()
at CoreLab.MySql.MySqlCommand.a(CommandBehavior A_0, IDisposable A_1, Int32 A_2, Int32 A_3)
at CoreLab.Common.DbCommandBase.ExecuteDbDataReader(CommandBehavior behavior)
at CoreLab.Common.DbCommandBase.ExecuteNonQuery()
Hope this can help you suggesting solution
Thanks
Amish
I tried using MysqlCommand.commandtimeout property as you suggested but it didnt work....
Below is the stack trace which gives exception when i use command.executenonquery
at CoreLab.MySql.a5.d(Byte[] A_0, Int32 A_1, Int32 A_2)
at CoreLab.MySql.a5.b(Byte[] A_0, Int32 A_1, Int32 A_2)
at CoreLab.MySql.b.a(at A_0, Byte[] A_1, Int32 A_2, Boolean A_3)
at CoreLab.MySql.b.a(Byte[] A_0, Int32 A_1, Boolean A_2)
at CoreLab.MySql.ab.e()
at CoreLab.MySql.ab.o()
at CoreLab.MySql.MySqlCommand.a(CommandBehavior A_0, IDisposable A_1, Int32 A_2, Int32 A_3)
at CoreLab.Common.DbCommandBase.ExecuteDbDataReader(CommandBehavior behavior)
at CoreLab.Common.DbCommandBase.ExecuteNonQuery()
Hope this can help you suggesting solution
Thanks
Amish
-
- Posts: 729
- Joined: Thu 13 Dec 2007 10:24
Hello Amish!
To solve the problem, try setting:
in the MySQL server configuration. Please ensure that this property has changed indeed (you can use 'show variables' command).
To solve the problem, try setting:
Code: Select all
[mysqld]
max_allowed_packet=167772160
Its done....
But i was not able do it the way you suggested.
I changed the variable max_allowed_packet to the the value you described above in my.ini file in Program files of MYSQL 4.1.
I failed to do it in mysql command line.
Some syntax problem was there.
Anyways..
Thank you very much for your help.
But i was not able do it the way you suggested.
I changed the variable max_allowed_packet to the the value you described above in my.ini file in Program files of MYSQL 4.1.
I failed to do it in mysql command line.
Some syntax problem was there.
Anyways..
Thank you very much for your help.
-
- Posts: 729
- Joined: Thu 13 Dec 2007 10:24