select  
  nullif(subq_0.c1,
    subq_1.c0) as c0, 
  subq_1.c1 as c1
from 
  (select  
          SESSION_USER() as c0, 
          ref_0.v6 as c1
        from 
          test.table42 as ref_0
            inner join test.table88 as ref_1
            on (ref_0.v0 = ref_1.v0 )
        where (1) 
          or ((0) 
            and ((EXISTS (
                select  
                    ref_2.v30 as c0, 
                    ref_0.v0 as c1, 
                    ref_2.v67 as c2, 
                    ref_1.v49 as c3, 
                    ref_2.v72 as c4, 
                    ref_1.v25 as c5, 
                    ref_0.v1 as c6, 
                    ref_1.v34 as c7, 
                    ref_1.v27 as c8, 
                    ref_1.v1 as c9, 
                    ref_2.v46 as c10, 
                    ref_2.v22 as c11
                  from 
                    test.table51 as ref_2
                  where ((EXISTS (
                        select  
                            (select v22 from test.table85)
                               as c0, 
                            ref_1.v25 as c1
                          from 
                            test.table7 as ref_3
                          where ((ref_2.v31 is not NULL) 
                              and (0)) 
                            or (1))) 
                      and ((0) 
                        and (1))) 
                    and (1))) 
              or ((ref_1.v23 is not NULL) 
                or (1))))) as subq_0
    left join (select  
          ref_5.v22 as c0, 
          ref_8.v53 as c1
        from 
          test.table42 as ref_4
              inner join test.table51 as ref_5
              on ((1) 
                  and (EXISTS (
                    select  
                        ref_6.v0 as c0, 
                        ref_4.v2 as c1, 
                        ref_5.v59 as c2, 
                        ref_4.v3 as c3, 
                        ref_5.v4 as c4, 
                        ref_6.v2 as c5, 
                        ref_5.v5 as c6, 
                        ref_6.v1 as c7, 
                        ref_6.v2 as c8, 
                        ref_6.v1 as c9, 
                        ref_5.v62 as c10, 
                        ref_5.v31 as c11, 
                        ref_5.v58 as c12
                      from 
                        test.table33 as ref_6
                      where (EXISTS (
                          select  
                              ref_7.v2 as c0
                            from 
                              test.table29 as ref_7
                            where 0)) 
                        and (1))))
            inner join test.table84 as ref_8
            on (ref_5.v32 = ref_8.v0 )
        where 0) as subq_1
    on (((subq_1.c0 is not NULL) 
          and (((EXISTS (
                select  
                    subq_0.c0 as c0
                  from 
                    test.table87 as ref_9
                  where 1)) 
              and ((((0) 
                    or (0)) 
                  and (EXISTS (
                    select  
                        subq_0.c0 as c0, 
                        ref_10.v2 as c1, 
                        subq_0.c0 as c2, 
                        subq_1.c1 as c3, 
                        subq_1.c1 as c4, 
                        subq_0.c1 as c5, 
                        subq_0.c1 as c6, 
                        subq_1.c0 as c7, 
                        ref_10.v0 as c8
                      from 
                        test.table13 as ref_10
                      where (subq_1.c1 is not NULL) 
                        or (((0) 
                            and ((((0) 
                                  or ((0) 
                                    and ((1) 
                                      and (subq_0.c0 is not NULL)))) 
                                and (1)) 
                              or ((1) 
                                or (EXISTS (
                                  select  
                                      ref_10.v3 as c0, 
                                      subq_0.c1 as c1, 
                                      subq_1.c1 as c2, 
                                      subq_1.c1 as c3
                                    from 
                                      test.table42 as ref_11
                                    where 0))))) 
                          and (subq_0.c1 is not NULL))))) 
                or (1))) 
            and (((0) 
                or (subq_0.c1 is not NULL)) 
              and (((((1) 
                      and (((((0) 
                              and ((0) 
                                and ((subq_0.c1 is NULL) 
                                  or (0)))) 
                            or (1)) 
                          or (subq_1.c1 is not NULL)) 
                        or (subq_0.c1 is NULL))) 
                    and (0)) 
                  or (((((EXISTS (
                            select  
                                subq_0.c0 as c0, 
                                subq_0.c0 as c1, 
                                (select v2 from test.table7)
                                   as c2
                              from 
                                test.table88 as ref_12
                              where (((0) 
                                    and ((subq_1.c1 is NULL) 
                                      or (EXISTS (
                                        select  
                                            subq_0.c0 as c0, 
                                            subq_0.c0 as c1, 
                                            subq_1.c0 as c2
                                          from 
                                            test.table85 as ref_13
                                          where 0)))) 
                                  and ((subq_1.c0 is NULL) 
                                    and (EXISTS (
                                      select  
                                          subq_1.c0 as c0, 
                                          subq_0.c0 as c1, 
                                          subq_1.c0 as c2, 
                                          subq_0.c0 as c3, 
                                          62 as c4, 
                                          ref_14.v0 as c5, 
                                          ref_14.v0 as c6, 
                                          ref_12.v56 as c7, 
                                          ref_14.v2 as c8, 
                                          ref_14.v1 as c9, 
                                          ref_12.v33 as c10, 
                                          subq_1.c0 as c11, 
                                          subq_0.c0 as c12, 
                                          ref_14.v0 as c13, 
                                          ref_14.v3 as c14, 
                                          subq_1.c0 as c15
                                        from 
                                          test.table13 as ref_14
                                        where 1)))) 
                                and (0))) 
                          and (EXISTS (
                            select  
                                subq_1.c1 as c0, 
                                subq_0.c1 as c1, 
                                subq_0.c1 as c2, 
                                subq_0.c1 as c3, 
                                ref_15.v5 as c4
                              from 
                                test.table42 as ref_15
                              where (EXISTS (
                                  select  
                                      subq_0.c0 as c0, 
                                      subq_0.c0 as c1, 
                                      ref_16.v1 as c2, 
                                      ref_15.v4 as c3, 
                                      ref_16.v31 as c4
                                    from 
                                      test.table84 as ref_16
                                    where ref_15.v0 is not NULL)) 
                                and (ref_15.v3 is NULL)))) 
                        and ((EXISTS (
                            select  
                                subq_0.c0 as c0, 
                                subq_1.c1 as c1
                              from 
                                test.table35 as ref_17
                              where (ref_17.v3 is not NULL) 
                                and (subq_0.c0 is NULL))) 
                          and (((1) 
                              and (0)) 
                            or ((1) 
                              and ((subq_0.c0 is NULL) 
                                and (1)))))) 
                      or (((((0) 
                              or (subq_0.c1 is NULL)) 
                            or (0)) 
                          or (subq_0.c0 is NULL)) 
                        or ((0) 
                          or (((0) 
                              and (subq_0.c0 is NULL)) 
                            or (0))))) 
                    or (EXISTS (
                      select  
                          subq_1.c1 as c0, 
                          subq_0.c1 as c1, 
                          subq_0.c1 as c2, 
                          subq_1.c0 as c3, 
                          ref_18.v1 as c4, 
                          subq_1.c1 as c5, 
                          subq_1.c1 as c6, 
                          ref_18.v1 as c7, 
                          subq_0.c0 as c8, 
                          subq_0.c0 as c9, 
                          subq_1.c1 as c10, 
                          ref_18.v4 as c11
                        from 
                          test.table29 as ref_18
                        where ref_18.v1 is not NULL)))) 
                or (0))))) 
        and (subq_1.c0 is not NULL))
where 1;