SelectWithUnionQuery (children 1)
 ExpressionList (children 1)
  SelectQuery (children 3)
   ExpressionList (children 4)
    WithElement (children 1)
     Subquery (children 1)
      SelectWithUnionQuery (children 1)
       ExpressionList (children 4)
        SelectQuery (children 6)
         ExpressionList (children 1)
          Identifier repo_name
         TablesInSelectQuery (children 1)
          TablesInSelectQueryElement (children 1)
           TableExpression (children 1)
            TableIdentifier github_events
         Function and (children 1)
          ExpressionList (children 2)
           Function equals (children 1)
            ExpressionList (children 2)
             Identifier event_type
             Literal \'WatchEvent\'
           Function equals (children 1)
            ExpressionList (children 2)
             Function toDate (children 1)
              ExpressionList (children 1)
               Identifier created_at
             Function minus (children 1)
              ExpressionList (children 2)
               Function today (children 1)
                ExpressionList
               Literal UInt64_1
         ExpressionList (children 1)
          Identifier repo_name
         ExpressionList (children 1)
          OrderByElement (children 1)
           Function count (children 1)
            ExpressionList
         Literal UInt64_100
        SelectQuery (children 6)
         ExpressionList (children 1)
          Identifier repo_name
         TablesInSelectQuery (children 1)
          TablesInSelectQueryElement (children 1)
           TableExpression (children 1)
            TableIdentifier github_events
         Function and (children 1)
          ExpressionList (children 2)
           Function equals (children 1)
            ExpressionList (children 2)
             Identifier event_type
             Literal \'WatchEvent\'
           Function equals (children 1)
            ExpressionList (children 2)
             Function toMonday (children 1)
              ExpressionList (children 1)
               Identifier created_at
             Function toMonday (children 1)
              ExpressionList (children 1)
               Function minus (children 1)
                ExpressionList (children 2)
                 Function today (children 1)
                  ExpressionList
                 Function toIntervalWeek (children 1)
                  ExpressionList (children 1)
                   Literal UInt64_1
         ExpressionList (children 1)
          Identifier repo_name
         ExpressionList (children 1)
          OrderByElement (children 1)
           Function count (children 1)
            ExpressionList
         Literal UInt64_100
        SelectQuery (children 6)
         ExpressionList (children 1)
          Identifier repo_name
         TablesInSelectQuery (children 1)
          TablesInSelectQueryElement (children 1)
           TableExpression (children 1)
            TableIdentifier github_events
         Function and (children 1)
          ExpressionList (children 2)
           Function equals (children 1)
            ExpressionList (children 2)
             Identifier event_type
             Literal \'WatchEvent\'
           Function equals (children 1)
            ExpressionList (children 2)
             Function toStartOfMonth (children 1)
              ExpressionList (children 1)
               Identifier created_at
             Function minus (children 1)
              ExpressionList (children 2)
               Function toStartOfMonth (children 1)
                ExpressionList (children 1)
                 Function today (children 1)
                  ExpressionList
               Function toIntervalMonth (children 1)
                ExpressionList (children 1)
                 Literal UInt64_1
         ExpressionList (children 1)
          Identifier repo_name
         ExpressionList (children 1)
          OrderByElement (children 1)
           Function count (children 1)
            ExpressionList
         Literal UInt64_100
        SelectQuery (children 6)
         ExpressionList (children 1)
          Identifier repo_name
         TablesInSelectQuery (children 1)
          TablesInSelectQueryElement (children 1)
           TableExpression (children 1)
            TableIdentifier github_events
         Function and (children 1)
          ExpressionList (children 2)
           Function equals (children 1)
            ExpressionList (children 2)
             Identifier event_type
             Literal \'WatchEvent\'
           Function equals (children 1)
            ExpressionList (children 2)
             Function toYear (children 1)
              ExpressionList (children 1)
               Identifier created_at
             Function minus (children 1)
              ExpressionList (children 2)
               Function toYear (children 1)
                ExpressionList (children 1)
                 Function today (children 1)
                  ExpressionList
               Literal UInt64_1
         ExpressionList (children 1)
          Identifier repo_name
         ExpressionList (children 1)
          OrderByElement (children 1)
           Function count (children 1)
            ExpressionList
         Literal UInt64_100
    WithElement (children 1)
     Subquery (children 1)
      SelectWithUnionQuery (children 1)
       ExpressionList (children 1)
        SelectQuery (children 5)
         ExpressionList (children 3)
          Identifier repo_name
          Function count (alias count_last_day) (children 1)
           ExpressionList
          Function plus (alias position_last_day) (children 1)
           ExpressionList (children 2)
            Function rowNumberInAllBlocks (children 1)
             ExpressionList
            Literal UInt64_1
         TablesInSelectQuery (children 1)
          TablesInSelectQueryElement (children 1)
           TableExpression (children 1)
            TableIdentifier github_events
         Function and (children 1)
          ExpressionList (children 2)
           Function in (children 1)
            ExpressionList (children 2)
             Identifier repo_name
             Subquery (children 1)
              SelectWithUnionQuery (children 1)
               ExpressionList (children 1)
                SelectQuery (children 2)
                 ExpressionList (children 1)
                  Identifier repo_name
                 TablesInSelectQuery (children 1)
                  TablesInSelectQueryElement (children 1)
                   TableExpression (children 1)
                    TableIdentifier top_repos
           Function equals (children 1)
            ExpressionList (children 2)
             Function toDate (children 1)
              ExpressionList (children 1)
               Identifier created_at
             Function minus (children 1)
              ExpressionList (children 2)
               Function today (children 1)
                ExpressionList
               Literal UInt64_1
         ExpressionList (children 1)
          Identifier repo_name
         ExpressionList (children 1)
          OrderByElement (children 1)
           Identifier count_last_day
    WithElement (children 1)
     Subquery (children 1)
      SelectWithUnionQuery (children 1)
       ExpressionList (children 1)
        SelectQuery (children 5)
         ExpressionList (children 3)
          Identifier repo_name
          Function count (alias count_last_week) (children 1)
           ExpressionList
          Function plus (alias position_last_week) (children 1)
           ExpressionList (children 2)
            Function rowNumberInAllBlocks (children 1)
             ExpressionList
            Literal UInt64_1
         TablesInSelectQuery (children 1)
          TablesInSelectQueryElement (children 1)
           TableExpression (children 1)
            TableIdentifier github_events
         Function and (children 1)
          ExpressionList (children 2)
           Function in (children 1)
            ExpressionList (children 2)
             Identifier repo_name
             Subquery (children 1)
              SelectWithUnionQuery (children 1)
               ExpressionList (children 1)
                SelectQuery (children 2)
                 ExpressionList (children 1)
                  Identifier repo_name
                 TablesInSelectQuery (children 1)
                  TablesInSelectQueryElement (children 1)
                   TableExpression (children 1)
                    TableIdentifier top_repos
           Function equals (children 1)
            ExpressionList (children 2)
             Function toMonday (children 1)
              ExpressionList (children 1)
               Identifier created_at
             Function minus (children 1)
              ExpressionList (children 2)
               Function toMonday (children 1)
                ExpressionList (children 1)
                 Function today (children 1)
                  ExpressionList
               Function toIntervalWeek (children 1)
                ExpressionList (children 1)
                 Literal UInt64_1
         ExpressionList (children 1)
          Identifier repo_name
         ExpressionList (children 1)
          OrderByElement (children 1)
           Identifier count_last_week
    WithElement (children 1)
     Subquery (children 1)
      SelectWithUnionQuery (children 1)
       ExpressionList (children 1)
        SelectQuery (children 5)
         ExpressionList (children 3)
          Identifier repo_name
          Function count (alias count_last_month) (children 1)
           ExpressionList
          Function plus (alias position_last_month) (children 1)
           ExpressionList (children 2)
            Function rowNumberInAllBlocks (children 1)
             ExpressionList
            Literal UInt64_1
         TablesInSelectQuery (children 1)
          TablesInSelectQueryElement (children 1)
           TableExpression (children 1)
            TableIdentifier github_events
         Function and (children 1)
          ExpressionList (children 2)
           Function in (children 1)
            ExpressionList (children 2)
             Identifier repo_name
             Subquery (children 1)
              SelectWithUnionQuery (children 1)
               ExpressionList (children 1)
                SelectQuery (children 2)
                 ExpressionList (children 1)
                  Identifier repo_name
                 TablesInSelectQuery (children 1)
                  TablesInSelectQueryElement (children 1)
                   TableExpression (children 1)
                    TableIdentifier top_repos
           Function equals (children 1)
            ExpressionList (children 2)
             Function toStartOfMonth (children 1)
              ExpressionList (children 1)
               Identifier created_at
             Function minus (children 1)
              ExpressionList (children 2)
               Function toStartOfMonth (children 1)
                ExpressionList (children 1)
                 Function today (children 1)
                  ExpressionList
               Function toIntervalMonth (children 1)
                ExpressionList (children 1)
                 Literal UInt64_1
         ExpressionList (children 1)
          Identifier repo_name
         ExpressionList (children 1)
          OrderByElement (children 1)
           Identifier count_last_month
   ExpressionList (children 2)
    Identifier d.repo_name
    ColumnsRegexpMatcher
   TablesInSelectQuery (children 3)
    TablesInSelectQueryElement (children 1)
     TableExpression (children 1)
      TableIdentifier last_day (alias d)
    TablesInSelectQueryElement (children 2)
     TableExpression (children 1)
      TableIdentifier last_week (alias w)
     TableJoin (children 1)
      Function equals (children 1)
       ExpressionList (children 2)
        Identifier d.repo_name
        Identifier w.repo_name
    TablesInSelectQueryElement (children 2)
     TableExpression (children 1)
      TableIdentifier last_month (alias m)
     TableJoin (children 1)
      Function equals (children 1)
       ExpressionList (children 2)
        Identifier d.repo_name
        Identifier m.repo_name
