Skip to content

DISCARD isn't valid in Redshift, so connection#reset! throws #25

Description

@smcgivern

https://github.com/aamine/activerecord4-redshift-adapter/blob/master/lib/active_record/connection_adapters/redshift_adapter.rb#L247 runs DISCARD ALL, but that's not valid in Redshift, so it throws an exception instead:

# DISCARD ALL;
ERROR:  syntax error at or near "DISCARD"
LINE 1: DISCARD ALL;
        ^

This should probably be replaced with something like pg_terminate_backend, but that might not behave exactly the same way.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions