![]() | |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
I have a column that is my primary key... it has PK and NN checked off in MySQL Workbench table editor... However software is able to write a record where the columns value is ''... Which isn't NULL I guess.. but what do I do in the table construction SQL so that blank isn't valid either? try making it an autoincrementing integer..and never ever write to it on |
#3
| |||
| |||
|
|
SpreadTooThin wrote: I have a column that is my primary key... it has PK and NN checked off in MySQL Workbench table editor... However software is able to write a record where the columns value is ''... Which isn't NULL I guess.. but what do I do in the table construction SQL so that blank isn't valid either? try making it an autoincrementing integer..and never ever write to it on pain of ..something or other.:-) |
#4
| |||
| |||
|
|
On Mar 15, 3:36 pm, The Natural Philosopher <t... (AT) invalid (DOT) invalid wrote: SpreadTooThin wrote: I have a column that is my primary key... it has PK and NN checked off in MySQL Workbench table editor... However software is able to write a record where the columns value is ''... Which isn't NULL I guess.. but what do I do in the table construction SQL so that blank isn't valid either? try making it an autoincrementing integer..and never ever write to it on pain of ..something or other.:-) But its a VARCHAR.... |
#5
| |||
| |||
|
|
I have a column that is my primary key... it has PK and NN checked off in MySQL Workbench table editor... However software is able to write a record where the columns value is ''... Which isn't NULL I guess.. but what do I do in the table construction SQL so that blank isn't valid either? |
#6
| |||
| |||
|
|
I have a column that is my primary key... it has PK and NN checked off in MySQL Workbench table editor... However software is able to write a record where the columns value is ''... Which isn't NULL I guess.. but what do I do in the table construction SQL so that blank isn't valid either? |
#7
| |||
| |||
|
|
I have a column that is my primary key... it has PK and NN checked off in MySQL Workbench table editor... However software is able to write a record where the columns value is ''... Which isn't NULL I guess.. but what do I do in the table construction SQL so that blank isn't valid either? |
#8
| |||
| |||
|
|
On 3/15/2011 5:34 PM, SpreadTooThin wrote: I have a column that is my primary key... it has PK and NN checked off in MySQL Workbench table editor... However software is able to write a record where the columns value is ''... Which isn't NULL I guess.. but what do I do in the table construction You have a database question - try a newsgroup for your database (in this case comp.databases.mysql). You'll get much better answers. |
#9
| |||
| |||
|
|
I have a column that is my primary key... it has PK and NN checked off in MySQL Workbench table editor... However software is able to write a record where the columns value is ''... Which isn't NULL I guess.. |
|
but what do I do in the table construction SQL so that blank isn't valid either? In most databases, this is implemented with CHECK constraints -- which MySQL |
#10
| |||
| |||
|
|
On 3/15/2011 5:34 PM, SpreadTooThin wrote: I have a column that is my primary key... it has PK and NN checked off in MySQL Workbench table editor... However software is able to write a record where the columns value is ''... Which isn't NULL I guess.. but what do I do in the table construction SQL so that blank isn't valid either? You have a database question - try a newsgroup for your database (in this case comp.databases.mysql). You'll get much better answers. |
![]() |
| Thread Tools | |
| Display Modes | |
| |