Show partitions allocated to a specific raw or historical poll data table
This query lists the partitions allocated to a specific raw or historical poll data table. This query is useful if you want to investigate whether all partitions are being created properly.
The sample query provided shows partitions allocated to the raw poll data , pollData. By
default, this table stores approximately an hour of raw poll data, and the table is partitioned into
8 partitions of 10 minutes each. Check the results of this query to make sure that the upper and
lower ranges of the partition reflect expected values according to the clock on the server hosting
the database. If these times are not current then either the relevant instance of the Polling
engine, ncp_poller, is not runnning, or there is a problem creating new partitions.
Example
This example query displays sample SQL to show partitions allocated to the raw poll data , pollData.select TABNAME,DATAPARTITIONNAME,LOWTIME,HIGHTIME
from ncpolldata.pollDataPartitions
WHERE TABNAME = 'POLLDATA'
ORDER BY HIGHTIME
The
table below describes this query.
Line numbers | Description |
---|---|
1 |
Specify the data to show in the results.
|
2 | Specify the pollDataPartitions table as the driving table for this query. |
3 | Limit the partition data retrieved to those partitions related to the pollData table. |
4 | List results in order of the HIGHTIME column. This orders the data by latest partition first. |
Results
The table below shows sample results for this query.
Table name |
Partition name |
Low time |
High time |
---|---|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-08-13 12:50:00 |
|
|
|
2015-08-13 13:00:00 |