Hi Jeremy, thanks for taking this the next step! I'll keep an eye on the
change logs to help test once things are ready. Thanks again for your help
with everything.
On Mon, Dec 1, 2008 at 9:06 PM, Jeremy Evans <[EMAIL PROTECTED]> wrote:
>
> On Nov 28, 8:56 am, devdiscuss <[EMAIL PROTECTED]> wrote:
> > Hi, I've submitted a patch adding basic JDBC stored procedure support
> > to the Sequel Database object. The next step would be to add this
> > functionality to the Dataset as well. Since this is my first patch
> > and I'm still getting familiar with the code (thank you Jeremy for
> > your assistance with it all), I figured I'd start small. I've tested
> > this successfully using JRuby and the SQLServer JDBC driver.
> >
> > Usage is:
> >
> > DB.execute_sproc("{call mysp(?,?)}", :args => ['first param', 'second
> > param'])
>
> I'm using your patch as a base for stored procedure support, I should
> have a patch ready for testing tomorrow. The API is changing, it will
> be:
>
> DB.call_sproc(:mysp, :args=>['first param', 'second param'])
>
> Not that I recommend using the Database object directly, since the
> results are adapter dependent. There will be full support for use
> from datasets similar to the prepared statement support. The API will
> be:
>
> DB[:table].call_sproc(:select, :mysp, 'first param', 'second param')
> # or
> sp = DB[:table].prepare_sproc(:select, :mysp)
> sp.call('first param', 'second param')
> sp.call('third param', 'fourth param')
>
> There will be stored procedure support in both the JDBC and MySQL
> adapters. Support for other adapters may be added later.
>
> Jeremy
> >
>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"sequel-talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/sequel-talk?hl=en
-~----------~----~----~----~------~----~------~--~---