This repository was archived by the owner on Jun 23, 2025. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
#652: feature: HRANDFIELD command #696
Merged
JyotinderSingh
merged 9 commits into
dicedb:master
from
Indranil0603:feature_HRANDFIELD
Sep 26, 2024
Merged
#652: feature: HRANDFIELD command #696
JyotinderSingh
merged 9 commits into
dicedb:master
from
Indranil0603:feature_HRANDFIELD
Sep 26, 2024
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Contributor
|
Could you please resolve the conflicts? |
Contributor
Author
|
Hi @JyotinderSingh I have resolved the conflicts |
lucifercr07
reviewed
Sep 25, 2024
JyotinderSingh
approved these changes
Sep 26, 2024
Contributor
JyotinderSingh
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for adding support for HRANDFIELD command @Indranil0603! I've changed the structure of the tests and the eval implementation a little to make it more readable.
Please go through it for future reference.
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Closes #652
Adds support for the HRANDFIELD command. This command returns one or more random fields from the hash stored at the specified key. If the "WITHVALUES" option is provided, both fields and their corresponding values are returned. It supports fetching a specific number of fields based on the count argument, with positive values returning unique fields and negative values allowing repeated selections.
Redis doc: HRANDFIELD
Changes: