Title: Athena V3 compatibility issue with condition on the timestamp field · Issue #5935 · feast-dev/feast · GitHub
Open Graph Title: Athena V3 compatibility issue with condition on the timestamp field · Issue #5935 · feast-dev/feast
X Title: Athena V3 compatibility issue with condition on the timestamp field · Issue #5935 · feast-dev/feast
Description: Expected Behavior I can run materialization of feature views with Athena V3 as offline store. Current Behavior Getting an error like this feast.infra.utils.aws_utils.AthenaQueryError: Athena SQL Query failed to finish. Details: {'QueryEx...
Open Graph Description: Expected Behavior I can run materialization of feature views with Athena V3 as offline store. Current Behavior Getting an error like this feast.infra.utils.aws_utils.AthenaQueryError: Athena SQL Qu...
X Description: Expected Behavior I can run materialization of feature views with Athena V3 as offline store. Current Behavior Getting an error like this feast.infra.utils.aws_utils.AthenaQueryError: Athena SQL Qu...
Opengraph URL: https://github.com/feast-dev/feast/issues/5935
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Athena V3 compatibility issue with condition on the timestamp field","articleBody":"## Expected Behavior \nI can run materialization of feature views with Athena V3 as offline store.\n\n## Current Behavior\n\nGetting an error like this\n`feast.infra.utils.aws_utils.AthenaQueryError: Athena SQL Query failed to finish. Details: {'QueryExecution': {'QueryExecutionId': 'b5444c28-41d0-4992-81cc-6d524750161a', 'Query': 'CREATE TABLE _a8a21947682843c598b8340d0ac02738\\n WITH (\\n external_location = \\'s3://re-ds-feature-store-test-bkt/reco/athena_staging/unload/50b466e7-6cfe-40f7-8f21-a615ca3e0243\\',\\n format = \\'parquet\\',\\n write_compression = \\'snappy\\'\\n )\\n as\\n \\n SELECT property_reference_id, listing_id, is_active, offer_type, country, canton, postalcode, locality, street, geo_latitude, geo_longitude, platforms, subcategory_main_code_hgrets, category_idx, price_gross_normalized, size_sqm_normalized_cleaned, number_of_rooms_cleaned, floor, year_built, year_lastrenovated, are_pets_allowed, has_elevator, has_parking, has_garage, has_niceview, has_steamer, has_washingmachine, has_tumbledryer, has_cabletv, has_flatsharingcommunity, has_attic, has_balcony, has_gardenshed, has_swimmingpool, has_fireplace, is_childfriendly, is_wheelchairaccessible, is_minergiegeneral, is_minergiecertified, is_newbuilding, is_groundfloor, is_oldbuilding, timestamp\\n FROM \"AwsDataCatalog\".\"feature_store_reco\".\"listings\"\\n WHERE timestamp BETWEEN \\'2026-02-01 01:00:00.000\\' AND \\'2026-02-01 02:00:00.000\\'', 'StatementType': 'DDL', 'ResultReuseConfiguration': {'ResultReuseByAgeConfiguration': {'Enabled': False}}, 'QueryExecutionContext': {'Database': 'feature_store_reco', 'Catalog': 'awsdatacatalog'}, 'Status': {'State': 'FAILED', 'StateChangeReason': 'TYPE_MISMATCH: line 52:18: Cannot check if timestamp(3) is BETWEEN varchar(23) and varchar(23). You may need to manually clean the data before retrying. Athena will not delete data in your account.', 'SubmissionDateTime': datetime.datetime(2026, 2, 2, 16, 2, 54, 362000, tzinfo=tzlocal()), 'CompletionDateTime': datetime.datetime(2026, 2, 2, 16, 2, 55, 164000, tzinfo=tzlocal()), 'AthenaError': {'ErrorCategory': 2, 'ErrorType': 1002, 'Retryable': False, 'ErrorMessage': 'TYPE_MISMATCH: line 52:18: Cannot check if timestamp(3) is BETWEEN varchar(23) and varchar(23). You may need to manually clean the data before retrying. Athena will not delete data in your account.'}}, 'Statistics': {'EngineExecutionTimeInMillis': 395, 'DataScannedInBytes': 0, 'TotalExecutionTimeInMillis': 802, 'QueryQueueTimeInMillis': 55, 'ServicePreProcessingTimeInMillis': 172, 'ServiceProcessingTimeInMillis': 180, 'ResultReuseInformation': {'ReusedPreviousResult': False}}, 'WorkGroup': 'wg_re-data-services-feature-store-stk-test', 'EngineVersion': {'SelectedEngineVersion': 'AUTO', 'EffectiveEngineVersion': 'Athena engine version 3'}, 'SubstatementType': 'CREATE_TABLE_AS_SELECT'}, 'ResponseMetadata': {'RequestId': 'd3f31624-2219-44a0-8eb7-47a4223eac49', 'HTTPStatusCode': 200, 'HTTPHeaders': {'date': 'Mon, 02 Feb 2026 15:02:55 GMT', 'content-type': 'application/x-amz-json-1.1', 'content-length': '4887', 'connection': 'keep-alive', 'x-amzn-requestid': 'd3f31624-2219-44a0-8eb7-47a4223eac49'}, 'RetryAttempts': 0}}`\n\n## Steps to reproduce\n\n### Specifications\n\n- Version: \u003e=v0.55.0\n- Platform: macOS/Linux\n- Subsystem:\n\n## Possible Solution\nChange cast_style=\"raw\" to cast_style=\"timestamp\" in feast/infra/offline_stores/contrib/athena_offline_store/athena.py line 112:\n```python\ntimestamp_filter = get_timestamp_filter_sql(\n start_date_str,\n end_date_str,\n timestamp_field,\n date_partition_column,\n cast_style=\"timestamp\", # \u003c-- Fix: use \"timestamp\" instead of \"raw\"\n quote_fields=False,\n)\n```","author":{"url":"https://github.com/dym-ok","@type":"Person","name":"dym-ok"},"datePublished":"2026-02-02T15:52:17.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":0},"url":"https://github.com/5935/feast/issues/5935"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:26f8d8a8-3ce5-7e70-92af-7cdc81867feb |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | EC36:2095E1:3162782:4539FE6:6A4F7A28 |
| html-safe-nonce | 25778b854eecbee283a14dd76cc501771ceeca98b1016d3e2e35cfd2a6543503 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFQzM2OjIwOTVFMTozMTYyNzgyOjQ1MzlGRTY6NkE0RjdBMjgiLCJ2aXNpdG9yX2lkIjoiNjA1ODk4NzM0NDk0OTYzOTcyMCIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 47203c6a1ad05520054f167dfd43cd155499d610f4bb16d46909ac0f7b0f2673 |
| hovercard-subject-tag | issue:3886680443 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/feast-dev/feast/5935/issue_layout |
| twitter:image | https://opengraph.githubassets.com/fa6fb9a8fb483f6e32585aeb5676f6c0ad14ece68dfbd71ec72118e3cf36c2c5/feast-dev/feast/issues/5935 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/fa6fb9a8fb483f6e32585aeb5676f6c0ad14ece68dfbd71ec72118e3cf36c2c5/feast-dev/feast/issues/5935 |
| og:image:alt | Expected Behavior I can run materialization of feature views with Athena V3 as offline store. Current Behavior Getting an error like this feast.infra.utils.aws_utils.AthenaQueryError: Athena SQL Qu... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | dym-ok |
| hostname | github.com |
| expected-hostname | github.com |
| None | b92d11c0aa4a77d54ef4af1078b6a15fb5a70a215b30c4ecf28889d5a8e656d9 |
| turbo-cache-control | no-preview |
| go-import | github.com/feast-dev/feast git https://github.com/feast-dev/feast.git |
| octolytics-dimension-user_id | 57027613 |
| octolytics-dimension-user_login | feast-dev |
| octolytics-dimension-repository_id | 161133770 |
| octolytics-dimension-repository_nwo | feast-dev/feast |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 161133770 |
| octolytics-dimension-repository_network_root_nwo | feast-dev/feast |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 4b249b445842943ed31549e027f57a8ade9881ed |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width