Skip to content

Commit f1b0013

Browse files
Fix the char type
1 parent 0eacaf3 commit f1b0013

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/NHibernate/Type/AbstractCharType.cs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,9 +51,7 @@ public override void Set(DbCommand cmd, object value, int index, ISessionImpleme
5151
}
5252

5353
public override string ObjectToSQLString(object value, Dialect.Dialect dialect)
54-
{
55-
return '\'' + value.ToString() + '\'';
56-
}
54+
=> dialect.ToStringLiteral(value.ToString(), SqlType);
5755

5856
// 6.0 TODO: rename "xml" parameter as "value": it is not a xml string. The fact it generally comes from a xml
5957
// attribute value is irrelevant to the method behavior.

0 commit comments

Comments
 (0)