user3213045
user3213045

Reputation: 169

Nhibernate SQL Server 2016 dialect

I'm looking to use NHibernate with SQL Server 2016.

The latest dialect is for SQL Server 2012 and would therefore allow all SQL Server 2012 functionality within SQL Server 2016. I want to know if the new SQL Server 2016 functionality is in any way available via NHibernate.

I'm mainly interested in the following functionality:

Is this functionality available out of the box in the latest (Feb 2017) version of NHibernate and if not are there any ready made extensions that enable the use of this functionality ?

Upvotes: 0

Views: 2424

Answers (2)

Frédéric
Frédéric

Reputation: 9854

These features are highly SQL-Server dependent, and are to be enabled on server side. This a DBA task, not an ORM task (Object Relational Mapping tool - NHibernate is an ORM, Entity Framework too).

If your DBA supports them, just ask him to enable them. There is nothing to be done on NHibernate side.

  • In-Memory Tables:
    You have to flag tables to be handled with in-memory OLTP as memory-optimized when creating them.
    If you use NHibernate hbm2ddl tool to create your tables, you then need to change your process for creating them yourself. hbm2ddl is far too database agnostic for handling those kind of specific options.
  • Transparent Data Encryption:
    This is fully SQL Server concern. That encrypts the database files. This is completely transparent for client software like NHibernate. It has no impact on them. That is a bit nonsense to ask support in clients for a feature which is a server only feature, to which clients are never exposed.
  • Row Level Security:
    Again, fully handled server side. Again, a bit nonsense to ask support in clients for a feature which is a server side feature. Have you documented yourself a bit on those technologies before asking? Read more on Microsoft docs.

    The access restriction logic is located in the database tier rather than away from the data in another application tier.

Defining the filters/access rules in database is your job (or your dba job). This has never been the job of an ORM.

It is wholly up to you (or your dba) to enable them, and they will just work, whatever the application, be it NHibernate or something else.

Upvotes: 2

Ricardo Peres
Ricardo Peres

Reputation: 14525

These features are not available. You will need to create tickets in JIRA (https://nhibernate.jira.com) and maybe discuss them with the developers of NHibernate (https://groups.google.com/forum/#!forum/nhibernate-development).

Upvotes: 0

Related Questions