- Redis Basics
- Redis - Home
- Redis - Overview
- Redis - Environment
- Redis - Configuration
- Redis - Data types
- Redis Commands
- Redis - Commands
- Redis - Keys
- Redis - Strings
- Redis - Hashes
- Redis - Lists
- Redis - Sets
- Redis - Sorted Sets
- Redis - HyperLogLog
- Redis - Publish Subscribe
- Redis - Transactions
- Redis - Scripting
- Redis - Connections
- Redis - Server
- Redis Advanced
- Redis - Backup
- Redis - Security
- Redis - Benchmarks
- Redis - Client Connection
- Redis - Pipelining
- Redis - Partitioning
- Redis - Java
- Redis - Php
- Redis Useful Resources
- Redis - Quick Guide
- Redis - Useful Resources
- Redis - Discussion
Redis - Hash Hincrbyfloat Command
Redis HINCRBYFLOAT command is used to increment the specified field of a hash stored at the key, and representing a floating point number, by the specified increment. If the field does not exist, it is set to 0 before performing the operation. If the field contains a value of wrong type or specified increment is not parsable as floating point number, then an error occurs.
Return Value
String reply, the value of the field after the increment.
Syntax
Following is the basic syntax of Redis HINCRBYFLOAT command.
redis 127.0.0.1:6379> HINCRBYFLOAT KEY_NAME FIELD_NAME INCR_BY_NUMBER
Example
redis 127.0.0.1:6379> HSET myhash field 20.50 (integer) 1 redis 127.0.0.1:6379> HINCRBYFLOAT mykey field 0.1 "20.60"
redis_hashes.htm
Advertisements