# Create Table issue when connecting to Redshift

**URL:** <https://forum.inductiveautomation.com/t/create-table-issue-when-connecting-to-redshift/69598>\
**Category:** Ignition\
**Tags:** perspective\
**Created:** [February 8, 2023, 7:34pm UTC](https://forum.inductiveautomation.com/t/create-table-issue-when-connecting-to-redshift/69598 "2023-02-08T19:34:52Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![MSI\_EXP\_Auto](https://avatars.discourse-cdn.com/v4/letter/m/fbc32d/32.png) [@MSI\_EXP\_Auto](https://forum.inductiveautomation.com/u/MSI_EXP_Auto)\
**Post date:** [February 8, 2023, 7:34pm UTC](https://forum.inductiveautomation.com/t/create-table-issue-when-connecting-to-redshift/69598/1 "2023-02-08T19:34:52Z")

</div>

Trying to create a transaction group, OPC -\> DB. The database is AWS Redshift which is based on Postgres but has some key differences, one of which I found when trying to auto create a table for my transaction group.

Here is part of the error - java.lang.Exception: Error running query: CREATE TABLE ignition.downtime\_test ("downtime\_test\_ndx" SERIAL NOT NULL,"Downtime\_Test\_Tag"

Caused by: com.amazon.redshift.util.RedshiftException: ERROR: Column "downtime\_test.downtime\_test\_ndx" has unsupported type "serial".

Any work around for this, I would like to be able to create tables automatically? My default translator is set to postgres, does anyone have parameters for a Redshift translator they would be willing to share?

---

<div class="post-metadata">

**Author:** ![dkhayes117](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/dkhayes117/32/68344_2.png) [@dkhayes117](https://forum.inductiveautomation.com/u/dkhayes117)\
**Post date:** [February 8, 2023, 7:38pm UTC](https://forum.inductiveautomation.com/t/create-table-issue-when-connecting-to-redshift/69598/2 "2023-02-08T19:38:19Z")

</div>

I've not done this myself, but you could start with trying to use the redshift JDBC driver  
[Download the Amazon Redshift JDBC driver, version 2.1 - Amazon Redshift](https://docs.aws.amazon.com/redshift/latest/mgmt/jdbc20-download-driver.html)

---

<div class="post-metadata">

**Author:** ![MSI\_EXP\_Auto](https://avatars.discourse-cdn.com/v4/letter/m/fbc32d/32.png) [@MSI\_EXP\_Auto](https://forum.inductiveautomation.com/u/MSI_EXP_Auto)\
**Post date:** [February 8, 2023, 7:45pm UTC](https://forum.inductiveautomation.com/t/create-table-issue-when-connecting-to-redshift/69598/3 "2023-02-08T19:45:43Z")

</div>

I'm already using this, had to create the driver in ignition to set up the connection. Connection is working fine, Redshift just does not support the create table syntax used by the auto generate table option from a transaction group.

---

<div class="post-metadata">

**Author:** ![dkhayes117](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/dkhayes117/32/68344_2.png) [@dkhayes117](https://forum.inductiveautomation.com/u/dkhayes117)\
**Post date:** [February 8, 2023, 7:51pm UTC](https://forum.inductiveautomation.com/t/create-table-issue-when-connecting-to-redshift/69598/4 "2023-02-08T19:51:55Z")

</div>

> [@MSI\_EXP\_Auto](#):
>
> My default translator is set to postgres

You probably just need to create a new db translator for it.  
[JDBC Drivers and Translators - Ignition User Manual 8.1 - Ignition Documentation (inductiveautomation.com)](https://docs.inductiveautomation.com/display/DOC81/JDBC+Drivers+and+Translators#JDBCDriversandTranslators-AddingaJDBCDriver)

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [February 8, 2023, 8:22pm UTC](https://forum.inductiveautomation.com/t/create-table-issue-when-connecting-to-redshift/69598/5 "2023-02-08T20:22:19Z")

</div>

> [@MSI\_EXP\_Auto](#):
>
> has unsupported type "serial".

You are not going to find a work-around. This column type keyword is needed for Ignition to make a primary key.

---

<div class="post-metadata">

**Author:** ![MSI\_EXP\_Auto](https://avatars.discourse-cdn.com/v4/letter/m/fbc32d/32.png) [@MSI\_EXP\_Auto](https://forum.inductiveautomation.com/u/MSI_EXP_Auto)\
**Post date:** [February 8, 2023, 8:24pm UTC](https://forum.inductiveautomation.com/t/create-table-issue-when-connecting-to-redshift/69598/6 "2023-02-08T20:24:10Z")

</div>

That's what its seeming like, was hoping someone might have done it successfully before I get to deep into the weeds

---

<div class="post-metadata">

**Author:** ![JordanCClark](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/jordancclark/32/83362_2.png) [@JordanCClark](https://forum.inductiveautomation.com/u/JordanCClark)\
**Post date:** [February 8, 2023, 8:24pm UTC](https://forum.inductiveautomation.com/t/create-table-issue-when-connecting-to-redshift/69598/7 "2023-02-08T20:24:38Z")

</div>

> [@MSI\_EXP\_Auto](#):
>
> com.amazon.redshift.util.RedshiftException: ERROR: Column "downtime\_test.downtime\_test\_ndx" has unsupported type "serial"

EDIT: Doh! forgot the link...  
[This page](https://docs.aws.amazon.com/redshift/latest/dg/c_unsupported-postgresql-datatypes.html) shows the unsupported datatypes. Try in the translator:

`bigint identity(0, 1)`

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [February 8, 2023, 8:36pm UTC](https://forum.inductiveautomation.com/t/create-table-issue-when-connecting-to-redshift/69598/8 "2023-02-08T20:36:52Z")

</div>

I just reviewed the unsupported **features** list (separate from Jordan's link):

> **[Unsupported PostgreSQL features - Amazon Redshift](https://docs.aws.amazon.com/redshift/latest/dg/c_unsupported-postgresql-features.html)**
>
> Lists the PostgreSQL features that are not supported in Amazon Redshift.

So it doesn't support indexes of any kind, doesn't support any constraints, and doesn't support sequences (the identity generation part of PostgreSQL). I don't see how this can possibly be a good choice for front-end data collection.

---

<div class="post-metadata">

**Author:** ![MSI\_EXP\_Auto](https://avatars.discourse-cdn.com/v4/letter/m/fbc32d/32.png) [@MSI\_EXP\_Auto](https://forum.inductiveautomation.com/u/MSI_EXP_Auto)\
**Post date:** [February 8, 2023, 8:47pm UTC](https://forum.inductiveautomation.com/t/create-table-issue-when-connecting-to-redshift/69598/9 "2023-02-08T20:47:49Z")

</div>

Ya. I have an MSSQL database on site that I can use but some folks wanted live downtime data queryable from redshift since its where all our other production data is housed.
