Page 1 of 1

Date Types with Postgresql

Posted: Mon 01 Apr 2013 11:15
by Mikkeli
When i try to
Generate Database Script from model...
and
Update database from model
Date datatypes is all mapped to date
Sample:
CREATE TABLE efinvoice.class1s (
id UUID NOT NULL,
property_date DATE NOT NULL,
property_datetime DATE NOT NULL,
property_datetime2 DATE NOT NULL,
property_dbtimestamp DATE NOT NULL,
property_localdatetme DATE NOT NULL,
property_utcdatetime DATE NOT NULL,
property_timestamp DATE NOT NULL,
property_time DATE NOT NULL,
"version" DATE NOT NULL,
CONSTRAINT "PK_class1s" PRIMARY KEY (id)

How I change those to correct one (Even version is DATE, not timestamp)

I use Devart Entity Developer 5.0.66.0 and fluent nhibernate template

Re: Date Types with Postgresql

Posted: Tue 02 Apr 2013 07:35
by Shalex
Thank you for the report. We will post here when the behaviour is changed: System.DateTime .NET structure will be mapped to TIMESTAMP database type.

Re: Date Types with Postgresql

Posted: Wed 03 Apr 2013 05:51
by Shalex
As a temporary workaround, please specify the server type explicitly: Property Editor > Column [...] > SQL Type.

Re: Date Types with Postgresql

Posted: Fri 05 Apr 2013 12:59
by Shalex
The behaviour is changed: System.DateTime .NET structure is mapped to TIMESTAMP database type when using Model First approach starting from the 5.5.80 build of Entity Developer: http://forums.devart.com/viewtopic.php?f=32&t=26309.
It can be downloaded from http://www.devart.com/entitydeveloper/download.html (trial version) or from Registered Users' Area (for users with active subscription only).