Searching for Profile Properties

rated by 0 users
This post has 10 Replies | 2 Followers

Not Ranked
Posts 18
Points 235
Frescard Posted: Tue, Dec 13 2005 4:06 PM
I understand that the user profile data is stored as a continuous string in the PropertyValuesString field in aspnet_Profile with floating positions for each particular property.

So, how would I have to formulate my SQL-Query in order to extract users that match specific profile properties (let's say I want to find all members that are male, or all that have language set to 'spanish', etc.)?

  • | Post Points: 20
Top 10 Contributor
Posts 2,527
Points 28,845
MVPs
Partners
Unfortunately, you have just stumbled across one of the larger disadvantages of the serialized Profile implementation. Due to the way profile data is stored, while there are SQL functions available which can pull out specific data, the performance of any search based on these techniques would be pretty pitiful.

The only real way to build a solid search is to write your own custom ProfileProvider, where you could then use a more conventional schema to implement more advanced profile searching.

Four Roads

  • | Post Points: 35
Top 10 Contributor
Male
Posts 2,373
Points 15,755
MVPs
Top 10 Contributor
Posts 2,527
Points 28,845
MVPs
Partners
Yep, that's the function I was referring to - just don't think I'd want to base a commercial-grade search solution around that method.

Four Roads

  • | Post Points: 5
Top 100 Contributor
Posts 207
Points 1,080
spdl replied on Wed, Dec 14 2005 2:16 PM

Are you planning to write a cs ProfileProvider for this task in the future?

Member handling is quite important for community sites....

ralph

spdl
  • | Post Points: 20
Top 10 Contributor
Posts 2,527
Points 28,845
MVPs
Partners
It's looking likely that I may have to do just that for an external CS project that I'm currently speccing. We'll have to invesigate the exact performance and maintenance constraints of developing a solution to work with the existing provider before a final decision is made, though.

Four Roads

  • | Post Points: 65
Top 10 Contributor
Male
Posts 2,373
Points 15,755
MVPs
Dave replied on Thu, Dec 15 2005 3:50 AM
There's this one which stores each profile property in it's own row, I haven't downloaded the samples yet (in work restrictions!) but the code on the page is incomplete so can't say if it works or not.
  • | Post Points: 5
Not Ranked
Posts 18
Points 235
Frescard replied on Wed, Jan 11 2006 1:23 PM
Genyus wrote:
It's looking likely that I may have to do just that for an external CS project that I'm currently speccing. We'll have to invesigate the exact performance and maintenance constraints of developing a solution to work with the existing provider before a final decision is made, though.


Any news on that external project yet?
Will there be a chance that the solution (or at least the concept) developed for it might be shared here?

  • | Post Points: 5
Top 100 Contributor
Posts 207
Points 1,080
spdl replied on Tue, Apr 18 2006 9:22 AM
HI

Just checking.... 4 month later.... are there any news on extended profiles that can be queried via SQL?

Thanks
ralph
spdl
  • | Post Points: 5
Not Ranked
Posts 31
Points 425
paully_21 replied on Wed, Jan 16 2008 6:09 PM

I too would love to to be able to search on these properties, but I am running into all sorts of problems. 
Please keep us posted on your project.

  • | Post Points: 20
Top 10 Contributor
Posts 2,527
Points 28,845
MVPs
Partners
Just to say, we never went down the custom profile provider in the end. I don't know if anyone else out there has done this yet.

Four Roads

  • | Post Points: 5
Page 1 of 1 (11 items) | RSS
Powered by Community Server (Commercial Edition), by Telligent Systems

Copyright© 2008 Telligent Systems Inc. All rights reserved
CommunityServer.com  •  Telligent.com