简体   繁体   中英

Aws Wrangler giving not implemented error: impossible to query aws athena

I'm trying to query AWS Athena with aws wrangler, but it's always giving me 'NotImplementedError: dictionary<values=int32, indices=int32, ordered=0>'. Currently the wrangler package I'm using is 2.17.0 and I've tried both python 3.10.8 and 3.9.15.

To reproduce:

import awswrangler as wr
import boto3
boto3.setup_default_session(region_name="eu-central-1")

def download_all_matches():
    query = "SELECT * FROM database"
    df = wr.athena.read_sql_query(query, database="db",categories=["x","y"])

df = download_all()

The issue seems to be with pyarrow, however, I've tried to use other packages in addition to the basic package (8.0.0) conda installs.

Apparently the trick was to not specify the columns (read_sql_query(... categories=[]). In my understanding some of the previous versions of Wrangler demanded, or at least worked with, specifying the categories or columns.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM