{"action":"created","issue":{"url":"https://api.github.com/repos/layerware/hugsql/issues/7","labels_url":"https://api.github.com/repos/layerware/hugsql/issues/7/labels{/name}","comments_url":"https://api.github.com/repos/layerware/hugsql/issues/7/comments","events_url":"https://api.github.com/repos/layerware/hugsql/issues/7/events","html_url":"https://github.com/layerware/hugsql/issues/7","id":115657683,"number":7,"title":"Cryptic no hstore extension installed exception","user":{"login":"Skinney","id":854889,"avatar_url":"https://avatars.githubusercontent.com/u/854889?v=3","gravatar_id":"","url":"https://api.github.com/users/Skinney","html_url":"https://github.com/Skinney","followers_url":"https://api.github.com/users/Skinney/followers","following_url":"https://api.github.com/users/Skinney/following{/other_user}","gists_url":"https://api.github.com/users/Skinney/gists{/gist_id}","starred_url":"https://api.github.com/users/Skinney/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Skinney/subscriptions","organizations_url":"https://api.github.com/users/Skinney/orgs","repos_url":"https://api.github.com/users/Skinney/repos","events_url":"https://api.github.com/users/Skinney/events{/privacy}","received_events_url":"https://api.github.com/users/Skinney/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-11-07T10:26:52Z","updated_at":"2015-11-07T15:17:16Z","closed_at":null,"body":"I'm converting all my yesql code to hugsql, and I've run into this very strange bug. Need some helping in understanding why this happens.\r\n\r\nI'm trying to run the following sql:\r\n\r\n```\r\n--:name create! :!\r\nINSERT INTO shows (tvdb_id, name, description, banner, poster, network, next_update)\r\nVALUES (:v:tvdb_id, :v:name, :v:description, :v:banner, :v:poster, :v:network, :v:next_update);\r\n```\r\n\r\ntvdb_id is an int, next_update is a joda-time instance. The other values are strings.\r\n\r\nPostgres displays the following::\r\n\r\n```\r\nLOG:  execute <unnamed>: SHOW TRANSACTION ISOLATION LEVEL\r\nLOG:  execute <unnamed>: BEGIN\r\nLOG:  execute <unnamed>: INSERT INTO shows (tvdb_id, name, description, banner, poster, network, next_update)\r\n\tVALUES ($1, $2, $3, $4, $5, $6, $7)\r\nDETAIL:  parameters: $1 = '278518', $2 = 'Last Week Tonight with John Oliver', $3 = 'Last Week Tonight with John Oliver is an American late-night talk and news satire television program.\r\n\tL.W.T draws its comedy and satire from recent news stories, political figures, media organizations, pop culture and often aspects of the show itself.', $4 = 'graphical/278518-g3.jpg', $5 = 'posters/278518-2.jpg', $6 = 'HBO', $7 = '2015-11-09 01:00:00+01'\r\nLOG:  execute <unnamed>: SELECT pg_type.oid   FROM pg_catalog.pg_type   LEFT   JOIN (select ns.oid as nspoid, ns.nspname, r.r           from pg_namespace as ns           join ( select s.r, (current_schemas(false))[s.r] as nspname                    from generate_series(1, array_upper(current_schemas(false), 1)) as s(r) ) as r          using ( nspname )        ) as sp     ON sp.nspoid = typnamespace  WHERE typname = $1  ORDER BY sp.r, pg_type.oid DESC LIMIT 1\r\nDETAIL:  parameters: $1 = 'hstore'\r\nLOG:  execute S_3: ROLLBACK\r\n```\r\n\r\nAnd this is my stacktrace:\r\n\r\n```\r\nERROR] org.postgresql.util.PSQLException: No hstore extension installed.\r\norg.postgresql.util.PSQLException: No hstore extension installed.\r\n\tat org.postgresql.jdbc2.AbstractJdbc2Statement.setMap(AbstractJdbc2Statement.java:1746)\r\n\tat org.postgresql.jdbc2.AbstractJdbc2Statement.setObject(AbstractJdbc2Statement.java:2138)\r\n\tat org.postgresql.jdbc3g.AbstractJdbc3gStatement.setObject(AbstractJdbc3gStatement.java:38)\r\n\tat org.postgresql.jdbc4.AbstractJdbc4Statement.setObject(AbstractJdbc4Statement.java:48)\r\n\tat com.zaxxer.hikari.proxy.HikariPreparedStatementProxy.setObject(HikariPreparedStatementProxy.java)\r\n\tat clojure.java.jdbc$eval1178$fn__1179.invokePrim(jdbc.clj:341)\r\n\tat clojure.java.jdbc$eval1178$fn__1179.invoke(jdbc.clj)\r\n\tat clojure.java.jdbc$eval1157$fn__1158$G__1148__1167.invoke(jdbc.clj:328)\r\n\tat clojure.java.jdbc$set_parameters$fn__1254.invoke(jdbc.clj:478)\r\n\tat clojure.core$map_indexed$mapi__6824$fn__6825.invoke(core.clj:7015)\r\n\tat clojure.lang.LazySeq.sval(LazySeq.java:40)\r\n\tat clojure.lang.LazySeq.seq(LazySeq.java:49)\r\n\tat clojure.lang.RT.seq(RT.java:507)\r\n\tat clojure.core$seq__4128.invoke(core.clj:137)\r\n\tat clojure.core$dorun.invoke(core.clj:3009)\r\n\tat clojure.java.jdbc$set_parameters.invoke(jdbc.clj:477)\r\n\tat clojure.java.jdbc$db_query_with_resultset$run_query_with_params__1341.invoke(jdbc.clj:823)\r\n\tat clojure.java.jdbc$db_query_with_resultset.invoke(jdbc.clj:831)\r\n\tat clojure.java.jdbc$query.doInvoke(jdbc.clj:866)\r\n\tat clojure.lang.RestFn.invoke(RestFn.java:425)\r\n\tat hugsql.adapter.clojure_java_jdbc.HugsqlAdapterClojureJavaJdbc.query(clojure_java_jdbc.clj:15)\r\n\tat episode_next.db.show$id_for_tvdb_id.invoke(show.clj:5)\r\n\tat episode_next.db.show$id_for_tvdb_id.invoke(show.clj:5)\r\n\tat episode_next.routes.show$upsert_show_BANG_$fn__59504.invoke(show.clj:20)\r\n\tat clojure.java.jdbc$db_transaction_STAR_.doInvoke(jdbc.clj:595)\r\n\tat clojure.lang.RestFn.invoke(RestFn.java:521)\r\n\tat clojure.java.jdbc$db_transaction_STAR_.doInvoke(jdbc.clj:611)\r\n\tat clojure.lang.RestFn.invoke(RestFn.java:425)\r\n\tat episode_next.routes.show$upsert_show_BANG_.invoke(show.clj:18)\r\n\tat episode_next.routes.show$connect_show__GT_device_BANG_$fn__59513.invoke(show.clj:39)[INFO] /show/follow 500 194ms {:device-id #uuid \"4443b630-8534-11e5-898f-0e2267e517ab\", :tvdb-id 278518}\r\n\r\n\tat episode_next.routes.show$connect_show__GT_device_BANG_.invoke(show.clj:38)\r\n\tat episode_next.routes.show$eval59517$fn__59518.invoke(show.clj:53)\r\n\tat clojure.lang.MultiFn.invoke(MultiFn.java:229)\r\n\tat episode_next.http$router.invoke(http.clj:32)\r\n\tat episode_next.http$wrap_components$fn__60290.invoke(http.clj:27)\r\n\tat episode_next.http$wrap_error_page$fn__60287.invoke(http.clj:20)\r\n\tat episode_next.transit$wrap_transit_response$fn__60226.invoke(transit.clj:44)\r\n\tat episode_next.transit$wrap_transit_body$fn__60223.invoke(transit.clj:38)\r\n\tat episode_next.log$wrap_with_logger$fn__59304.invoke(log.clj:29)\r\n\tat aleph.http.server$wrap_stream__GT_input_stream$fn__21998.invoke(server.clj:403)\r\n\tat aleph.http.server$handle_request$fn__21916$f__17232__auto____21917.invoke(server.clj:153)\r\n\tat clojure.lang.AFn.run(AFn.java:22)\r\n\tat java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)\r\n\tat java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)\r\n\tat java.lang.Thread.run(Thread.java:745)\r\n```\r\n\r\nAny idea why this is happening?"},"comment":{"url":"https://api.github.com/repos/layerware/hugsql/issues/comments/154713913","html_url":"https://github.com/layerware/hugsql/issues/7#issuecomment-154713913","issue_url":"https://api.github.com/repos/layerware/hugsql/issues/7","id":154713913,"user":{"login":"csummers","id":46089,"avatar_url":"https://avatars.githubusercontent.com/u/46089?v=3","gravatar_id":"","url":"https://api.github.com/users/csummers","html_url":"https://github.com/csummers","followers_url":"https://api.github.com/users/csummers/followers","following_url":"https://api.github.com/users/csummers/following{/other_user}","gists_url":"https://api.github.com/users/csummers/gists{/gist_id}","starred_url":"https://api.github.com/users/csummers/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/csummers/subscriptions","organizations_url":"https://api.github.com/users/csummers/orgs","repos_url":"https://api.github.com/users/csummers/repos","events_url":"https://api.github.com/users/csummers/events{/privacy}","received_events_url":"https://api.github.com/users/csummers/received_events","type":"User","site_admin":false},"created_at":"2015-11-07T15:17:16Z","updated_at":"2015-11-07T15:17:16Z","body":"That is strange.  Can you show the output of the -sqlvec version of the function with the data you are passing in?"}}