how to define long varchar in hazelcast python client?

34 Views Asked by At

I create map in hazelcast with sql statement like this:

query = f'''CREATE MAPPING  {category_name}(
    __key INT,
    create_time BIGINT,
    raw_database VARCHAR)
    TYPE IMap
    OPTIONS('keyFormat'='int', 'valueFormat'='json-flat');'''
create_category_response = client.sql.execute(query)

when i insert long varchar in map:

row_database = """jkhbjhbkjqwertyuiop[]asdfghjkl;/.mnbvcxzasdfgqewrtyhygjutjqazwsxedcrfvtgbnhytgujmnhy15978huinhtrfvgdeswapkmjbgjnbhytqwexzasfeaqijnhb531254872gtdghgggggga"""
query = f"INSERT INTO {category_name} VALUES(1, 146546321654, '{row_database}');"
reponse = client.sql.execute(query)

get error like this:

HazelcastSqlError("Length of identifier "jkhbjhbkjqwertyuiop[]asdfghjkl;/.mnbvcxzasdfgqewrtyhygjutjqazwsxedcrfvtgbnhytgujmnhy15978huinhtrfvgdeswapkmjbgjnbhytqwexzasfeaqijnhb531254872gtdghgggggga", ' must be less than or equal to 128 characters", None)

0

There are 0 best solutions below