来自用户指南http://www.dobeash.com/RebDB/db-guide.html
我做了这个
>> record: make block! []
== []
>> append record 'next
== [next]
>> append record now/date
== [next 13-Sep-2009]
>> append record "test insert date"
== [next 13-Sep-2009 "test insert date"]
>> db-insert my-table record
== [4 13-Sep-2009 "test insert date"]
>>
在一行中做任何更短的方法吗?
答案 0 :(得分:1)
您可以使用COMPOSE
:
db-insert my-table compose [next (now/date) "test insert date"]
或REDUCE
:
db-insert my-table reduce ['next now/date "test insert date"]