Revision 5507
Added by Aaron Marcuse-Kubitza about 12 years ago
lib/sql_gen.py | ||
---|---|---|
1163 | 1163 |
|
1164 | 1164 |
# Replace out both with and without quotes |
1165 | 1165 |
expr = expr.replace(out.to_str(db), in_str) |
1166 |
expr = re.sub(r'(?<!["\'\.=\[])\b'+out.name+r'\b(?!["\'\.=\]])', in_str,
|
|
1167 |
expr) |
|
1166 |
expr = re.sub(r'(?<!["\'\.=\[])\b'+out.name+r'\b(?!["\',\.=\]])',
|
|
1167 |
in_str, expr)
|
|
1168 | 1168 |
|
1169 | 1169 |
if in_cols_found != None and expr != orig_expr: # replaced something |
1170 | 1170 |
in_cols_found.append(in_) |
Also available in: Unified diff
sql_gen.py: map_expr(): Don't replace an unquoted name when followed by ",", as it would be in an into table name for a function with multiple arguments (e.g. family in "_join_words(1=Field family, 2=Field name)")