TurboMagic
Members-
Content Count
242 -
Joined
-
Last visited
-
Days Won
9
Everything posted by TurboMagic
-
Ok, I'm pleased too early: when trying to perform a backup with FB 4.0 while the DB Connection is open, it fails with an I/O error because the DB file is already open. 😞 And I also found out now that the cases where it worked were because of having installed and 4.0 FB server on the same VM for using a DB tool and having forgotten to turn off the service 😞 With 2.5 embedded this wasn't a problem as far as I can remember. That would mean now, that I have to close the DB connection and close the DriverLink, then I can perform the backup and then I need to reopen the DB connection and what's more: all datasets I have, which pointed on this DB connection and which might be open at this point in time become invalid. I would have to recreate them all. Correct? Or is there a way I can perform a backup while still having an open DB connection using the embedded version of Firebird? I could understand for the Restore, but not for the Backup... And yes, the other option would be to not use Embedded but the regular client/server variant.
-
Ok, I did the Firebird 4.0 Migration now and Backup/Restore basically work again. I've got something else in im application now when restoring, but that's something on my side.
-
Starting with FB 3.0 you are wrong. The client library is named like the client/server one now, as they try to unify things.
-
Oh, really? Then I should directly try to migrate to FB 4 embedded. I guess you used embedded? As I guess I wouldn't have the issues using the server variant...
-
Here's the code used to initialize the restore component: FFBDriverLink := TFDPhysFBDriverLink.Create(nil); FFBDriverLink.VendorLib := 'D:\Projects\MyApp\Win32\Debug\Database\fbclient.dll'; FFBDriverLink.Embedded := true; FFBRestore := TFDIBRestore.Create(nil); FFBRestore.ConnectTimeout := 0; FFBRestore.Database := DatabaseFileName; FFBRestore.DriverLink := FFBDriverLink; FFBRestore.Password := c_DBPassword; FFBRestore.QueryTimeout := 2; FFBRestore.UserName := c_DBUserName; FFBRestore.Options := [roReplace]; FFBRestore.Protocol := TIBProtocol.ipLocal; FFBRestore.Verbose := true; FFBRestore.AfterExecute := OnRestoreFinishedInternal; FFBRestore.OnProgress := OnRestoreProgressInternal; FFBRestore.OnError := OnRestoreErrorInternal;
-
Delphi Code Coverage Wizard Plus V2.1 released
TurboMagic replied to TurboMagic's topic in Delphi Third-Party
Publication via GetIt is currently on hold, as the curator of it always gets virus alerts 😞 Most likely from the included exe cmd line too the wizard uses. I already generated a new version where I complied those myself. Let's see if that can be accepted. -
I'm using D11.3 and a Firebird database. I use TFDBatchMove to copy rows from one database (the old one before the update of the application) to the empty DB installed with the update. Now when that new database contains a new column declared as non Null it crashes. How to prevent this or how to deal with this?
-
TFDBatchMove with non NULL column in target table
TurboMagic replied to TurboMagic's topic in Databases
Ok, I have a solution now, thanks to Uwe's suggestion: If I use a DataSetWriter instead of a SQL one, I can assign a TFDTable component to that one, which has the TableName property and which calls OnNewRecord just fine. In that one can I check the table name and if it's one of the tables where not Null columns have been added later on, I can check these columns for 'not NULL' and assign a default value there. In my tests the DB functionality of having default values didn't work. Maybe the TFDBatchMove added NULL values itsself for these additional columns... -
TFDBatchMove with non NULL column in target table
TurboMagic replied to TurboMagic's topic in Databases
Ok, the plan with the TFDBatchMoveDataSetWriter isn't so easy. It lacks the .TableName property and it looks like I need to assign a TDataSet to that one. Seems more investigation is required. -
TFDBatchMove with non NULL column in target table
TurboMagic replied to TurboMagic's topic in Databases
Well, when I provide an SQL query for the reader as you describe I'm getting more inflexible when adding new fields to that table in comparison to only having to deal with cases where a "not NULL" for a column needs to be dealt with. Since Uwe hints that a SQLWriter will not call OnNewRecord I will try the TFDBatchMoveDataSetWriter now. If that calls this event and lets me call FieldByName it should do. -
TFDBatchMove with non NULL column in target table
TurboMagic replied to TurboMagic's topic in Databases
I tried OnNewRecord now, but it doesn't seem to get called. What am I'm doing wrong? Here I assign OnNewRecord via code, since FWriter is created at runtime: FWriter.FDDataSet.OnNewRecord := OnNewRecord; Here's the implementation of that event: procedure TDBCopy.OnNewRecord(DataSet: TDataSet); begin if (FWriter.ActualTableName.ToUpper = 'KASSE_EINSTELLUNGEN') then begin DataSet.FieldByName('DRAWBACK_CALCULATION').AsInteger := 0; end; if (FWriter.ActualTableName.ToUpper = 'KASSE_PRINTSETTINGS') then begin DataSet.FieldByName('PRINT_SMALL_BONS').AsInteger := 0; end; end; But when running FBatchMove.Execute; the breakpoint in the event is never ever called. And the way my application crashes indicates that it's actually never run. Do I need to activate something somewhere? I only assign TableNames to FReader.TableName and FWriter.TableName and then run FBatchMove.Execute; -
TFDBatchMove with non NULL column in target table
TurboMagic replied to TurboMagic's topic in Databases
Thanks for that pointer. -
Hello, this is the notice that DEC (Delphi Encryption Compendium) has a new home. The GitHub repository has been transferred to me by the previous maintainer as he no longer found the time to work on it and I was the main developer since a few years already anyway. The new URL is: https://github.com/MHumm/DelphiEncryptionCompendium This transfer also makes it a bit more likely that the V6.0 which is still in the works will be released in the near future. Best regards TurboMagic
-
I have D10.4.2 with ICS 8.65 installed (having not had any need for ICS in the recent years I only got aware of V9.0 now). I would like to read out the contents on a DNS TXT record. For this I looked at the OverbyteICSNSLookup sample application. While this can display a bunch of stuff read out from DNS I don't see where the contents of a TXT record if accessed. I don't want to parse the raw DNS answer. I guess there's some simpler way available. The only string like thing I found was AnswerName but that doesn't really sound like it.
-
How to read DNS TXT record contents?
TurboMagic replied to TurboMagic's topic in ICS - Internet Component Suite
Thanks for the info! That one works for me. My DNS is an inernal one so Google etc. don't help me... -
How to read DNS TXT record contents?
TurboMagic replied to TurboMagic's topic in ICS - Internet Component Suite
Ok, I can query this TXT record now, when I know the IP of one of our internal DNS servers. But how to find that one out? Yes, cmd.exe -> ipconfig /all would tell me, but I need to implement this internally. I tried to understand what THTTPCli does to determine that, but I failed to do so. Is there some other easier solution available to get such an IP-address? I know that I can have several connections and thus several DNS servers. but I think I can manage when I get a list of all those. -
How to read DNS TXT record contents?
TurboMagic replied to TurboMagic's topic in ICS - Internet Component Suite
Well, I won't use this for e-mail, but the data will most likely not change often, if at all. But this is good to know for first tests. -
Ah! Yes, you're right! D2009 was Generics and Anonymous methods...
-
How to read DNS TXT record contents?
TurboMagic replied to TurboMagic's topic in ICS - Internet Component Suite
Thanks, this looks like what I'm after. -
How to read DNS TXT record contents?
TurboMagic replied to TurboMagic's topic in ICS - Internet Component Suite
Ok, time to upgrade. I see. Thanks! What I learned is, that TXT records can have a name and thus I could retrieve that one with this? -
As far as I remember Win64 compiler was introduced with D2009 already.
-
Hello, I've got some good news and sort of a Christmas present: What is it? Delphi Code Coverage Wizard V2.0. A GUI to make using the CodeCoverage.exe tool easier. Oh and what please is code coverage? With code coverage one can find out whether the unit tests one has (I do hope you have some!) really cover all of your code or if you missed some scenarious. If you still are unsure how that looks like you might have a look at the screenshots provided at the bottom of the project's github page here: https://github.com/MHumm/delphi-code...ge-wizard-plus Now where to get this fine tool? https://github.com/MHumm/delphi-code...eases/tag/V2.0 Hopefully via GetIt package manager soon as well. That one currently still contains V1.1 A list of the improvements made between V1.1 and V2.0 is found on the release URL above. Now enjoy it TurboMagic
-
Delphi Code Coverage WIzard Plus V2.0 released
TurboMagic replied to TurboMagic's topic in Delphi Third-Party
Well, I'd be gratefull if somebody could grab that new version from development branch and test the new additions to find out if I understood and implemented those correctly. -
This one only exists since 10.4 or 11.x or so...
-
The issue is: CE is such a system. You are only allowed up to a certain $$$$ you make a year. But EMBT isn't MS which has more revenue streams and thus can better stay profitable even if a number of persons misuse the free version as replacement for the paid one. That's also the reason why CE only is being released months after a new major release.