Update a Date_Time Field

130 pts.
Tags:
Scripts
SQL
SQL 2005
SQL scripts
SQL Server 2005
I'm trying to update a DATE_TIME field to a NULL value. When I run the script below I get an error. Any ideas on what I'm missing?

UPDATE Orders SET CONFIRMATION_DATE_TIME = ' ' WHERE ST_ID = 102690

ERROR: Msg 245, Level 16, State 1, Line 1 Syntax error converting the varchar value 'Ê' to a column of data type int.

Thanks!



Software/Hardware used:
SQL SERVER 2005

Answer Wiki

Thanks. We'll let you know when a new response is added.

I’m not a SQL Server guy, but in virtually all RDBMSes you would code something like:

SET column_name = NULL

It is important to remember that null values are *special* in the extreme.

HTH

Discuss This Question: 1  Reply

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following