You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The more I think about it the more it seems to me that SelectAll() was not a good idea at all. I'm thinking of deleting it completely, because you can achieve the same results using Select(). But when using Select(), you have a freedom to specify the custom query you need, like:
var query = CreateSqlQueryBuilder()
.From<User>()
.Select(user => $"DISTINCT TOP 10 {user.Age}")
.ToSqlQuery();
which would result in:
SELECT DISTINCT TOP 10 [User].[Age]
FROM [User]
So, Select() is already as flexible as needed to allow consumers to specify complex custom queries. Introducing SelectAll() was meant to be a convenient shortcut for Select(x => "*") but eventually it ended up being more of a problem.
Hi,
can you please add the possibility of a distinct select?
Regards Mario
The text was updated successfully, but these errors were encountered: