all groups > sql server new users > june 2005 >
You're in the

sql server new users

group:

how to empty a field?


Re: how to empty a field? Jens Süßmeyer
6/28/2005 12:00:00 AM
sql server new users: Then press CTRL + 0, that will give you a NULL value to enter in the field.

HTH, Jens Suessmeyer.

---
http://www.sqlserver2005.de
---

"r" <r@r.com> schrieb im Newsbeitrag
news:uLqaThAfFHA.612@TK2MSFTNGP12.phx.gbl...
[quoted text, click to view]

how to empty a field? r
6/28/2005 10:06:09 AM
I have a table that contains a smalldatetime field. One of the records had
a date entered into this field, and now I need to remove the date from the
field. Whenever I try to just "delete" it (delete key) I get a message:

The value you entered is not consistent with the data type or length of the
column.

What can I do to just get that date out of there?! Ideally I'd make the
field NULL.

HELP!

Thanks.

-R

Re: how to empty a field? r
6/28/2005 10:36:31 AM
Nevermind. Got it. CTRL+0 will make the field null.


[quoted text, click to view]

Re: how to empty a field? r
6/28/2005 10:37:33 AM
Thanks Keith.... I was actually just trying to do it in the table itself
(via Enterprise Manager, or whatever it's called). But that is also helpful
for future reference! : )

-R


[quoted text, click to view]

Re: how to empty a field? Keith Kratochvil
6/28/2005 12:26:55 PM
You will need to do some replacements within this sql statement so that it
will run within your environment

UPDATE YourTable SET YourSmallDateTimeColumn = NULL WHERE ThePrimaryKey = x




--
Keith


[quoted text, click to view]

AddThis Social Bookmark Button