Embodiments of the present application provide a
data processing method and device based on a
line segment tree structure, equipment and medium, the method comprises: after the
oracle contract receives the first transaction request sent by the business contract, the first request condition corresponding to the first condition hash value is obtained based on the first transaction request, and the condition hash value matched with the first condition hash value is found in the
line segment tree structure of the on-chain storage space. If not found, the
oracle contract is called to send the first off-chain query request for the first request condition to the off-chain
oracle, so that the oracle returns the first off-chain
business data to the oracle contract. The received first off-chain
business data is taken as the first
business data by calling the oracle contract, and the first business data and the first condition hash value are updated to the
tree node associated with the first request condition in the on-chain storage space. By using the embodiments of the present application, the
utilization rate of off-chain data can be improved, and the waste of storage resources can be avoided.