def get_main_cnpj(store):
    """Get the MAIN_COMPANY' cnpj without ORM interaction"""
    result = store.execute(
        """
        SELECT company.cnpj
        FROM parameter_data, branch, company
        WHERE field_name = 'MAIN_COMPANY' AND
              branch.id::text = field_value AND
              branch.person_id = company.person_id;"""
        )
    data = result.get_one()
    result.close()
    return data[0] if data else ''
