Hi everyone, I did some source diving and found out how to use call_sproc within the unit tests. This really aught to be documented somewhere. and, to be 100% frank, I'd much rather see something like db.select_sproc( :proc, *args ) than db.call_sproc( :select, :proc, *args ) if they really need to be called differently.
Clive 2009/2/13 Clive Crous <[email protected]>: > Hi, > > I'm trying (unsuccessfully) to use some mysql stored procedures and > could really use some help understanding how to call them from Sequel. > > Whenever I do > > db.execute( "CALL foo( 123 )" ) > > it returns a nil and then any subsequent usage of db raises > "Mysql::Error Commands out of sync; you can't run this command now". > > And if I try to use it as follows: > > db.call_sproc( :foo, :args => 123 ) > > it fails with "undefined method `empty?' for 123:Fixnum" > > yet if I make it a string it automatically quotes it, which is incorrect. > > I'm using Sequel directly from the github repository ( last change add > fixture dependencies extention to plugin page @ 2009-02-09 23:06:05 => > 13ab5e4af8a3af638fcdbcbe6f1c9c22b5e38397 ) > > Thanks, > Clive > --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
