Creating a Custom Profile Provider
The Profile
object uses the Provider Model. The ASP.NET Framework includes a single profile provider, the SqlProfileProvider
, that stores profile data in a Microsoft SQL Server database. In this section, you learn how to build a custom profile provider.
One problem with the default SqlProfileProvider
is that it serializes an entire profile into a single blob and stores the blob in a database table column. This means that you can’t execute SQL queries against the properties in a profile. In other words, the default SqlProfileProvider
makes it extremely difficult to generate reports off the properties stored in a profile.
In this section, we create a new profile provider that is modestly named the BetterProfileProvider ...
Get ASP.NET 4 Unleashed now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.