![]() |
#2
xuegao2008-06-04 18:24
|
无法将 NULL 值插入列 'chexing',表 'fty.dbo.车型表';该列不允许空值。INSERT 失败。
语句已终止。
表为:车型表 列名chexing(主键) chepaihao explain
Dim conn As New SqlConnection("Data Source=FTY;Initial Catalog=fty;Integrated Security=True ")
Dim str As String
str = "insert into 车型表(chepaihao) values( 'textbox1.text' )"
Dim comm As New SqlCommand(str, conn)
conn.Open()
comm.ExecuteNonQuery()
conn.Close()