mirror of
https://github.com/HeidiSQL/HeidiSQL.git
synced 2026-03-13 09:24:25 +08:00
Revert r5136, which removes support for single quotes in database names again, to fix a new bug when finding the right PG database name in a query like SET search_path TO E'information_schema', E'public'. See http://www.heidisql.com/forum.php?t=22799
This commit is contained in:
@@ -3070,7 +3070,7 @@ begin
|
||||
EscapeFunction := 'E'
|
||||
else
|
||||
EscapeFunction := '';
|
||||
rx.Expression := StringReplace(rx.Expression, '%s', EscapeFunction+'['+Quotes+']?(.+)['+Quotes+']?', [rfReplaceAll]);
|
||||
rx.Expression := StringReplace(rx.Expression, '%s', EscapeFunction+'['+Quotes+']?([^'+Quotes+']+)['+Quotes+']*', [rfReplaceAll]);
|
||||
if rx.Exec(SQL) then begin
|
||||
FDatabase := Trim(rx.Match[1]);
|
||||
FDatabase := DeQuoteIdent(FDatabase);
|
||||
|
||||
Reference in New Issue
Block a user