GithubHelp home page GithubHelp logo

Comments (5)

ericfe avatar ericfe commented on July 21, 2024

Have you tried with other values ( like 1024 instead of 8000 ) ?

from amazon-redshift-utils.

mattmc3 avatar mattmc3 commented on July 21, 2024

8000 is semi-arbitrary. The size just has to be large enough to hold the text of a long FOREIGN KEY object name. 1024 would work until you had a DDL generation for a line needing 1025 characters.

On Oct 31, 2015, at 6:46 PM, ericfe [email protected] wrote:

Have you tried with other values ( like 1024 instead of 8000 ) ?


Reply to this email directly or view it on GitHub #38 (comment).

from amazon-redshift-utils.

ericfe avatar ericfe commented on July 21, 2024

Correct. Given the max size of objects( tables and columns ) 1024 should be enough.
8000 has performance implications. If 1024 works for you, I will go with that for now.

from amazon-redshift-utils.

ericfe avatar ericfe commented on July 21, 2024

Pushed fix

from amazon-redshift-utils.

 avatar commented on July 21, 2024

Looks like the problem isn't fixed. The fix should go on line 89 in the --CONSTRAINT LIST section of the query. This can be reproduced by adding a UNIQUE constraint on a table using enough columns to blow past 275 characters, and then querying v_generate_tbl_ddl. The fix is still the same as I described - change line 89 to:
,'\t,' + pg_get_constraintdef(con.oid)::VARCHAR(1024) AS ddl

from amazon-redshift-utils.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.