Abstract: Provided are a data indexing method, a data querying method and an electronic device. The data indexing method includes: creating a clustered index for a plurality of data records according to values of preset fields within the plurality of data records, wherein the plurality of data records are configured to store data files, and the values of the preset fields are field values of the clustered index; plotting, for each of the data records, a data distribution diagram of offsets versus the data records in the data file; and performing curve-fitting on the data distribution diagram to obtain an index relation containing correspondences between the field values and the offsets, so that the offset is calculated according to the field values of the data record to be queried, and thereby the data record is queried.
Abstract: Provided are a data indexing method, a data querying method and an electronic device. The data indexing method includes: creating a clustered index for a plurality of data records according to values of preset fields within the plurality of data records, wherein the plurality of data records are configured to store data files, and the values of the preset fields are field values of the clustered index; plotting, for each of the data records, a data distribution diagram of offsets versus the data records in the data file; and performing curve-fitting on the data distribution diagram to obtain an index relation containing correspondences between the field values and the offsets, so that the offset is calculated according to the field values of the data record to be queried, and thereby the data record is queried.
Abstract: Provided are a data indexing method, a data querying method and an electronic device. The data indexing method includes: creating a clustered index for a plurality of data records according to values of preset fields within the plurality of data records, wherein the plurality of data records are configured to store data files, and the values of the preset fields are field values of the clustered index; plotting, for each of the data records, a data distribution diagram of offsets versus the data records in the data file; and performing curve-fitting on the data distribution diagram to obtain an index relation containing correspondences between the field values and the offsets, so that the offset is calculated according to the field values of the data record to be queried, and thereby the data record is queried.