Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 15 additions & 1 deletion js/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ import { tableFromIPC } from 'apache-arrow';
const arrow = readFileSync('simple.arrow');
const table = tableFromIPC(arrow);

console.table(table.toArray());
console.table([...table]);

/*
foo, bar, baz
Expand All @@ -64,6 +64,20 @@ null, null, null
*/
```

The most efficient way to work with an Arrow `Table` is to access the column Vectors (which you can get with `getChild` and `getChildAt`).

```js
table.getChildAt(0).get(0); // 1
```

If you need to access the rows, you can iterate over the table and access a row proxy.

```js
for (const row of table) {
console.log(row);
}
```

### Create a Table when the Arrow file is split across buffers

```js
Expand Down