How do I create efficient SQL select statements for any arbitrary model using Dapper in C#? -


i learned using select * inefficient , should not used in production code, i'm trying figure best way go creating sql select statements models. in case, there huge product entity in our database separated different tables, isn't, , i'm creating class represent table. have select table has ton of unnecessary columns don't need pull from, how dynamically create select statement selects columns need class?

would idea create static method converts class's properties comma-separated list mapped class when query using dapper?

maybe like:

public static string getcolumnsasstring(type class); 


Comments

Popular posts from this blog

Magento/PHP - Get phones on all members in a customer group -

php - .htaccess mod_rewrite for dynamic url which has domain names -

Website Login Issue developed in magento -