Advantage database with Firedac
Hi
We have moved from RB7 using D7 and Advantage Database server via the daAds.pas plugin from RB 20, Delphi 10.3 and FireDac to connect to ADS. When opening our existing reports we get an error TdaADSQueryDataview not found. I am guessing there is something we need to change in each rtm file. Could someone give me a pointer what to look for and change please?
Thanks
Andy
We have moved from RB7 using D7 and Advantage Database server via the daAds.pas plugin from RB 20, Delphi 10.3 and FireDac to connect to ADS. When opening our existing reports we get an error TdaADSQueryDataview not found. I am guessing there is something we need to change in each rtm file. Could someone give me a pointer what to look for and change please?
Thanks
Andy
Comments
Sessions type = FirteDAC session, Database Type = Advantage, If I choose New query designer or query wizard it displays a list of empty adt filenames, for example space followed by ADT and no fields listed.
In order to convert your templates to use a different database connection, you will need to manually edit the source of each template (hopefully programmatically) to match the new dataview classes, tables, etc. See the following article on some strategies about how this should be done.
http://rbwiki.digital-metaphors.com/dade/fundamentals-dade/convert-template-bde-to-ado/
I was able to recreate the issue you had with the table names not appearing when connecting to an Advantage DB with FireDAC. There is now a patch available that solves this problem for RB 21.01.
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
We tried this today but the data part of the file is in a format I don't recognise -
How can we extract the database setitngs as text ?
Thanks
Andy
object raCodeModule1: TraCodeModule
ProgramStream = {
01060F5472614576656E7448616E646C65720B50726F6772616D4E616D65060D
4C696E6531334F6E5072696E740B50726F6772616D54797065070B747450726F
63656475726506536F75726365068D70726F636564757265204C696E6531334F
6E5072696E743B0D0A626567696E0D0A2020206966204C6F6164735B27574352
45474E4F275D203C3E202727207468656E0D0A202020096C696E6531332E7669
7369626C65203A3D20547275650D0A202020656C73650D0A202020096C696E65
31332E76697369626C65203A3D2066616C73653B0D0A656E643B0D0A0D436F6D
706F6E656E744E616D6506064C696E653133094576656E744E616D6506074F6E
The section of the template you have copied above is RAP code in a proprietary format we used for older versions of ReportBuilder. This format will be updated when you save the template again with a newer version of ReportBuilder. There is nothing here, however, that should be altered to function correctly with a new DB connection as it does not apply to the DADE QueryDataViews.
As stated in the article I posted, you will want to look for the DataModule section of the template and alter the QueryDataView class as needed (as a minimum). Then you will need to go through that section of the template and change table names, field names, property values, etc. if needed. The best way to do this is to create a simple report from scratch and compare it to the older template to see what needs to be done.
The section of the template you need to look for will look something like the following:
object daDataModule1: TdaDataModule
object FireDACQueryDataView1: TdaFireDACQueryDataView
UserName = 'Query_Orders'
Height = 298
Left = 10
NameColumnWidth = 105
SizeColumnWidth = 35
SortMode = 0
Top = 10
TypeColumnWidth = 52
Width = 242
AutoSearchTabOrder = 0
object plOrders: TppChildDBPipeline
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
Please ignore, that report had no data !