开发者

quote table names in squeryl

I have a table named group in a mysql db. When I map this table to squeryl I get SQL synt开发者_JAVA百科ax errors since the table name group is not quoted (should be select * from `group`).

Is there any way I can tell squeryl to quote certain table names?


GROUP is a reserved word in SQL, so I'd recommend renaming your table to something else. (I'm guessing this is the cause of this issue.)


Have you tried :

val groups = table[Group]("`group`")

?

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜