postgres_file_writer

class mysql2pgsql.lib.postgres_file_writer.PostgresFileWriter(output_file, verbose=False)

Class used to ouput the PostgreSQL compatable DDL and/or data to the specified output file from a MySQL server.

Parameters :
  • output_file: the output file to send the DDL and/or data
  • verbose: whether or not to log progress to stdout
close()

Closes the output file

truncate(*args, **kwargs)

Write DDL to truncate the specified table

Parameters :

Returns None

write_constraints(*args, **kwargs)

Write DDL of table constraints to the output file

Parameters :

Returns None

write_contents(*args, **kwargs)

Write the data contents of table to the output file.

Parameters :

Returns None

write_indexes(*args, **kwargs)

Write DDL of table indexes to the output file

Parameters :

Returns None

write_table(*args, **kwargs)

Write DDL to create the specified table.

Parameters :

Returns None

Previous topic

postgres_db_writer

Next topic

postgres_writer

This Page