marqdo

Row recordsok

structure/08-records.mq.md

文档

main

说明

When the first header is @ or row, each data row is a map (marker column is not a field). Nested get: [field]([1](orders)).

orders =
@nameqty
1apple2
2pear3
n =nameaccess([1](access(orders, "1")), "name")
> print text=n
q =qtyaccess([2](access(orders, "2")), "qty")
> print text=q
Functions
Variables
  • description text
    First header @ / row makes a list of maps
  • markup text
    occlusion
  • n text
    apple
  • orders list · 2
    #nameqty
    1apple2
    2pear3
  • q int
    3
  • title text
    Row records
可执行知识(辅助)

运行与结果

apple 3
完整源码
---
markup: occlusion
title: Row records
description: First header @ / row makes a list of maps
---

# main

When the first header is `@` or `row`, each data row is a map (marker column is not a field). Nested get: `[field]([1](orders))`.

`orders` =

| @ | name | qty |
|---|------|-----|
| 1 | apple | 2 |
| 2 | pear | 3 |

**`n` = [name](access([1](access(orders, "1")), "name"))**

> print text=`n`

**`q` = [qty](access([2](access(orders, "2")), "qty"))**

> print text=`q`

Variable