with pool.acquire() as connection: cursor = connection.cursor() for result in cursor.execute( """select sys_context('userenv','sid') from dual"""): print(result)