Skip to content

HMSET throws an error if values contained in hash struct are not strings #2

@MWers

Description

@MWers

This code...

<cfscript>
redisKey = "example:command:hmset";
hashValues = {};
hashValues["one"] = 1;
hashValues["two"] = 2;
hashValues["three"] = 3;
application.redis.hmset(redisKey, hashValues);
</cfscript>

...throws the following error on Railo...

java.lang.Double cannot be cast to java.lang.String

...when the hash values are passed to Jedis.

Not sure if there's a programmatic solution to avoid this or if the solution is "only use strings within hash value structs".

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions