Hi
Is there a way to add a (bin, value) to existing key in atomic way.
For example there is a key with data
'bin1': 'value1'
and by doing something similar to client.add_bin(key, ‘bin2’, ‘value2’) get
'bin1': 'value1'
'bin2': 'value2'
without reading all the key record and putting back with updated bin info.
I saw that Aersopike client does have “remove_bin” function, I wondering will it have add_bin?
Thanks.
You have described the default behavior. The only time the existing record isn’t merged with the new write is when the write policy is set to replace.
I saw that Aersopike client does have “remove_bin” function, I wondering will it have add_bin?
This is done by sending a NULL value for the bin.
A bin is added automatically when you write a bin-name/bin-value pair that doesn’t yet exist. Removing it is done via sending a null, or in the case of the ‘bin remove’ that’s a helper that sends the null for you.
kporter
Split this topic
October 12, 2023, 4:11pm
5
system
Closed
January 4, 2024, 4:12pm
6
This topic was automatically closed 84 days after the last reply. New replies are no longer allowed.