Github user ankit2711 commented on a diff in the pull request:

    https://github.com/apache/metamodel/pull/58#discussion_r42319647
  
    --- Diff: 
jdbc/src/test/java/org/apache/metamodel/jdbc/JdbcTestTemplates.java ---
    @@ -633,4 +634,84 @@ public void run(UpdateCallback callback) {
                 dataContext.executeUpdate(new DropTable(defaultSchema, 
testTableName));
             }
         }
    +
    +    public static void timestampValueInsertSelect(Connection conn) throws 
Exception {
    +        assertNotNull(conn);
    +
    +        try {
    +            // clean up, if nescesary
    +            conn.createStatement().execute("DROP TABLE test_table");
    +        } catch (SQLException e) {
    +            // do nothing
    +        }
    +
    +        assertFalse(conn.isReadOnly());
    +
    +        JdbcDataContext dc = new JdbcDataContext(conn);
    +        final Schema schema = dc.getDefaultSchema();
    +        final Timestamp timestamp1 = Timestamp.valueOf("2015-10-16 
16:33:33.456");
    +        final Timestamp timestamp2 = Timestamp.valueOf("2015-10-16 
16:33:34.683");
    --- End diff --
    
    This is hard because not all DB drivers claim to have the complete 
fractions parts. If the 6 digit number is placed for the nanos then in Derby. 
H2 and HSQL only first 3 digits are stored. 


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to