[ 
https://issues.apache.org/jira/browse/ARROW-11347?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17270480#comment-17270480
 ] 

Brian Hulette commented on ARROW-11347:
---------------------------------------

Ah, you mean when accessing a Row, e.g. table.get(0)

I _think_ the choice of Map was for code-reuse between Struct vectors and Map 
vectors ([~paul.e.taylor] wrote this, he could comment more certainly). Note I 
also added the ability to access the fields in a row view "by attribute" in 
Python parlance in https://github.com/apache/arrow/pull/2197. So if you have a 
table with a "foo" field you can access it in a Row view with either 
table.get(0)["foo"] or table.get(0).foo. I'm pretty sure I actually added that 
in response to a perf measurement from Jeff back in 2018.

> [JavaScript] Consider Objects instead of Maps
> ---------------------------------------------
>
>                 Key: ARROW-11347
>                 URL: https://issues.apache.org/jira/browse/ARROW-11347
>             Project: Apache Arrow
>          Issue Type: Improvement
>          Components: JavaScript
>            Reporter: Dominik Moritz
>            Priority: Major
>              Labels: performance
>   Original Estimate: 24h
>  Remaining Estimate: 24h
>
> A quick experiment 
> (https://observablehq.com/@domoritz/performance-of-maps-vs-objects) seems to 
> show that object accesses are a lot faster than map accesses. Would it make 
> sense to switch to objects in the row API to improve performance? 



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to