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
|
Just checking to see if I am missing something, and if not, try to get better support for stored procedures in LightSpeed. There are times when I just want to return non-entities from a stored procedure and do not want to return a column of Id. Today it was a list of strings from a table that required use of the Distinct keyword. To the best of my knowledge the designer cannot handle this and I needed to fumble around with projections. Lucky projections did the trick, but I really don't want to have to write code for something that should easily be accomplished by dropping a stored procedure on the designer. Any chance you guys are working on better support for stored procedures with the designer for 3.0 so we don't have to think so much about what is being returned and shaping it to meet the needs of LightSpeed? Thanks, Dave
|
|
|
Hello David, We're not really sure what value you see LightSpeed adding in this scenario. The decoupling from the database engine is of limited value when using sprocs, so the only thing we really see here is having the designer generate the wrapper method rather than calling the sproc directly. We're not sure how useful it is to try to model a sproc that returns a list of strings in LightSpeed, because LightSpeed is really about handling an entity-based domain model rather than handling arbitrary data that happens to come from a database. Could you say a bit more about how you would like LightSpeed to help you in this kind of scenario? Thanks! By the way, one thing LightSpeed does provide that may help with calling sprocs, although it is quite low-level, is the LightSpeedContext.DataProviderObjectFactory property. The help file inexplicably omits documentation for IDataProviderObjectFactory, but it has methods such as CreateConnection and CreateCommand which you can use to create low-level ADO.NET objects without having to repeat the configuration that you've already provided for LightSpeed. |
|