Proceedings of the 2022 International Conference on Management of Data · 2022 · 20 citations · 22 references
ComputingComputer ScienceDatabasesKnowledge RepresentationMachine LearningDatabase ManagementGraph-based LearningQuery ProcessingRelational AlgebraRelational DatabasesStructured Query LanguageAttentionCardinality EstimationGraph Neural NetworksJoin OrderingOne-hot EncodingQuery EvaluationQuery RepresentationRelational Query Processing
Recently, the learning-based models are shown to outperform the conventional methods for many database tasks such as cardinality estimation, join order selection and performance tuning. However, most existing learning-based methods adopt the one-hot encoding for SQL query representation, unable to catch complicated semantic context, e.g. structure of query, database schema definition and distribution variance of columns. To address such above problem, we propose a novel pre-trained SQL representation model, called PreQR, which extends the language representation approach to SQL queries. We propose an automaton to encode the query structures, and apply a graph neural network to encode database schema information conditioned on the query. A new SQL encoder is then established by adopting the attention mechanism to support on-the-fly query-aware schema linking. Experimental results on real datasets show that replacing the one-hot encoding with our query representation can significantly improve the performances of existing learning-based models on several database tasks.
22
Kishore Papineni, Salim Roukos, Todd J. Ward et al. · 2001 · 21.5K citations · Full text
The Graph Neural Network Model
Franco Scarselli, M. Gori, Ah Chung Tsoi et al. · IEEE Transactions on Neural Networks · 2008 · 9.3K citations · Full text