3

the problem is that the primary key index cannot be 128 bits long. it must be 64 bits. but other indexes can be 128 bits so my solution was to implement an auto-generated monotonic primary key and then define the index I wanted as a secondary index struct [[eosio::table]] _prices { uint64_t id; symbol base; symbol quote; ... ...


1

You need to delete all instances of the old database structure before you can mutate it, I believe an instance still exists in the ether despite it not showing up anymore. If you're just on a local testnet, reset the chain otherwise wipe the deployed contract and re-deploy a fresh copy.


1

eosio::name is uint64_t internally and encodes string with BASE32. If you are sure that your tableid will contain chars in range of [.1-5a-z] and its length won't exceed 12 (or 13th-char only can have [.1-5a-j]), you can use it as primary key. By the way, the size of string is determined by its length, so if your tableid are expected to be longer than 8 in ...


Only top voted, non community-wiki answers of a minimum length are eligible