0

i was using ms access as my database where my default value for coloum was "" empty string . now i have shifted to sql 2008 where i cannot put empty sting as default value in the same manner as in access i.e "" . here i have to put either '' or " " ie with space within quotes. this value is treated different from "" value. for eg in statement like

if flexgrid.TextMatrix(1, 1)="" then

How can i set empty string in sql so that value is same as access.

thanks

3
Contributors
4
Replies
5
Views
6 Years
Discussion Span
Last Post by AndreRet
0

Your problem lies within your database table in Sql. When the database was created, you have selected that a value MUST be added into the field, hence your error. Edit the specific field in the table to accept null strings.

0

if i accept null string , i get error in vb '"Invalid use of null"

0

Did you change the field property in your table to accept a null string? If so, did you specify in your code that the string must NOT be null, hence the error.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.