I have collected and stored a huge dataset on the sales of motorcycle parts' shops in different cities. Since GridDB is known for its high-speed query results, it is a strong candidate for data storage.
I wanted to create a partitioned collection of data based on its cities to pinpoint those locations in order to maintain the high availability of parts. The partitioned collection created is shown below:
CREATE COLLECTION Bike_Parts_Sales (
id INTEGER,
city TEXT,
amount DOUBLE,
item TEXT,
PRIMARY KEY (id)
)
WITH (
TYPE='PARTITION',
COLUMN='city',
INTERVAL='100'
);
I performed a simple SELECT query on the column region between a specific date as follows:
SELECT * FROM Bike_Parts_Sales WHERE region = 'KHI' AND timestamp between '2024-03-25' and '2024-03-29';
However, GridDB was unable to perform the query and returned back with the following error:
ERROR: Query execution failed: [GS_ERR_PARTIAL_SEARCH_INCOMPLETE] Query execution failed due to an incomplete search in the partitioning order. Please retry the query later.
The partitioning error usually occurs when the partitioning column is not used in the query to fetch the data. However, I have queried on the partitioned column. In addition, I have retried the query on multiple occasions and at different intervals of time and even executed the query on a single date, but it has not solved the issue.
SELECT * FROM Bike_Parts_Sales WHERE region = 'KHI' AND timestamp = '2024-03-25';
As far as I have diagnosed, the issue is because GridDB is unable to perform a search on all the partitions. What is its root cause?
Kindly assist, and thank you in advance.