Category "amazon-athena"

Copy and Merge files to another S3 bucket

I have a source bucket where small 5KB JSON files will be inserted every second. I want to use AWS Athena to query the files by using an AWS Glue Datasource and

Splitting an array into columns in Athena/Presto

I feel this should be simple, but I've struggled to find the right terminology, please bear with me. I have two columns, timestamp and voltages which is the a

how to import boto3 athena client exceptions

I am working with athena from within my python code, using boto3, as follows: def query_athena(query, output_path): client = boto3.client('athena') clie

How to connect From Athena to apache super-Set on AWS EC2 instance

Now i following the Superset official document for connect Athena and apache-Superset.. I already made ./docker/requirements-local.txt and add a driver.. (echo

Amazon Athena partition with colon(:) is not working

When creating partition in Athena, I tried to use the date in the format (yyyy-MM-ddTHH:mm:ssZ) then I am not able to query the data Step 1: Create table CREA

Can AWS Athena update or insert data stored in S3?

The document just says that it is a query service but not explicitly states that it can or cannot perform data update. If Athena cannot do insert or update, is

What's the data format of Athena's .csv.metadata files?

What's the data format of the .csv.metadata files written by Amazon Athena? Alongside the output file of every query there is a metadata file. It looks like it

way to check if two intervals overlap in amazon Athena / Presto

I am wondering if we have a way to check if two dates overlap in amazon athena (when writing an athena query) . I can do this in R / Python using the int_overla

Is there a way to drop all databases in AWS athena?

There's a bunch of test databases that I have and I'd like a way to drop all of them. They all have long random strings as names, so it kind of sucks to have to

Athena queries between tables in different accounts

I can individually access two different Athena tables using two different IAM roles because each lie in different accounts. Is there a way to run a single quer

How can I convert an integer representing EPOCH time to a timestamp in Athena (Presto)?

I have a table where the datetime is stored as varchar but represents the EPOCH time (e.g. 1556895150). How can I get that value to be recognized as a timestamp

Trying to create a table in AWS Athena using a query

I have tried and failed many times t create a table in Athena via the create table from s3 bucket data I have two other tables that work built by a previous col

Lambda function exclude .csv.metadata files from the output

I have a Lambda function that executing Athena query and exporting the output in csv file to S3 bucket. Now in my S3 bucket I'm getting 2 files .csv and .csv.me

String to YYYY-MM-DD date format in Athena

So I've looked through documentation and previous answers on here, but can't seem to figure this out. I have a STRING that represents a date. A normal output l

How to make MSCK REPAIR TABLE execute automatically in AWS Athena

I have a Spark batch job which is executed hourly. Each run generates and stores new data in S3 with the directory naming pattern DATA/YEAR=?/MONTH=?/DATE=?/dat

What is the Athena equivalent of MySQL's JSON_REMOVE?

I want to remove items from a json value, producing a new json value, within the scope of an Athena query. MySQL has the function JSON_REMOVE which does this ni

How to merge rows by a similar column via levenshtein distance

I'm using AWS Athena and I'm trying to merge all the rows which have a specific column with levenshtein_distance value lower then 5 and sum the normalised perce