Simple statements like this: "Select x,y,z From Customer" are in the Data Access Layer.
If there would be logic in the query like filtering for customers from a certain city I would have to put the filtering in my business layer and do it on the in-memory customer collection.
When I regard now the Micro ORM tools they often show Sql statements with logic like:
var a = db.SingleOrDefault<Product>("SELECT * FROM SalesLT.Product WHERE ProductID = @0, 123);
Where should I put now this line of code? In the Business Layer or the Data Access Layer?
There is logic inside the statement which should belong in Business Layer. But then I have
Select statements inside my BLL ??
This is all confusing.
If you want a 3 layer model, then use of either the db context or the micro orm need to be done on the data access layer.