I want to split data on multiple tiKV because I have Swiss, Europeans and Americans and I need to store data in citizen country.
The user’s table has a country code and automatically data are stored in a good zone (tikv --label zone=ch/eu/us).
How can I do this ?
As this is a regulatory requirement, you can specify Placement Rules in SQL for the affected table, together with partitioning. See Placement Rules in SQL.
Example placement rules:
Example table:
The
pEurope
partition will apply theeurope
policy.