Reputation: 5123
How to use federation in SQL Azure connection using NHibernate ?
For example I want a federation to split data using CustomerID, and i want to direct all session calls to be directed to a specific federation based on a configurable CustomerID.
Upvotes: 6
Views: 653
Reputation: 624
Created a blog post which explains in detail how to query federations using NHibernate: Accessing SQL Azure Federations using NHibernate
Upvotes: 3
Reputation:
so if you know the customer ID, you just need to connect to other federation with command:
use federation CustomerFederation (CustomerID=2) with reset, filtering=on
where CustomerFederation,customerId is federation name and federation key of yours. basically, just execute the sql before any other operation you want to do on the other federation.
sorry for my english
Upvotes: 0