JanKaul commented on PR #54:
URL: https://github.com/apache/iceberg-rust/pull/54#issuecomment-1702408379
Converting from Table to TableLike is straightforward:
```rust
impl From<Table> for TableLike {
fn from(value: Table) -> Self {
TableLike::Table(value)
}
}
```
So you would only need to call `table.into()`.
For the table scan operation you would need to check whether your input is a
table or a view and then execute the corresponding scan operator. As long as we
don't have view support it could look like:
```rust
let table = if let TableLike(table) = tablelike {
Ok(table)
} else {
Err(Error::new(... , "Views are not supported yet"))
}
```
--
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]