alamb commented on issue #20135: URL: https://github.com/apache/datafusion/issues/20135#issuecomment-4683022019
I did some research on APIs of other systems and wonderfully they aren't anywhere near consistent: | System | What the user writes | |---|---| | **DataFusion (this PR)** | `file_row_index()` | | **Spark** | `_metadata.row_index` [msft](https://learn.microsoft.com/en-us/azure/databricks/ingestion/file-metadata-column) / [databricks](https://docs.databricks.com/aws/en/ingestion/file-metadata-column)| | **DuckDB** | [`read_parquet('f', file_row_number=true)`](https://duckdb.org/docs/current/data/parquet/overview#parameters) | | **Snowflake** | [`METADATA$FILE_ROW_NUMBER`](https://docs.snowflake.com/en/user-guide/querying-metadata#metadata-columns) (+ `METADATA$FILENAME`) | | **Polars** | [`scan_parquet(..., row_index_name="idx", row_index_offset=0)`](https://docs.pola.rs/api/python/stable/reference/api/polars.scan_parquet.html) / [`df.with_row_index("idx")`](https://docs.pola.rs/api/python/stable/reference/dataframe/api/polars.DataFrame.with_row_index.html) | **Similar Features** - DuckDB [`rowid`](https://duckdb.org/docs/stable/sql/statements/select#row-ids) — hidden pseudo-column, but only for native tables, not external Parquet. -- 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: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
