public static JoinInfo genJoinInfo() {
        String sql = "select \n" +
            "   x.id \n" +
            "   ,y.id \n" +
            "  from TEST_ods x left join TEST_dim y \n" +
            "  on x.id = y.id";

//        String sql = "select \n" +
//            "   m.id as mid \n" +
//            "   ,m.bb mbb \n" +
//            "   ,s.channel as sid\n" +
//            "   ,s.name as sbb \n" +
//            "  from MyTable m left join hbaseSide s\n" +
//            "  on m.id = s.rowkey";
        SqlParser.Config config = SqlParser
            .configBuilder()
            .setLex(Lex.MYSQL)
            .build();
        SqlParser sqlParser = SqlParser.create(sql, config);
        SqlNode sqlNode = null;
        try {
            sqlNode = sqlParser.parseStmt();
        } catch (SqlParseException e) {
            throw new RuntimeException("", e);
        }

        JoinInfo joinInfo = new JoinInfo();
        joinInfo.setLeftIsSideTable(false);
        joinInfo.setRightIsSideTable(true);
        final String LEFT_TABLE_NAME = "TEST_ods";
        final String RIGHT_TABLE_NAME = "TEST_dim";
        joinInfo.setRightTableAlias(RIGHT_TABLE_NAME);
        joinInfo.setLeftTableAlias(LEFT_TABLE_NAME);
        joinInfo.setLeftTableAlias("x");
        joinInfo.setRightTableAlias("y");
        joinInfo.setLeftNode(((SqlJoin) ((SqlSelect) sqlNode).getFrom()).getLeft());
        joinInfo.setRightNode(((SqlJoin) ((SqlSelect) sqlNode).getFrom()).getRight());
        joinInfo.setCondition(((SqlJoin) ((SqlSelect) sqlNode).getFrom()).getCondition());
        joinInfo.setSelectFields(((SqlSelect) sqlNode).getSelectList());
        joinInfo.setSelectNode(((SqlSelect) sqlNode).getSelectList());
        joinInfo.setJoinType(((SqlJoin) ((SqlSelect) sqlNode).getFrom()).getJoinType());
        joinInfo.setScope("0");
        Map leftSelectField = new HashMap<String, String>();
        leftSelectField.put("name", "name");
        leftSelectField.put("id", "id");
        joinInfo.setLeftSelectFieldInfo(leftSelectField);
        Map rightSelectField = new HashMap<String, String>();
        rightSelectField.put("id", "id");
        rightSelectField.put("name", "name");
        joinInfo.setRightSelectFieldInfo(rightSelectField);
        return joinInfo;
    }
@program: flink.sql
@author: wuren
@create: 2020/07/30
rdb/rdb-side/src/test/java/com/dtstack/flink/sql/side/rdb/testutil/ArgFactory.java