Create Table

SIMIN

Well-known member
Joined
Mar 10, 2008
Messages
92
Hi,
I want to create a table in my database, and also create a field in it named "Names" which is text, and also set a primary key named ID.
So I use this string connection:

"CREATE TABLE " + TableTextBoxX.Text + " (ID INT PRIMARY KEY, Names Text(255))"

But I get syntax error!
I played around with that but could not find how it should be correct!
Please help me:(
 
PlausiblyDamp really thank you!
you are great!
It works now, just one problem is that it does not create the primary key for my table I want ID to be primary key.
Where I am wrong? :confused:
 
Back
Top