||can I use a CDM the same way as I use a DMD?
||Fri, 25 Sep 2020 14:13:48 +1000
I have a CDM that only instantiates a database and a couple of functions
for the rest of the app modules to inherit and use..
Can I use is as a regular DMD, e.g.
SET PROC to baseSO2dev.CDM addi
oDMD = new BaseSO2devCDATAMODULE()
cSQL="truncate table energydata_temp"
This is to keep the database connectivity details into once central and
compiled file for easier maintenance and security bonus.
It seems to be working but the Help entry for custom classes says:
You can’t run a file you’ve developed in this way; it is simply a
template from which other forms, reports, or data modules can be derived.
I suspect this means that you can't double-click on them and see the
resulting rowset if a rowset is part of the CDM, but I'd like to make
sure before I hit a wall down the track...
All my database connectivity is ADO-based, so I'd like to stay away from
using a BDE alias.
A Connection Alias would work but would store the credentials as plain
text on the server while in a compiled DMD/CDM, they cannot be read
(well, let's put it this way, I have searched the DBW files for the
password and didn't find them).