Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
please Help Me Vb sign up with MySql.Data.MySqlClient
#2
Well, the problem is not with your VB.NET code, but actually lies within your MySQL database itself. When you update the table code with this line,
Code:
Dim sqlquery2 As String = "INSERT INTO code (Username, Password)VALUES ('" & TextBox1.Text & "','" & TextBox2.Text & "')"

You do not specify a value for the "Name" field in your database table. And your name field does not know what to do if a value is not specified, so it throws you this error. There are two main ways to solve this.
Option 1. When you make your INSERT code call, specify a value for the Name field
Option 2. Set a default value for the name field in your DB4FREE Settings.
My Blog | My Setup | My Videos | Have a wonderful day.


Messages In This Thread
Re: please Help Me Vb sign up with MySql.Data.MySqlClient - by brandonio21_phpbb3_import2 - 04-20-2012, 03:23 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  MySQL / Wamp Server Issues jaminben 2 12,977 04-22-2012, 10:31 AM
Last Post: brandonio21
  connect to mysql client cry1978 2 11,051 07-12-2011, 11:09 AM
Last Post: brandonio21
  MySQL Module xolara 4 16,787 04-16-2011, 12:28 AM
Last Post: xolara

Forum Jump:


Users browsing this thread: 1 Guest(s)