diff --git a/ChangeLog.md b/ChangeLog.md
--- a/ChangeLog.md
+++ b/ChangeLog.md
@@ -1,5 +1,9 @@
 <!-- -*- Markdown -*- -->
 
+## 0.8.3.9
+
+- Fix of unsafeValueNull. ( https://github.com/khibino/haskell-relational-record/issues/55 )
+
 ## 0.8.3.8
 
 - Bugfix of case projected record. ( https://github.com/khibino/haskell-relational-record/issues/54 )
diff --git a/relational-query.cabal b/relational-query.cabal
--- a/relational-query.cabal
+++ b/relational-query.cabal
@@ -1,5 +1,5 @@
 name:                relational-query
-version:             0.8.3.8
+version:             0.8.3.9
 synopsis:            Typeful, Modular, Relational, algebraic query engine
 description:         This package contiains typeful relation structure and
                      relational-algebraic query building DSL which can
diff --git a/src/Database/Relational/Query/Projectable.hs b/src/Database/Relational/Query/Projectable.hs
--- a/src/Database/Relational/Query/Projectable.hs
+++ b/src/Database/Relational/Query/Projectable.hs
@@ -21,7 +21,7 @@
   value,
   valueTrue, valueFalse,
   values,
-  unsafeValueNull,
+  nothing, unsafeValueNull,
 
   -- * Placeholders
   PlaceHolders, unsafeAddPlaceHolders, unsafePlaceHolders,
@@ -73,8 +73,9 @@
 import qualified Language.SQL.Keyword as SQL
 
 import Database.Record
-  (PersistableWidth, PersistableRecordWidth, derivedWidth,
+  (PersistableWidth, persistableWidth, PersistableRecordWidth, derivedWidth,
    HasColumnConstraint, NotNull)
+import Database.Record.Persistable (runPersistableRecordWidth)
 
 import Database.Relational.Query.Internal.SQL (StringSQL, stringSQL, showStringSQL)
 import qualified Database.Relational.Query.Internal.Sub as Internal
@@ -125,10 +126,20 @@
 unsafeProjectSql :: SqlProjectable p => String -> p t
 unsafeProjectSql =  unsafeProjectSql' . stringSQL
 
--- | Polymorphic projection of SQL null value.
-unsafeValueNull :: OperatorProjectable p => p (Maybe a)
-unsafeValueNull =  unsafeProjectSql "NULL"
+-- | Polymorphic projection of SQL null value. Semantics of comparing is unsafe.
+nothing :: (OperatorProjectable (Projection c), SqlProjectable (Projection c), PersistableWidth a)
+        => Projection c (Maybe a)
+nothing = proxyWidth persistableWidth
+  where
+    proxyWidth :: SqlProjectable (Projection c) => PersistableRecordWidth a -> Projection c (Maybe a)
+    proxyWidth w = unsafeProjectSqlTerms' $ replicate (runPersistableRecordWidth w) SQL.NULL
 
+{-# DEPRECATED unsafeValueNull "Use `nothing' instead of this." #-}
+-- | Deprecated. Polymorphic projection of SQL null value.
+unsafeValueNull :: (OperatorProjectable (Projection c), SqlProjectable (Projection c), PersistableWidth a)
+                => Projection c (Maybe a)
+unsafeValueNull = nothing
+
 -- | Generate polymorphic projection of SQL constant values from Haskell value.
 value :: (ShowConstantTermsSQL t, OperatorProjectable p) => t -> p t
 value =  unsafeProjectSqlTerms' . showConstantTermsSQL'
@@ -376,7 +387,7 @@
 casesOrElse = caseSearch
 
 -- | Null default version of 'caseSearch'.
-caseSearchMaybe :: OperatorProjectable (Projection c) -- (Projection c) is always ProjectableMaybe
+caseSearchMaybe :: (OperatorProjectable (Projection c) {- (Projection c) is always ProjectableMaybe -}, PersistableWidth a)
                 => [(Projection c (Maybe Bool), Projection c (Maybe a))] -- ^ Each when clauses
                 -> Projection c (Maybe a)                                -- ^ Result projection
 caseSearchMaybe cs = caseSearch cs unsafeValueNull
@@ -398,7 +409,7 @@
 casesOrElse' =  uncurry case'
 
 -- | Null default version of 'case''.
-caseMaybe :: OperatorProjectable (Projection c) -- (Projection c) is always ProjectableMaybe
+caseMaybe :: (OperatorProjectable (Projection c) {- (Projection c) is always ProjectableMaybe -}, PersistableWidth b)
           => Projection c a                             -- ^ Projection value to match
           -> [(Projection c a, Projection c (Maybe b))] -- ^ Each when clauses
           -> Projection c (Maybe b)                     -- ^ Result projection
diff --git a/test/sqlsEq.hs b/test/sqlsEq.hs
--- a/test/sqlsEq.hs
+++ b/test/sqlsEq.hs
@@ -340,6 +340,14 @@
     .*.
     value 10
 
+caseRecordMaybeX :: Relation () (Maybe (Int32, String))
+caseRecordMaybeX = relation $ do
+  return $
+    caseMaybe
+    (value (5 :: Int32))
+    [ (value (1 :: Int32)  , just $ (,) |$| value (1 :: Int32) |*| value "foo")
+    , (value 3 .+. value 2 , just $ (,) |$| value 2            |*| value "bar") ]
+
 cases :: [Test]
 cases =
   [ eqProp "caseSearch" caseSearchX
@@ -348,6 +356,9 @@
     "SELECT ALL CASE 5 WHEN 1 THEN 'foo' WHEN (3 + 2) THEN 'bar' WHEN 10 THEN 'baz' ELSE 'other' END AS f0"
   , eqProp "caseRecord" caseRecordX
     "SELECT ALL (CASE 5 WHEN 1 THEN 1 WHEN (3 + 2) THEN 2 WHEN 10 THEN 3 ELSE 0 END * 10) AS f0"
+  , eqProp "caseRecordMaybe" caseRecordMaybeX
+    "SELECT ALL CASE 5 WHEN 1 THEN 1 WHEN (3 + 2) THEN 2 ELSE NULL END AS f0, \
+              \ CASE 5 WHEN 1 THEN 'foo' WHEN (3 + 2) THEN 'bar' ELSE NULL END AS f1"
   ]
 
 _p_cases :: IO ()
