开发者

I need to pass stored procedure name dynamically to Linq-to-SQL, vb.net

开发者 https://www.devze.com 2023-03-19 11:47 出处:网络
How can I pass stored procedure name dynamically to Linq-to-SQL, vb.net and get the result into a datatabl开发者_JS百科e.

How can I pass stored procedure name dynamically to Linq-to-SQL, vb.net and get the result into a datatabl开发者_JS百科e.

Thanks in advance.


LINQ to SQL is all about compile-time type-safety and avoiding DataTables.

You should use classic ADO.Net, using a SqlDataAdapter.


you can either use ExecuteQuery<T>(string Your Query).First build your string and then execute it and return T result and then iterate it to DataTable.

0

精彩评论

暂无评论...
验证码 换一张
取 消