<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def table_to_csv(table, engine, filepath, chunksize=1000, overwrite=False):
 """ Export entire table to a csv file. :param table: :class:`sqlalchemy.Table` instance. :param engine: :class:`sqlalchemy.engine.base.Engine`. :param filepath: file path. :param chunksize: number of rows write to csv each time. :param overwrite: bool, if True, avoid to overite existing file. **中文文档** 将整个表中的所有数据, 写入csv文件。 """

    sql = select([table])
    sql_to_csv(sql, engine, filepath, chunksize)