GithubHelp home page GithubHelp logo

Comments (6)

PriyankaChandrabose avatar PriyankaChandrabose commented on June 9, 2024

Any update on this issue. The schema is not getting updated and throws the above exception

from fluent-nhibernate.

PriyankaChandrabose avatar PriyankaChandrabose commented on June 9, 2024

how to connect nhibernate with Microsoft.Data.Sqlite without using extensions and make schema update work

from fluent-nhibernate.

hazzik avatar hazzik commented on June 9, 2024

Thanks. I don't really know what is Hibernate.Extensions.Sqlite.SqliteDialect. I'll take a look at the issue later in the week.

from fluent-nhibernate.

PriyankaChandrabose avatar PriyankaChandrabose commented on June 9, 2024

To use nhibernate with Microsoft.data.sqlite to support creation and updation of tables - what driver and dialect to be used ?
any examples available ?

from fluent-nhibernate.

PriyankaChandrabose avatar PriyankaChandrabose commented on June 9, 2024

Hi,

Found the exact point of the error
GetSchema
MethodCall
GetTables

GetTables method of nhibernate is passing second argument and sqlconnection.cs class of Microsoft.Data.Sqlite is throing exception is 2nd argument is passed. Can some one help me with this

from fluent-nhibernate.

fredericDelaporte avatar fredericDelaporte commented on June 9, 2024

So, it looks like Microsoft.Data.Sqlite simply does not support a feature required by NHibernate for schema-update. The easier way to solve this is to ask for the feature on Microsoft side, if you find where to ask. But it seems they do not intend implementing it due to how they document this lack of support.

DbConnection.GetSchema() isn't implemented. This API isn't well-defined, so we recommend retrieving database metadata directly using standard SQLite APIs like the sqlite_master table and the table_info PRAGMA.

For more information, see Metadata.

On that later link:

Microsoft.Data.Sqlite doesn't implement the GetSchema method on DbConnection. Instead, you can query directly for schema information using the sqlite_master table and PRAGMA statements like table_info and foreign_key_list.

So, your other option is to implement your own SQLiteDataBaseMetaData following the recommendations of the above documentation.

from fluent-nhibernate.

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.