Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

Re^5: Create parallel database handles or SQL statements for multi-threaded/process access to Postgres DB using DBI, DBD::Pg and Parallel::ForkManager

by 1nickt (Canon)
on May 08, 2020 at 16:33 UTC ( [id://11116583]=note: print w/replies, xml ) Need Help??


in reply to Re^4: Create parallel database handles or SQL statements for multi-threaded/process access to Postgres DB using DBI, DBD::Pg and Parallel::ForkManager
in thread Create parallel database handles or SQL statements for multi-threaded/process access to Postgres DB using DBI, DBD::Pg and Parallel::ForkManager

Hi again,

Add to your DB schema:

unique key all_cols_uk (every, column, name, in, the, table),

https://www.w3schools.com/sql/sql_unique.asp

Hope this helps!


The way forward always starts with a minimal test.
  • Comment on Re^5: Create parallel database handles or SQL statements for multi-threaded/process access to Postgres DB using DBI, DBD::Pg and Parallel::ForkManager
  • Download Code

Replies are listed 'Best First'.
Re^6: Create parallel database handles or SQL statements for multi-threaded/process access to Postgres DB using DBI, DBD::Pg and Parallel::ForkManager
by erix (Prior) on May 08, 2020 at 18:52 UTC

    On that page postgres is not mentioned; in postgresql-SQL, that'd become, I think:

    create unique index all_cols_uk on tablename (every, column, name, in, + the, table) ;

    See: CREATE INDEX in the fine manual

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11116583]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others avoiding work at the Monastery: (2)
As of 2024-04-25 05:45 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found