You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* console.log(sortedElements); // Output: 2 - number of elements sorted and stored
7406
+
* console.log(await client.lrange("sortedList", 0, -1)); // Output: [ 'Bob', 'Alice' ] - Returns a list of the names sorted by age stored in `sortedList`
Copy file name to clipboardExpand all lines: node/src/Commands.ts
+13-17Lines changed: 13 additions & 17 deletions
Original file line number
Diff line number
Diff line change
@@ -3544,20 +3544,30 @@ export function createZIncrBy(
3544
3544
}
3545
3545
3546
3546
/**
3547
-
* Optional arguments to {@linkGlideClient.sort|sort}, {@linkGlideClient.sortStore|sortStore} and {@linkGlideClient.sortReadOnly|sortReadOnly} commands.
3547
+
* Optional arguments to {@linkBaseClient.sort|sort}, {@linkBaseClient.sortStore|sortStore} and {@linkBaseClient.sortReadOnly|sortReadOnly} commands.
3548
3548
*
3549
3549
* See https://valkey.io/commands/sort/ for more details.
3550
+
*
3551
+
* @remarks When in cluster mode, {@link SortOptions.byPattern|byPattern} and {@link SortOptions.getPatterns|getPattern} must map to the same hash
3552
+
* slot as the key, and this is supported only since Valkey version 8.0.
3550
3553
*/
3551
-
exporttypeSortOptions=SortBaseOptions&{
3554
+
exportinterfaceSortOptions{
3552
3555
/**
3553
3556
* A pattern to sort by external keys instead of by the elements stored at the key themselves. The
3554
3557
* pattern should contain an asterisk (*) as a placeholder for the element values, where the value
3555
3558
* from the key replaces the asterisk to create the key name. For example, if `key`
3556
3559
* contains IDs of objects, `byPattern` can be used to sort these IDs based on an
3557
3560
* attribute of the objects, like their weights or timestamps.
3561
+
* Supported in cluster mode since Valkey version 8.0 and above.
3558
3562
*/
3559
3563
byPattern?: GlideString;
3560
3564
3565
+
/**
3566
+
* Limiting the range of the query by setting offset and result count. See {@link Limit} class for
3567
+
* more information.
3568
+
*/
3569
+
limit?: Limit;
3570
+
3561
3571
/**
3562
3572
* A pattern used to retrieve external keys' values, instead of the elements at `key`.
3563
3573
* The pattern should contain an asterisk (`*`) as a placeholder for the element values, where the
* console.log(sortedElements); // Output: 2 - number of elements sorted and stored
954
-
* console.log(await client.lrange("sortedList", 0, -1)); // Output: [ 'Bob', 'Alice' ] - Returns a list of the names sorted by age stored in `sortedList`
0 commit comments