Scala & Slick stored procedure examples

2,799 views
Skip to first unread message

Robin Holtmann

unread,
Mar 7, 2013, 7:14:48 AM3/7/13
to scala...@googlegroups.com
Hi all,

I am thinking about using Slick with Playframework 2.0.
Are there Slick examples with stored procedures?
Especially stored procedures with multiple result sets and how to write those results in lists of tuples.

Thanks in advance
Robin

Christopher Vogt

unread,
Mar 14, 2013, 1:21:03 PM3/14/13
to scala...@googlegroups.com

Egon Nijns

unread,
Apr 24, 2013, 4:34:50 AM4/24/13
to scala...@googlegroups.com
Hi Christopher,

can you please elaborate on your answer?

I can't see how these links relate to the use of stored procedures for querying.

kind regards,
Egon.

Christopher Vogt

unread,
May 2, 2013, 3:28:03 AM5/2/13
to scala...@googlegroups.com
I just noticed I missed the "multiple result sets" in the original question. Multiple result sets are currently not supported. For a single result set you can use Slick plain sql queries, optionally using the interpolation syntax like this:

sql"{call myproc($a, $b)}".as[(String, Int, Int)]

For type-safe embedding of scalar functions please refer to the documentation linked before and search for SimpleFunction.

Chris
Reply all
Reply to author
Forward
0 new messages