polygene-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nic...@apache.org
Subject [1/2] polygene-java git commit: Added missing "createdColumn" to the ASSOCS tables.
Date Sat, 28 Oct 2017 16:00:22 GMT
Repository: polygene-java
Updated Branches:
  refs/heads/develop c2aa70698 -> 0e399e071


Added missing "createdColumn" to the ASSOCS tables.


Project: http://git-wip-us.apache.org/repos/asf/polygene-java/repo
Commit: http://git-wip-us.apache.org/repos/asf/polygene-java/commit/3705ce97
Tree: http://git-wip-us.apache.org/repos/asf/polygene-java/tree/3705ce97
Diff: http://git-wip-us.apache.org/repos/asf/polygene-java/diff/3705ce97

Branch: refs/heads/develop
Commit: 3705ce9750d2366bd4d8b205a30bc5651610edba
Parents: c2aa706
Author: niclas <niclas@hedhman.org>
Authored: Sat Oct 28 23:22:58 2017 +0800
Committer: niclas <niclas@hedhman.org>
Committed: Sat Oct 28 23:22:58 2017 +0800

----------------------------------------------------------------------
 .../main/java/org/apache/polygene/entitystore/sql/MixinTable.java | 3 +++
 1 file changed, 3 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/polygene-java/blob/3705ce97/extensions/entitystore-sql/src/main/java/org/apache/polygene/entitystore/sql/MixinTable.java
----------------------------------------------------------------------
diff --git a/extensions/entitystore-sql/src/main/java/org/apache/polygene/entitystore/sql/MixinTable.java
b/extensions/entitystore-sql/src/main/java/org/apache/polygene/entitystore/sql/MixinTable.java
index aa567f2..cf0968c 100644
--- a/extensions/entitystore-sql/src/main/java/org/apache/polygene/entitystore/sql/MixinTable.java
+++ b/extensions/entitystore-sql/src/main/java/org/apache/polygene/entitystore/sql/MixinTable.java
@@ -143,6 +143,7 @@ class MixinTable
                                       for( EntityReference ref : entityReferences )
                                       {
                                           InsertSetMoreStep<Record> set = assocsTable.set(
identityColumn, valueIdentity )
+                                                                                     .set(
createdColumn, new Timestamp( System.currentTimeMillis() ) )
                                                                                      .set(
nameColumn, assocName.name() )
                                                                                      .set(
indexColumn, "" + counter++ )
                                                                                      .set(
referenceColumn, ref == null ? null : ref.identity().toString() );
@@ -169,6 +170,7 @@ class MixinTable
                                            {
                                                EntityReference ref = entityReferences.get(
name );
                                                InsertSetMoreStep<Record> set = assocsTable.set(
identityColumn, valueIdentity )
+                                                                                        
 .set( createdColumn, new Timestamp( System.currentTimeMillis() ) )
                                                                                         
 .set( nameColumn, assocName.name() )
                                                                                         
 .set( indexColumn, name )
                                                                                         
 .set( referenceColumn, ref.identity().toString() );
@@ -255,6 +257,7 @@ class MixinTable
             Table<Record> table = dsl.tableOf( mixinTable.getName() + ASSOCS_TABLE_POSTFIX
);
             int result2 = dsl.createTableIfNotExists( table )
                              .column( identityColumn )
+                             .column( createdColumn )
                              .column( nameColumn )
                              .column( indexColumn )
                              .column( referenceColumn )


Mime
View raw message