Skip to content

Commit 4b9048a

Browse files
authored
Update README
1 parent f051e55 commit 4b9048a

1 file changed

Lines changed: 2 additions & 5 deletions

File tree

README.md

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -336,9 +336,7 @@ private List<Person> getPersonList(int num) {
336336

337337
### How can I write a ``java.sql.Timestamp``? ###
338338

339-
You probably have Java classes with a ``java.sql.Timestamp`` to represent timestamps in an application. Now if
340-
you use the ``AbstractMapping`` or ``simpleRowWriter`` it expects a ``LocalDateTime``! Isn't it supported? How can
341-
you write a ``Timestamp`` then?
339+
You probably have Java classes with a ``java.sql.Timestamp`` in your application. Now if you use the ``AbstractMapping`` or a ``SimpleRowWriter`` it expects a ``LocalDateTime``. Here is how to map a ``java.sql.Timestamp``.
342340

343341
Imagine you have an ``EMail`` class with a property ``emailCreateTime``, that is using a ``java.sql.Timestamp`` to
344342
represent the time. The column name in Postgres is ``email_create_time`` and you are using a ``timestamp`` data type.
@@ -373,8 +371,7 @@ public static class EMailMapping extends AbstractMapping<EMail>
373371

374372
### Handling Null Characters or... 'invalid byte sequence for encoding "UTF8": 0x00' ###
375373

376-
If you see the error message ``invalid byte sequence for encoding "UTF8": 0x00`` your data contains Null Characters. Although ``0x00`` is
377-
valid UTF-8 PostgreSQL does not support writing it, because it uses C-style string termination internally.
374+
If you see the error message ``invalid byte sequence for encoding "UTF8": 0x00`` your data contains Null Characters. Although ``0x00`` is totally valid UTF-8... PostgreSQL does not support writing it, because it uses C-style string termination internally.
378375

379376
PgBulkInsert allows you to enable a Null Value handling, that removes all ``0x00`` occurences and replaces them with an empty string:
380377

0 commit comments

Comments
 (0)