January 2019
Beginner
556 pages
14h 19m
English
Psycopg 2 is able to execute the COPY command to quickly retrieve big amounts of data from the database or to store data in the database. The copy_to() and copy_from() methods of the cursor class are used, respectively, to copy data to a file-like object from a database table, and from a file-like object to a database table. There is another method, cursor.copy_expert(), that provides more advanced functionality with all the flexibility that the COPY command provides.
The cursor.copy_to() method takes the following parameters:
Read now
Unlock full access