Actions37
- Append
- Blocking Pop Left
- Blocking Pop Right
- Delete
- Eval
- Exists
- Expire At
- Get
- Get Set
- Hash Exists
- Hash Keys
- Hash Length
- Hash Values
- Increment
- Info
- JSON Get
- JSON Set
- Keys
- List Length
- Multi Get
- Multi Set
- Persist
- Pop
- Publish
- Push
- Scan
- Set
- Set Add
- Set Cardinality
- Set Is Member
- Set Remove
- Sorted Set Add
- Sorted Set Cardinality
- Sorted Set Range
- Sorted Set Remove
- String Length
- TTL
Sorted Set Add
AI-generatedSummary
Add one or more members with associated scores to a Redis sorted set identified by its name.
Inputs
- Sorted Set (required) — The name of the sorted set to which members will be added.
- Score-Member Pairs (required) — Pairs of scores and members in the format "score1 member1 score2 member2" representing the values and their scores to add to the sorted set.
Output shape
a list containing an object with details about the insertion result
The output includes the sorted set name, the count of new members added, and an array of added score-member objects. An error is thrown if the score-member pairs are not provided in even numbers.
Examples
Example 1: Add two members with scores to a sorted set named 'mySortedSet'
Set 'Sorted Set' to 'mySortedSet' and 'Score-Member Pairs' to '1.0 member1 2.0 member2'.