File tree Expand file tree Collapse file tree 1 file changed +22
-0
lines changed Expand file tree Collapse file tree 1 file changed +22
-0
lines changed Original file line number Diff line number Diff line change 16
16
17
17
from __future__ import annotations
18
18
19
+ import itertools
19
20
import itertools
20
21
import typing
21
22
from typing import Callable , Literal , Tuple
@@ -129,6 +130,25 @@ def join_by_column(
129
130
)
130
131
}
131
132
133
+ def get_column_left (col_id ):
134
+ return lmapping [col_id ]
135
+
136
+ def get_column_right (col_id ):
137
+ return rmapping [col_id ]
138
+
139
+ lmapping = {
140
+ col_id : guid .generate_guid ()
141
+ for col_id in itertools .chain (
142
+ left .column_names , left ._hidden_ordering_column_names
143
+ )
144
+ }
145
+ rmapping = {
146
+ col_id : guid .generate_guid ()
147
+ for col_id in itertools .chain (
148
+ right .column_names , right ._hidden_ordering_column_names
149
+ )
150
+ }
151
+
132
152
def get_column_left (col_id ):
133
153
return lmapping [col_id ]
134
154
@@ -146,6 +166,8 @@ def get_column_right(col_id):
146
166
col_id_overrides = rmapping ,
147
167
)
148
168
join_conditions = [
169
+ value_to_join_key (left_table [lmapping [left_index ]])
170
+ == value_to_join_key (right_table [rmapping [right_index ]])
149
171
value_to_join_key (left_table [lmapping [left_index ]])
150
172
== value_to_join_key (right_table [rmapping [right_index ]])
151
173
for left_index , right_index in zip (left_column_ids , right_column_ids )
You can’t perform that action at this time.
0 commit comments