Search code examples
node.jsgoogle-cloud-platformknex.jsgoogle-cloud-spanner

Does knex has cloud spanner support


We are currently using NodeJs with Knex for connecting with MySQL.
We have plans to migrate our database to Cloud Spanner.
So wanted to know, if knexjs has support for cloud spanner.
I did not see any related articles in their official website (http://knexjs.org/).

If not, any ORM which has support to both MySQL and Cloud Spanner which will have minimal changes from knexjs


Solution

  • We continued using Knexjs for our Spanner operations. It is working fine so far. We build the queries using knex and convert it to raw queries using

    querybuilder.toSQL()
    

    and binding the parameters.