---
title: "sybase 12.5 insert null values "
author: "standalone"
date: "2012-02-28T12:54:28Z"
tags: []
categories: ["数据库"]
slug: "sybase-12-5-insert-null-values"
draft: false
lastmod: "2012-02-28T12:54:28Z"
id: 1429017
url: "https://standalone.iteye.com/blog/1429017"
---

It's weird that sybase will convert empty string into ' ' (note: not empty but just a whitespace). 

So if you want to insert a null into a row, you should do like this:

 

insert tabe xxx values (..., null, ...)

 

That's, include a null value in your sql query, or you should not metion that column name in the sql, it defaultly will insert a null.