Reputation: 4341
1) Why SchemaMetadataUpdater.QuoteTableAndColumns
doesn't update (scape) schema names? how I can update schemas? I have a problem with preserved schema's as keyword is MsSql like 'Statistics'
. However this can be fixed by using '[Statistics]'
.
2) How to override default schemas for ManyToMany relationship based on an specific condition; not global default schema?
UPDATE
2.1) When you define a ManyToMany relationship between User and Role, UserRole table is automatically generated by NHibernate for handling this relation staffs. Now we can easily change schema for Role and User tables, but we haven't access to UserRole and as a result we can't specify schema for that. My questoin is How to change schema for this type of tables?
Thank's
Upvotes: 0
Views: 206
Reputation: 7941
In the base XML mapping for nhibernate you would escape the table/column names with
`(grave accent - the other character on the tilda key (~) below the esc key) this is the native escape >character for nhibernate and translates it to the correct escape character for the database dialect you are using. so nhibernate will traslate
`Statistics`` to [Statistics] for MSSql
2) can you please expand. as it is not very clear what you are tying to do.
sorry for the formatting. markdown is playing havoc with the grave accent key.
Upvotes: 1