Title: A deep reinforcement learning model with plan value network for join order selection

Authors: Yifan Qiao; Shengjie Wei; Ruiwei Gao; Nan Han; Shaojie Qiao; Haiquan Song

Addresses: Chu Kochen Honors College, Zhejiang University, Hangzhou, Zhejiang, China ' Digital Media Art, Key Laboratory of Sichuan Province, Sichuan Conservatory of Music, Chengdu, Sichuan, China ' School of Software Engineering, Chengdu University of Information Technology, Chengdu, Sichuan, China ' School of Software Engineering, Chengdu University of Information Technology, Chengdu, Sichuan, China ' School of Software Engineering, Chengdu University of Information Technology, Chengdu, Sichuan, China ' School of Energy Power and Mechanical Engineering, North China Electric Power University, Baoding 071003, Beijing, China

Abstract: The existing optimisers and dynamic programming methods rely on the cardinality estimation and the cost model of the local database. The resulting join plan does not reflect the execution time, and the errors of cardinality estimation will also lead to the join plans with poor quality. We propose a new learning optimiser, called DVJ (Deep reinforcement learning with plan Value networks for Join order selection). Compared with the existing deep reinforcement learning method, DVJ has two improvements: (1) the plan value network is designed to improve the reward mechanism in the existing deep reinforcement learning method, and the join plan generated by DVJ can reflect the latency; (2) applying Deep Q-Network to reduce the optimisation time and increase the chance of finding the best connection plan. Extensive experiments are conducted and the experimental results demonstrate that DVJ outperforms traditional optimisers and the existing deep reinforcement learning methods.

Keywords: query optimisation; join order selection; database management system; cardinality estimation; deep reinforcement learning; cost estimation; query optimiser; query plan; join plan; join optimisation.

DOI: 10.1504/IJWMC.2021.121627

International Journal of Wireless and Mobile Computing, 2021 Vol.21 No.4, pp.365 - 374

Received: 15 Sep 2021
Accepted: 22 Jan 2022

Published online: 21 Mar 2022 *

Full-text access for editors Full-text access for subscribers Purchase this article Comment on this article