zadd

This block is part of the redis group and was last modified in core v15.0.3.

Redis Key Selection Required

This block relies on a Redis key to perform its redis releated actions. You must manually select the Redis key you want to use in the flow in the blueprint using the Redis key selector modal. To access the modal, click the white button on the block.

zadd v13.0.5 Updated v15.0.3

add one member to a sorted set

In pins 6 + flow
  • flow
  • value value required

    value to add

  • score number required

    score number

  • insert only condition

    adds NX to the command options, indication it should only insert and not update existing members

  • increment condition

    adds INCR to the command options, indication it should increment the score to the existing member

  • only if greater condition v15.0.3

    moves an existing member only when the new score is greater than the one it has; a member that is not there is added. One Redis step on every Redis version (a fixed script, not ZADD GT). Not together with insert only, increment or only if less (INVALID_OPTIONS); the score must be a finite number (INVALID_SCORE) and the value a string or a number (INVALID_VALUE)

  • only if less condition v15.0.3

    moves an existing member only when the new score is less than the one it has; a member that is not there is added. The rules of only if greater apply

Out pins 6 + flow
  • flow
  • result number

    Returns the number of items added or updated within the sorted set

  • changed condition v15.0.3

    With only if greater or only if less: true when the member was added or its score moved, false when the score it had was kept. Not written without those options

  • score number v15.0.3

    With only if greater or only if less: the score the member has after the block ran. Not written without those options

  • success condition

    Returns true when the operation succeeded

  • error value
  • key value v13.0.7
redis zadd
zadd

A typical wiring for zadd: a function trigger starts the flow; value feeds the set pin; value feeds the value pin; number feeds the score pin; the flow out pin feeds debug.

Studio canvas example for the zadd block: typical wiring for zadd.

Version history

Introduced in v13.0.5.

Last modified in v15.0.3.

v13.0.7 This block or one of its pins was updated in v13.0.7, click here to see the release notes.

Service documentation

External API reference This block wraps a third-party service. Click here for the service's own documentation of the underlying endpoint.
Back to redis Return to the main group to view all sub-groups Back to redis sorted sets Return to the group to view all blocks within this group