Abstract:Blockchain technology has attracted significantly attention in the field of distributed data management because of its decentralized and immutable nature. However, current blockchain systems face limitations in data query processing including single query function, low query efficiency and difficulties in ensuring query credibility. To address these challenges, in this paper, a global index structure called KMPT is proposed, inspired by the design concept of Ethereum Merkle Patricia tree on the premise of ensuring the immutability of index. The KMPT structure aims to realize the function of locating the target block at one time, avoiding the retrieval process of traversing blocks. Furthermore, by incorporating the intra-block index TMPT, the proposed approach enables high-efficiency content-based blockchain data retrieval. Experiments demonstrate that, compared with the method of only building intra block index, the proposed index model significantly improved the efficiency and stability of query retrieval within the acceptable index construction cost. In addition, it can provide the proof of existence or non-existence of data query at the same time, enhancing the credibility of query results.