Difference | GetRange operation | Search operation |
---|---|---|
Real-time query | The GetRange operation is performed on the data table. You do not need to create an
index to query data. You can query data immediately after the data is written to the
data table.
For more information about the GetRange operation, see Read data whose primary key is in a specified range and GetRange. |
The Search operation is performed on the search index. Data is asynchronously synchronized
from the data table to the search index that is created for the data table. You can
query data from the search index after the data is synchronized from the data table
to the search index. In most cases, data is synchronized from the data table to the
search index 3 seconds after the data is written to the data table.
For more information about the Search operation, see Overview. |
Consumption and scaling of computing resources | The system locates the partitions of the data table based on the specified primary key range and performs read operations only on the partitions. A small number of computing resources are consumed, and the computing resources are scalable. | The consumption and scaling of computing resources vary based on whether or not you
specify a routing key when you create a search index.
For information about how to create a search index, see Create search indexes. |
Data filtering | Data can be scanned. Complex data filtering is not supported. | The Search operation is more flexible than the GetRange operation. You can specify column conditions and combine the conditions to filter data based on search indexes. |