kyleu / boilerplay

Using the latest technology in the Scala ecosystem, Boilerplay is a reactive web application built on Play Framework, ScalaJS, Silhouette, Sangria/GraphQL, and PostgreSQL. It provides a good starting point for whatever you want to build.

Home Page:https://kyleu.github.io/boilerplay

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Postgres DDL syntax error

nkconnor opened this issue · comments

Using Postgres 9.4, I get an error with the if not exists part of index creation

boilerplay=# create index if not exists "audit_act" on "audit" using btree ("act" asc nulls last);
ERROR:  syntax error at or near "not"
LINE 1: create index if not exists "audit_act" on "audit" using btre...
                        ^

Yep, looks like "create index if not exists" is Postgres 9.5+

https://dba.stackexchange.com/questions/35616/create-index-if-it-does-not-exist

I'll update the doc, thanks for the report.