Giter Club home page Giter Club logo

Comments (6)

markusahlstrand avatar markusahlstrand commented on September 13, 2024

Hi @vdimitrieski ,

Thanks for reporting the issue. The test for migrations and mysql is currently commented out and I can't remember when and why this happened.. I'll see if I can get it passing again.

from knex-data-api-client.

markusahlstrand avatar markusahlstrand commented on September 13, 2024

I get this error for the migrations test:

data-api-mysql
       knex-migrate
         should setup a database with knex-migrate:
     insert into `knex_migrations` (`batch`, `migration_time`, `name`) values (1, '2021-06-02 16:02:46.063', '20191220234943_init.js') - Database error code: 1292. Message: Data truncation: Incorrect datetime value: '"2021-06-02T14:02:46.063Z"' for column 'migration_time' at row 1

So, I guess it has something to do with differences in timestamps formats in mysql vs postgres?

from knex-data-api-client.

vdimitrieski avatar vdimitrieski commented on September 13, 2024

@markusahlstrand thanks for checking out. If you take a look at the error, I think the knex-generated insert command contains a well formatted datetime '2021-06-02 16:02:46.063', but when it reaches Aurora MySQL it is actually in the format '2021-06-02T14:02:46.063Z' which bounced. As this knex-generated insert command is valid, and you can actually can execute it in the Aurora query builder, I assume the error is somewhere in the middle :)

Any thoughts of what it might be?

from knex-data-api-client.

markusahlstrand avatar markusahlstrand commented on September 13, 2024

Seems like it's being passed as a datetime and we're not handing it correctly when converting it to a sql string. Should hopefully be a quick fix

from knex-data-api-client.

markusahlstrand avatar markusahlstrand commented on September 13, 2024

Published 1.5.5 with a fix that at least makes the migration test happy :) Let me know if it works for you.

from knex-data-api-client.

vdimitrieski avatar vdimitrieski commented on September 13, 2024

It works now with Aurora MySQL as well. Thanks for the fast fix!

from knex-data-api-client.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.