We're Moving!

The Vertica Forum is moving to a new OpenText Analytics Database (Vertica) Community.

Join us there to post discussion topics, learn about

product releases, share tips, access the blog, and much more.

Create My New Community Account Now


How to rename constraints — Vertica Forum

How to rename constraints

joergschaberjoergschaber Vertica Customer

Hi,
is there a more simple or elegant way to rename table-contraints other than dropping and adding again?

Answers

  • marcothesanemarcothesane - Select Field - Administrator

    if there were any ways to achieve that, @joergschaber, it would be an ALTER CONSTRAINT command. I tried both searching the docu and by firing this command:

    marco ~/1/Vertica/supp $ vsql -c "ALTER CONSTRAINT l_c_pk RENAME TO pk-l_c"
    ERROR 4856:  Syntax error at or near "CONSTRAINT" at character 7
    LINE 1: ALTER CONSTRAINT l_c_pk RENAME TO pk-l_c
    

Leave a Comment

BoldItalicStrikethroughOrdered listUnordered list
Emoji
Image
Align leftAlign centerAlign rightToggle HTML viewToggle full pageToggle lights
Drop image/file