Slick Plain SQL arbitrary parameters

71 views
Skip to first unread message

Dan Di Spaltro

unread,
Apr 8, 2014, 3:37:16 AM4/8/14
to scala...@googlegroups.com
I am using a non-supported database with Slick Plain SQL and it works pretty well.  Basically I just want some syntatic sugar and Slick gives me that.  So I am currently working on generating dynamic SQL, but I can't really figure out a good to pass in arbitrary values on an insert statement as an example.  In JDBC world it's easy, I was wondering what the preferred way to do that in slick is.  

Christopher Vogt

unread,
Apr 8, 2014, 10:12:08 AM4/8/14
to scala...@googlegroups.com


> So I am currently working on generating dynamic SQL, but I
> can't really figure out a good to pass in arbitrary values on an insert
> statement as an example.

What is dynamic? The types of the values as well as the number of values?

Chris

Dan Di Spaltro

unread,
Apr 8, 2014, 1:03:47 PM4/8/14
to scala...@googlegroups.com
Yes exactly.



--

---
You received this message because you are subscribed to a topic in the Google Groups "Slick / ScalaQuery" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/scalaquery/zdFlFJYzi9o/unsubscribe.
To unsubscribe from this group and all its topics, send an email to scalaquery+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/scalaquery/534403B8.6010808%40gmail.com.
For more options, visit https://groups.google.com/d/optout.



--
Dan Di Spaltro

Christopher Vogt

unread,
Apr 8, 2014, 2:57:37 PM4/8/14
to scala...@googlegroups.com
The you need to generate all of it into the SQL string or use jdbc.
Dynamic queries is not Slick's strength at the moment.

Chris

Dan Di Spaltro

unread,
Apr 9, 2014, 2:38:00 AM4/9/14
to scala...@googlegroups.com
Great, thanks for the help.  I went to JDBC for the specific need.



Chris

--

---
You received this message because you are subscribed to a topic in the Google Groups "Slick / ScalaQuery" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/scalaquery/zdFlFJYzi9o/unsubscribe.
To unsubscribe from this group and all its topics, send an email to scalaquery+...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.



--
Dan Di Spaltro

Christopher Vogt

unread,
Apr 9, 2014, 8:15:05 AM4/9/14
to scala...@googlegroups.com
By the way, here is some yet unreleased documentation on Slick-JDBC interop.

https://github.com/slick/slick/pull/691

Dan Di Spaltro

unread,
Apr 9, 2014, 3:22:28 PM4/9/14
to scala...@googlegroups.com
Great thanks looks like all the code is in 2.0.1.  I appreciate the help!


On Wed, Apr 9, 2014 at 5:15 AM, Christopher Vogt <jan.christ...@gmail.com> wrote:
By the way, here is some yet unreleased documentation on Slick-JDBC interop.

https://github.com/slick/slick/pull/691
--

---
You received this message because you are subscribed to a topic in the Google Groups "Slick / ScalaQuery" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/scalaquery/zdFlFJYzi9o/unsubscribe.
To unsubscribe from this group and all its topics, send an email to scalaquery+...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.



--
Dan Di Spaltro
Reply all
Reply to author
Forward
0 new messages