Environment
- Yugabyte Platform
Issue
Finding the tablet on which that particular primary key is on.
Use Case:
A particular partition key is throwing an error and we want to know which tablet that partition key is on.
Resolution
Overview
First of all the primary key, in this case, is going to be the partition key.
Steps:
1. We have to take the hashing range of each tablet and convert it to the decimal number format.
https://www.rapidtables.com/convert/number/hex-to-decimal.html
This link can help in the conversion.
2. Connect the shell
3. Run the below query:
select partition_hash(id) from table.name where id = the-id-we-are-looking-for;
4. We can get the hashing range from the UI as shown in the screenshot (column 2):
Comments
1 comment
How do we find hashing range of each tablet for each table?
Please sign in to leave a comment.