Files
floci/docs
Priamo Germosen f0ee5d44a0 fix(athena): answer no rows for a table whose location holds no data (#8575)
Athena answers a table whose S3 location holds no data with no rows.
Floci's view read the location with DuckDB's read_* glob, which refuses
to bind when nothing matches, so every query on such a table failed.

- GlueViewDdlBuilder checks the location a table is read from (its read
  path, so a projected table's partition folders) before building its
  view. One that holds no data gets a view of no rows with the table's
  declared columns as their declared types (GlueTableResolver
  .emptyProjection), nested and binary columns as the engine reads them
  (columnType: array<T> as T[], map, struct, binary as BLOB).
- TableLocation.holdsNoData lists the location in one scan: folder
  markers (keys ending in a slash) hold no data, and a read path with
  `*` segments is listed from its literal prefix, an object counting
  when its key matches the glob. A location holding another glob
  character, or whose bucket does not exist, is read as before.

GlueViewDdlBuilderTest covers an empty location, one holding only
folder markers, a projected location holding only objects its glob does
not reach, nested and binary column types, an unmodeled glob and a
missing bucket. AthenaDelimitedTextSidecarIntegrationTest
queries an empty location and a folder marker against the real engine.
athena.md says so.
2026-11-16 08:52:15 -04:00
..
2026-03-15 17:43:56 -05:00