ConnectString: Input<>Generated

Discussion of open issues, suggestions and bugs regarding UniDAC (Universal Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
FredS
Posts: 272
Joined: Mon 10 Nov 2014 17:52

ConnectString: Input<>Generated

Post by FredS » Sun 12 Dec 2021 16:14

In v9.1.1 you add a port number where there shouldn't be one.

Code: Select all

      Assert(DM.Con.Port.IsZero, 'Port Not Zero');
      DM.Con.ConnectString := AConnectString;
      Assert(AConnectString.Equals(DM.Con.ConnectString), 'ConnectString: Input<>Generated: %s <>  %s'.ToFmt([LF + SPACE + AConnectString, LF + SPACE + DM.Con.ConnectString]));

Code: Select all

EAssertionFailed: ConnectString: Input<>Generated: 
 Provider Name=SQL Server;Provider=MSOLEDBSQL.1;Data Source=MY-PC;Initial Catalog=PA;Force Create Database=False;User ID=sa;Password=Masterkey1;IP Version=ivIPBoth;Login Prompt=False;Pooling=True;Min Pool Size=4 <>  
 Provider Name=SQL Server;Provider=MSOLEDBSQL.1;Data Source=MY-PC;Initial Catalog=PA;Force Create Database=False;Port=3050;User ID=sa;Password=Masterkey1;IP Version=ivIPBoth;Login Prompt=False;Pooling=True;Min Pool Size=4 (D:\My Projects\Permissions Audit\Source\GUI\ThreadModule.pas, line 804) ($2D33F96) ($2D33F96) ($A399FC)
You guys need help testing, how can this leave your shop?
More important how do I bill you for time spent?

FredS
Posts: 272
Joined: Mon 10 Nov 2014 17:52

Re: ConnectString: Input<>Generated

Post by FredS » Sun 12 Dec 2021 17:48

This is a Datamodule with a TUniConnection component on it. It is created as a TTask.

The TUniConnection has a connection string which was used for design time work many UniDAC version ago..
Its provider is set to Interbase, when I clear the ConnectionString then all is cleared but the ConnectionString suddenly shows 'Port = 3050' even though no port was ever set..

Stellar
Devart Team
Posts: 496
Joined: Tue 03 Oct 2017 11:00

Re: ConnectString: Input<>Generated

Post by Stellar » Mon 13 Dec 2021 11:22

Hi,
Thanks for your request.

We've reproduced the issue and started to investigate possible causes of the described behavior.
We will let you know the results as soon as we get them.

Best regards,
Sergey

FredS
Posts: 272
Joined: Mon 10 Nov 2014 17:52

Re: ConnectString: Input<>Generated

Post by FredS » Mon 20 Dec 2021 19:22

While you are at it have a look at Pooling Options. Those are still in the ConnectString even if Pooling is OFF..

Stellar
Devart Team
Posts: 496
Joined: Tue 03 Oct 2017 11:00

Re: ConnectString: Input<>Generated

Post by Stellar » Thu 13 Jan 2022 15:55

Hi Fred,

Please note that if a connection parameter has been changed and it needs to be added to the connection string, then it will be added regardless of the values set for other parameters.

If you want parameters not to be added to the connection string, then set them to their default values.

Should you have any questions, do not hesitate to ask!
Best regards,
Sergey,

Stellar
Devart Team
Posts: 496
Joined: Tue 03 Oct 2017 11:00

Re: ConnectString: Input<>Generated

Post by Stellar » Thu 01 Sep 2022 07:48

Hi Fred,

Please be informed, that we have added a reset of parameters to default values when changing the provider.
These changes are included in the latest version of UniDAC 9.2.1.

Best regards,
Sergey

lisapurnellsw
Posts: 1
Joined: Wed 05 Oct 2022 07:46

Re: ConnectString: Input<>Generated

Post by lisapurnellsw » Wed 05 Oct 2022 07:48

You can add coloring for each server connection. paper io

Post Reply