Giter Club home page Giter Club logo

Comments (7)

lecaillon avatar lecaillon commented on July 28, 2024

Well, I reproduced partially your issue. I saw in the output window the SQLite error you mentioned.
But not 3 times for each migration scripts. Only 3 times by migration. Do you run Evolve.Migrate() multiples times ?

from evolve.

Andrewwelton avatar Andrewwelton commented on July 28, 2024

Apologies, I must've had something else going on to have it happen multiple times as I can't reproduce that part now. It is only the 3 for the whole migration.

from evolve.

Andrewwelton avatar Andrewwelton commented on July 28, 2024

That method was my best guess as to the cause of it. It was the only place I saw the "SHOW" sql query being used. Just seems weird if I'm providing the Driver when instantiating the class, shouldn't that be an indication?

As I mentioned, it definitely doesn't impact the performance of the framework (which is really fantastic by the way!), so if this isn't something that would be a simple fix feel free to close it :)

from evolve.

lecaillon avatar lecaillon commented on July 28, 2024

These messages are due to the method I use to determine the database you use (SQL Server, SQLite, PostgreSQL ...)

I will try to use an another strategy in a future version, but honestly, because the migrations work fine
it is not in my top priority list.

And yes, afterwards it's seems a bit awkward to guess what database you use that way. 😔

There had to be a reason.... I hope.

from evolve.

Andrewwelton avatar Andrewwelton commented on July 28, 2024

Totally fair! Thank you for the quick responses :)

from evolve.

lecaillon avatar lecaillon commented on July 28, 2024

@Andrewwelton I finally remember why I use this method to detect what type of DBMS is used. That's because Evolve can run in "App-Mode" (you instanciate the class Evolve in your code) and this way can be started with a DbConnection object in the constructor, without any driver specified.

I don't know any other method to determine wich kind of database is used with only a IDbConnection

Are you ? 😉

from evolve.

Andrewwelton avatar Andrewwelton commented on July 28, 2024

Yeah that totally makes sense, I'm using the "App-Mode" myself :)

My thought was that if I instantiate the Evolve object in app like this:
var evolve = new Evolve.Evolve(connection, Console.WriteLine) { Driver = "sqlite" };

I've provided what type of connection the IDbConnection is when I instantiated the Evolve object, so doing the extra work to try and figure it out seemed unnecessary.

from evolve.

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.