mirror of
https://github.com/HeidiSQL/HeidiSQL.git
synced 2025-08-14 10:02:10 +08:00
Add call to Query() in SetDatabase() after removing it accidentally in previous commit. See http://www.heidisql.com/forum.php?t=15536
This commit is contained in:
@ -2586,8 +2586,6 @@ end;
|
|||||||
Set "Database" property and select that db if connected
|
Set "Database" property and select that db if connected
|
||||||
}
|
}
|
||||||
procedure TDBConnection.SetDatabase(Value: String);
|
procedure TDBConnection.SetDatabase(Value: String);
|
||||||
var
|
|
||||||
SQL: String;
|
|
||||||
begin
|
begin
|
||||||
Log(lcDebug, 'SetDatabase('+Value+'), FDatabase: '+FDatabase);
|
Log(lcDebug, 'SetDatabase('+Value+'), FDatabase: '+FDatabase);
|
||||||
if Value <> FDatabase then begin
|
if Value <> FDatabase then begin
|
||||||
@ -2597,9 +2595,10 @@ begin
|
|||||||
FOnDatabaseChanged(Self, Value);
|
FOnDatabaseChanged(Self, Value);
|
||||||
end else begin
|
end else begin
|
||||||
if FParameters.NetTypeGroup = ngPgSQL then
|
if FParameters.NetTypeGroup = ngPgSQL then
|
||||||
SQL := Format(GetSQLSpecifity(spUSEQuery), [EscapeString(Value)])
|
Value := EscapeString(Value)
|
||||||
else
|
else
|
||||||
SQL := Format(GetSQLSpecifity(spUSEQuery), [QuoteIdent(Value)])
|
Value := QuoteIdent(Value);
|
||||||
|
Query(Format(GetSQLSpecifity(spUSEQuery), [Value]), False);
|
||||||
end;
|
end;
|
||||||
SetObjectNamesInSelectedDB;
|
SetObjectNamesInSelectedDB;
|
||||||
end;
|
end;
|
||||||
|
Reference in New Issue
Block a user