title: Quartz, setting up postgres schema, what should JOB_DATA be?
body: <p>I'm using liquibase to setup the database tables for quartz as per <a href="https://raw.githubusercontent.com/Bert-R/quartz-repro/master/src/main/resources/db/changelog/db.changelog-master.yaml" rel="nofollow noreferrer">Bert R recipe</a>. </p>
  
  <p>What is the correct type for the JOB_DATA columns for postgres?</p>
  
  <p>The raw error is</p>
  
  <pre><code>Caused by: org.quartz.JobPersistenceException: Couldn't retrieve trigger: 2
  at org.quartz.impl.jdbcjobstore.JobStoreSupport.retrieveTrigger(JobStoreSupport.java:1538)
  Caused by: java.lang.ArrayIndexOutOfBoundsException: 2
  at org.postgresql.util.PGbytea.toBytes(PGbytea.java:76)
  </code></pre>
  
  <p>The base error is in PostgreSQlDelegate.java trying to read the JOB_DATA column from the qrtz_triggers table. This column does have just \x in it. </p>
  
  <p>I have changed the above liquibase file to change the type from BLOB to BYTEA as I was getting an error </p>
  
  <pre><code>column "job_data" is of type oid but expression is of type bytea
  </code></pre>
  
  <p>The quartz properties file includes the following settings for the Job Store</p>
  
  <pre><code># Job Store
  org.quartz.jobStore.class=org.quartz.impl.jdbcjobstore.JobStoreTX
  org.quartz.jobStore.driverDelegateClass = 
  org.quartz.impl.jdbcjobstore.PostgreSQLDelegate
  </code></pre>