Don't put NULL inside quotes in your update statement. This should work:

UPDATE table SET field = NULL WHERE something = something
Answer from Fosco on Stack Overflow
🌐
GeeksforGeeks
geeksforgeeks.org › sql › how-to-set-a-column-value-to-null-in-sql
How to Set a Column Value to Null in SQL? - GeeksforGeeks
MySQL · Sign In ▲ · Open In App · Last Updated : 23 Jul, 2025 · Comments · Improve · Suggest changes · Like Article · Like · Report · You can set a column value to NULL using the SQL UPDATE statement.
Published   July 23, 2025
🌐
W3Schools
w3schools.com › mysql › mysql_null_values.asp
MySQL NULL Values - IS NULL and IS NOT NULL
HTML CSS JAVASCRIPT SQL PYTHON JAVA PHP HOW TO W3.CSS C C++ C# BOOTSTRAP REACT MYSQL JQUERY EXCEL XML DJANGO NUMPY PANDAS NODEJS DSA TYPESCRIPT ANGULAR ANGULARJS GIT POSTGRESQL MONGODB ASP AI R GO KOTLIN SWIFT SASS VUE GEN AI SCIPY CYBERSECURITY DATA SCIENCE INTRO TO PROGRAMMING BASH RUST ... MySQL SQL MySQL SELECT MySQL WHERE MySQL AND, OR, NOT MySQL ORDER BY MySQL INSERT INTO MySQL NULL Values MySQL UPDATE MySQL DELETE MySQL LIMIT MySQL MIN and MAX MySQL COUNT, AVG, SUM MySQL LIKE MySQL Wildcards MySQL IN MySQL BETWEEN MySQL Aliases MySQL Joins MySQL INNER JOIN MySQL LEFT JOIN MySQL RIGHT JOIN MySQL CROSS JOIN MySQL Self Join MySQL UNION MySQL UNION ALL MySQL GROUP BY MySQL HAVING MySQL EXISTS MySQL ANY, ALL MySQL INSERT SELECT MySQL CASE MySQL Null Functions MySQL Comments MySQL Operators
🌐
C# Corner
c-sharpcorner.com › UploadFile › 65fc13 › how-to-handle-the-null-values-in-mysql-server
How to Handle Null Values in MYSQL?
By using the assignment operator (“=”), you can set any value of a column to NULL by using the Update Statement. ... By using the following query, you can check the output. SELECT * FROM GROWTHMINDSETS WHERE EmailAddress IS NULL AND PhoneNo ...
🌐
MySQL
dev.mysql.com › doc › refman › 8.4 › en › working-with-null.html
MySQL :: MySQL 8.4 Reference Manual :: 5.3.4.6 Working with NULL Values
These are in fact values, whereas NULL means “not having a value.” You can test this easily enough by using IS [NOT] NULL as shown: mysql> SELECT 0 IS NULL, 0 IS NOT NULL, '' IS NULL, '' IS NOT NULL; +-----------+---------------+------------+----------------+ | 0 IS NULL | 0 IS NOT NULL | '' IS NULL | '' IS NOT NULL | +-----------+---------------+------------+----------------+ | 0 | 1 | 0 | 1 | +-----------+---------------+------------+----------------+ Thus it is entirely possible to insert a zero or empty string into a NOT NULL column, as these are in fact NOT NULL.
🌐
MySQL
dev.mysql.com › doc › refman › 8.0 › en › problems-with-null.html
MySQL :: MySQL 8.0 Reference Manual :: B.3.4.3 Problems with NULL Values
To help with NULL handling, you can use the IS NULL and IS NOT NULL operators and the IFNULL() function. In SQL, the NULL value is never true in comparison to any other value, even NULL. An expression that contains NULL always produces a NULL value unless otherwise indicated in the documentation ...
Find elsewhere
🌐
Coursesweb
coursesweb.net › php-mysql › insert-select-update-null-value_t
Insert, Select and Update NULL value in MySQL
$sql = "INSERT INTO `table_name` (`column1`, `column2`, `column3`) VALUES ('val1', 'NULL', 'val3')"; The same works with UPDATE. Example: $sql = "UPDATE `table_name` SET `column1`='val1', `column2`=NULL, WHERE `column3`='val3'"; Or: $nul = 'NULL'; ...
🌐
w3resource
w3resource.com › sql › insert-statement › insert-null.php
Sql inserting NULL values - w3resource
-- This SQL code attempts to insert a new row into the 'agents' table. -- INSERT INTO statement begins INSERT INTO agents -- Specifies the table 'agents' where the data will be inserted VALUES ("A001","Jodi","London",.12,NULL); -- Specifies the values to be inserted into each column of the table: -- "A001" will be inserted into the 'agent_code' column (assuming it's a string data type) -- "Jodi" will be inserted into the 'agent_name' column -- "London" will be inserted into the 'working_area' column -- .12 will be inserted into the 'commission' column (assuming it's a numeric data type) -- NULL will be inserted into the 'salary' column, assuming it allows NULL values
🌐
TutorialsPoint
tutorialspoint.com › insert-null-value-into-int-column-in-mysql
Insert NULL value into INT column in MySQL?
INSERT INTO yourTableName(yourColumnName) values(NULL); To understand the above syntax, let us first create a table. The query to create a table is as follows. mysql> create table InsertNullDemo -> ( -> StudentId int, -> StudentName varchar(100), -> StudentAge int -> ); Query OK, 0 rows affected ...
🌐
TutorialsPoint
tutorialspoint.com › how-to-set-default-value-to-null-in-mysql
How to set default value to NULL in MySQL?
Use DEFAULT keyword in MySQL to set default value to NULL. Let us first create a − mysql> create table DemoTable1440 -> ( -> StudentId int NOT NULL AUTO_INCREMENT PRIMARY
🌐
MySQL Tutorial
mysqltutorial.org › home › mysql basics › mysql null: the beginner’s guide
MySQL NULL
December 29, 2023 - To set the value of a column to NULL, you use the assignment operator ( =). For example, to update the phone of David William to NULL, you use the following UPDATE statement: UPDATE leads SET phone = NULL WHERE id = 3;Code language: SQL (Structured ...
🌐
MySQL
dev.mysql.com › doc › refman › 8.0 › en › working-with-null.html
MySQL :: MySQL 8.0 Reference Manual :: 5.3.4.6 Working with NULL Values
These are in fact values, whereas NULL means “not having a value.” You can test this easily enough by using IS [NOT] NULL as shown: mysql> SELECT 0 IS NULL, 0 IS NOT NULL, '' IS NULL, '' IS NOT NULL; +-----------+---------------+------------+----------------+ | 0 IS NULL | 0 IS NOT NULL | '' IS NULL | '' IS NOT NULL | +-----------+---------------+------------+----------------+ | 0 | 1 | 0 | 1 | +-----------+---------------+------------+----------------+ Thus it is entirely possible to insert a zero or empty string into a NOT NULL column, as these are in fact NOT NULL.
🌐
TutorialsPoint
tutorialspoint.com › mysql-update-column-to-null-for-blank-values
MySQL update column to NULL for blank values
mysql> update DemoTable1601 set LastName=if(LastName='',NULL,LastName); Query OK, 2 rows affected (0.22 sec) Rows matched: 4 Changed: 2 Warnings: 0 ... +-----------+----------+ | FirstName | LastName | +-----------+----------+ | John | Doe | | Adam | NULL | | David | Miller | | Chris | NULL | +-----------+----------+ 4 rows in set (0.00 sec)
🌐
TutorialsPoint
tutorialspoint.com › how-to-set-a-column-value-to-null-in-sql
How to Set a Column Value to Null in SQL?
UPDATE table_name SET column_name = NULL WHERE conditions; ... NULL: Denotes the NULL value in SQL.
🌐
MySQL
dev.mysql.com › doc › refman › 8.4 › en › problems-with-null.html
MySQL :: MySQL 8.4 Reference Manual :: B.3.4.3 Problems with NULL Values
To help with NULL handling, you can use the IS NULL and IS NOT NULL operators and the IFNULL() function. In SQL, the NULL value is never true in comparison to any other value, even NULL. An expression that contains NULL always produces a NULL value unless otherwise indicated in the documentation ...
🌐
TutorialsPoint
tutorialspoint.com › mysql › mysql-null-values.htm
MySQL - NULL Values
To update NULL values in a table, you can use the "UPDATE" statement with the "IS NULL" operator. This filter the rows containing NULL values and set new values using the "SET" keyword.
🌐
MySQL
dev.mysql.com › doc › refman › 8.0 › en › null-values.html
MySQL :: MySQL 8.0 Reference Manual :: 11.1.7 NULL Values
Be aware that the NULL value is different from values such as 0 for numeric types or the empty string for string types. For more information, see Section B.3.4.3, “Problems with NULL Values”.
🌐
Xojo Programming Forum
forum.xojo.com › databases
MySQL: How to assign Null Value to Field when Inserting a record? - Databases - Xojo Programming Forum
February 22, 2017 - I am using MySQL. How do I assign a Null value to a CHAR Field when inserting a record? Dim Row As New DatabaseRecord Row.Column("ID") = "ABC" Row.Column("Contents") = Nil mDB.InsertRecord("ABC", Row) I…