Hello DevBest,
This is just a simple bug and it's to do with MySQL however I can't find what it is, So I have gave you people on DevBest the challenge. It is something to do with my table structure that I am using for the pets table in the database. The error shown below is the error which can by found in my MySQL Error file on the emulator. On the console the error that was wrote was "Error caught in query". The error that I have is the parameter "@name" is null and it contains no name, when the pet it'self have the name "Test4" this name contains no invalid characters so that should not be the issue.
Error (MySQL Error File)
Many thanks,
Kieran.
This is just a simple bug and it's to do with MySQL however I can't find what it is, So I have gave you people on DevBest the challenge. It is something to do with my table structure that I am using for the pets table in the database. The error shown below is the error which can by found in my MySQL Error file on the emulator. On the console the error that was wrote was "Error caught in query". The error that I have is the parameter "@name" is null and it contains no name, when the pet it'self have the name "Test4" this name contains no invalid characters so that should not be the issue.
Error (MySQL Error File)
Code:
Error in query:
UPDATE user_pets SET room_id = 0, name = [URL='http://devbest.com/members/name.7391/']name[/URL], race = @race, color = @color, type = 15, expirience = 0, energy = 100, nutrition = 100, respect = 0, createstamp = '1365903481', x = 0, Y = 0, Z = 0 WHERE id = 4
MySql.Data.MySqlClient.MySqlException (0x80004005): Fatal error encountered during command execution. ---> MySql.Data.MySqlClient.MySqlException (0x80004005): Parameter '@name' must be defined.
at MySql.Data.MySqlClient.Statement.SerializeParameter(MySqlParameterCollection parameters, MySqlPacket packet, String parmName)
at MySql.Data.MySqlClient.Statement.InternalBindParameters(String sql, MySqlParameterCollection parameters, MySqlPacket packet)
at MySql.Data.MySqlClient.Statement.BindParameters()
at MySql.Data.MySqlClient.PreparableStatement.Execute()
at MySql.Data.MySqlClient.MySqlCommand.ExecuteReader(CommandBehavior behavior)
at MySql.Data.MySqlClient.MySqlCommand.ExecuteReader(CommandBehavior behavior)
at MySql.Data.MySqlClient.MySqlCommand.ExecuteNonQuery()
at Database_Manager.Database.Session_Details.QueryAdapter.runQuery()
Many thanks,
Kieran.