Skip to content

Commit a3ed35a

Browse files
Consider STRAIGHT_JOIN as a join operator
STRAIGHT_JOIN is a MySQL-specific join operator that is used to force a join to be performed in the order of the tables specified. This is done when the user suspects that the query planner is not choosing the optimal join order. This type of control is not supported by Readyset, so we don't need to treat it differently from a regular JOIN/INNER JOIN. We already parse STRAIGHT_JOIN as a join operator, but we don't use it in the query graph. This commit fixes that. Closes: REA-5502 Closes: #1468 Release-Note-Core: Add support for STRAIGHT_JOIN as a join operator. Change-Id: Ibb145144373c32f5dbb1271bc0283fdca83a2659 Reviewed-on: https://gerrit.readyset.name/c/readyset/+/9044 Reviewed-by: Sidney Cammeresi <sac@readyset.io> Tested-by: Buildkite CI
1 parent 9477a18 commit a3ed35a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

readyset-server/src/controller/sql/query_graph.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1172,7 +1172,7 @@ pub fn to_query_graph(stmt: SelectStatement) -> ReadySetResult<QueryGraph> {
11721172
params,
11731173
}
11741174
}
1175-
JoinOperator::Join | JoinOperator::InnerJoin => {
1175+
JoinOperator::Join | JoinOperator::InnerJoin | JoinOperator::StraightJoin => {
11761176
for pred in &extra_preds {
11771177
classify_conditionals(
11781178
pred,

0 commit comments

Comments
 (0)