Work at SourceForge, help us to make it a better place! We have an immediate need for a Support Technician in our San Francisco or Denver office.

Close

#18 Upserts don't work for certain postgres types (e.g time)

pending-fixed
Ralf Wisser
None
5
2012-06-21
2012-06-20
Tom
No

If you export the time type from postgres with the upsert option the sql produced looks like this:

Insert into blah(field, field, timefield time) select * from (values (blah, blah, '10:00:00'))

Postgres complains that:
ERROR: column "test" is of type time without time zone but expression is of type text

If you add a cast to time like so

time '10:00:00'

this command works fine, this is already done for timestamps.

One imagines that there might be similar errors for other types.

Postgres version:
PostgreSQL 9.0.5 on x86_64-pc-linux-gnu, compiled by GCC gcc-4.5.real (Ubuntu/Linaro 4.5.2-8ubuntu4) 4.5.2, 64-bit
Jailer version: 4.0.7

Discussion

  • Ralf Wisser
    Ralf Wisser
    2012-06-21

    • assigned_to: nobody --> rwisser
     
  • Ralf Wisser
    Ralf Wisser
    2012-06-21

    • status: open --> pending-fixed
     
  • Ralf Wisser
    Ralf Wisser
    2012-06-21

    fixed in release 4.0.11