Yes, there is no harm in querying aspnet_Users
or any other Microsoft Membership database table under normal circumstances.
But if you are dealing with fairly large number of records, it will effect the query performance. The reason behind it is that, INDEXING applied on Microsoft Membership tables is not very ideal. Most of the tables have ApplicationId
as clustered index, which no one uses even rarely.
UserId
is indexed, and LoweredUserName
field is indexed in aspnet_membership
and aspnet_users
tables. So use them in your where clauses to boost up performance for large databases.
I hope this answers your question, if yes then mark it as "answered".