Fix issue where reverse engineered SQL was failing for foreign tables, if it had = in the options. Fixes #4171

This commit is contained in:
Aditya Toshniwal
2019-06-10 12:15:12 +05:30
committed by Akshay Joshi
parent 8b9c50ee5c
commit 7ff85903e4
2 changed files with 4 additions and 1 deletions

View File

@@ -1192,7 +1192,9 @@ class ForeignTableView(PGChildNodeView, DataTypeReader):
if db_variables is not None:
for row in db_variables:
var_name, var_value = row.split("=")
# The value may contain equals in string, split on
# first equals only
var_name, var_value = row.split("=", 1)
var_dict = {'option': var_name, 'value': var_value}