This thread looks to be a little on the old side and therefore may no longer be relevant. Please see if there is a newer thread on the subject and ensure you're using the most recent build of any software if your question regards a particular product.
This thread has been locked and is no longer accepting new posts, if you have a question regarding this topic please email us at support@mindscape.co.nz
|
Is it possible to support the table-valued parameters feature of SQL Server 2008? I have a stored procedure that returns entities but takes a table of parameters rather than scalar values. If this isn't possible, how can I execute my query using ADO.NET then create instances of my entity class from the data?
Kris
|
|
|
We don't currently support table-valued parameters on stored procedures because we don't provide a way for you to pass database-specific parameter types like SqlDbType.Structured. We'll take a look at improving this. In the meantime, the latest builds of LightSpeed have a new IUnitOfWork.FindBySql method which takes an IDbCommand and materialises the results into entities. See http://www.mindscape.co.nz/forums/Post.aspx?ThreadID=2369&PostID=6843 for how to use this. This should enable you to use TVPs albeit in a rather manual way! We have however not tested this with TVPs so please let us know if it doesn't work. (Please note: if upgrading from 2.2 RTM to the nightly build, please observe the warning about uninstalling RTM first, otherwise you may receive errors after the upgrade.) |
|