Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Unexpected behavior. What am I missing ?
#3
I have uploaded a new demo which uses ADO DB. It is SA (Indy) but it makes no difference if you use SA Http.sys.

Also, the Coinitialization error message is fixed setting ServerController's ComInitialization property (you can set it to ciNormal).

The demo is here:

https://github.com/Atozed/IntraWeb/tree/...WADODBDemo

Is is very simple but it shows some important concepts used for all IW DB applications, regardless of DB and engine used to connect to it.

Most important concepts are:

- Where to put the connection
- Where to put the DataSet objects (queries, tables, etc.)
- How to use these objects from the visual containers (the form where you have visual controls)

In this example:

- Connection is put into the user session object, meaning that each user has an exclusive DB connection. This works well if you have a limited number of simultaneous users
- DataSet objects (Queries) are put into DataModules which are owned by forms. I *personally* follow a very strict design which is: each form has its own DataModule (I also have some shared DataModules which can also be used by several forms). This design has proven to be efficient and much easier to maintain in the long run.
Reply


Messages In This Thread
RE: Unexpected behavior. What am I missing ? - by Alexandre Machado - 07-21-2019, 11:14 AM

Forum Jump:


Users browsing this thread: 1 Guest(s)