nastra commented on code in PR #9286: URL: https://github.com/apache/iceberg/pull/9286#discussion_r1430387289
########## spark/v3.5/spark/src/test/java/org/apache/iceberg/spark/sql/TestSelect.java: ########## @@ -234,23 +234,31 @@ public void testVersionAsOf() { } @Test - public void testTagReferenceAsOf() { + public void testTagReference() { Table table = validationCatalog.loadTable(tableIdent); long snapshotId = table.currentSnapshot().snapshotId(); table.manageSnapshots().createTag("test_tag", snapshotId).commit(); - - // create a second snapshot, read the table at the snapshot List<Object[]> expected = sql("SELECT * FROM %s", tableName); + + // create a second snapshot, read the table at the tag sql("INSERT INTO %s VALUES (4, 'd', 4.0), (5, 'e', 5.0)", tableName); List<Object[]> actual1 = sql("SELECT * FROM %s VERSION AS OF 'test_tag'", tableName); assertEquals("Snapshot at specific tag reference name", expected, actual1); - // read the table at the snapshot + // read the table at the tag // HIVE time travel syntax List<Object[]> actual2 = sql("SELECT * FROM %s FOR SYSTEM_VERSION AS OF 'test_tag'", tableName); assertEquals("Snapshot at specific tag reference name", expected, actual2); - // read the table using DataFrameReader option: branch + // Spark session catalog does not support extended table names + if (!"spark_catalog".equals(catalogName)) { + // read the table at the tag Review Comment: ```suggestion // read the table using the "tag_" prefix in the table name ``` -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@iceberg.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@iceberg.apache.org For additional commands, e-mail: issues-h...@iceberg.apache.org