Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Using CursorAdapter with CRUD Store Procedures
Message
From
18/10/2004 17:53:49
 
 
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00952188
Message ID:
00952463
Views:
10
Hi Martin,

I've built a rather simple builder to create cursoradapters that mirror SQL tables where stored procedures exist. I haven't tested it in all scenarios, it's got a crude UI and it's put together rather "at-the-momentish" but I'd be willing to send it to you so you can review and/or modify to fit your needs. I just put something together to satisfy my immediate needs and haven't had time to get it all pretty yet. Let me know if you are interested.

Aloha,

James
>Hi, all.
>
>I was doing some training last week at a customer. They are using SQL Server 2000 and they has a corporate policy to do all DB access trough Store Procedures. I helped them in the past to build a data access component when they where using VFP 7, and we sat for a round of test-driven development to refactor it using CursorAdapter. It was more an exercise than something very critical, but anyway...
>
>I couldn't find a good way to make the CursorAdapter use the Select/Insert/Update/Delete SPs.
>
>We try to fiddle with the *Cmd methods, but to no avail. The problem I couldn't figure out was how to pass parameters to the SP. I tried adding them to the SP command string in the Before* (BeforeInsert, for example), but my changes are not applied. I managed to force the parameters before calling TableUpdate, but this only works in single-record cases.
>
>Any hint or example? I guess it should be some easy way I'm totally overlooking.
>
>Thanks in advance,
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform