.. _f-databasemain: module ``sql.database_main`` ============================ .. inheritance-diagram:: pyensae.sql.database_main Short summary +++++++++++++ module ``pyensae.sql.database_main`` generic class to access a SQL database :githublink:`%|py|5` Classes +++++++ +--------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------+ | class | truncated documentation | +========================================================+========================================================================================================================+ | :class:`Database ` | This class allows the user to load table from text files and store them into a SQL file which can be empty or not, ... | +--------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------+ Static Methods ++++++++++++++ +------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------+ | staticmethod | truncated documentation | +==============================================================================+============================================================================================+ | :meth:`fill_sql_table ` | Returns a Database object, creates the database if it does not exists, same for the table. | +------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------+ | :meth:`schema_database ` | Returns the schema for a database which would contains this database. | +------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------+ Methods +++++++ +--------------------------------------------------------------------------------+-----------------------------------------------------------------------+ | method | truncated documentation | +================================================================================+=======================================================================+ | :py:meth:`__init__ ` | | +--------------------------------------------------------------------------------+-----------------------------------------------------------------------+ | :meth:`copy_to ` | Copies all tables into db, we assume both database are not connected. | +--------------------------------------------------------------------------------+-----------------------------------------------------------------------+ | :meth:`import_dataframe ` | Imports a DataFrame into a table. | +--------------------------------------------------------------------------------+-----------------------------------------------------------------------+ | :meth:`to_df ` | Converts a SQL request into a :epkg:`pandas:Dataframe`. | +--------------------------------------------------------------------------------+-----------------------------------------------------------------------+ Documentation +++++++++++++ .. automodule:: pyensae.sql.database_main :members: :special-members: __init__ :show-inheritance: