On Thursday, July 25, 2013 6:07:38 AM UTC-7, Heberto del Rio wrote:

> The point for me is, even in case it is decided not to implement this 
> option in SQLite, how to have access to the SQLite::Database connection 
> created when the user call Sequel.connect('sqlite://...') or Sequel.sqlite, 
> so it is up to the user to call the create_function. The only way I have 
> found (but that is due to my lack of knowledge on Sequel, I'm a newbie) is 
> to do the following: DB.pool.first.create_function(...., but it is not 
> clean, in my opinion. Is there any option on the framework to have access 
> to the actual connection (after initialization) in order to do things like 
> these?


Use the :after_connect Database option.  It accepts a callable value that 
is called with each underlying connection created by the connection pool.

Thanks,
Jeremy

-- 
You received this message because you are subscribed to the Google Groups 
"sequel-talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sequel-talk.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to