Promotic

Object PmaAdo (ADO database)

Description:
See: PmaAdo - Deatiled object description, PmaAdo - Practical examples

This object provides access to databases using the ADO technology. This object represents connection to one database and can contain multiple AdoRecordset objects (providing access to data in physical database tables). The PmaAdo object can be used for read/write the data from/to the physical database table and also can execute SQL statements in he connected database.
The PmaAdo object directly enables the objects and methods of the ADO technology. Especially the AdoRecordset object as a result of the SQL statement SELECT. This technology ensures that the system is as open as possible and averything that can be done using the ADO technology, can also be used in the PROMOTIC system.

No other Pma objects can be created in this object.
This object can be created in objects: PmaRoot, PmaFolder, PmaPrototype. Multiple objects of this type can be created in such objects.
The usage of the PmaAdo object requires purchase of the "PmDB" licence. When developing the application in the freeware mode PmFree, or with development environment and while testing it in runtime, this component is always functional.
This object inherits properties, methods and events of the PmaObject object.
Properties and methods of this object:
DbBeginTrans()Starts new transaction over the connected database
DbClose()Disconnection of the PmaAdo object of the database and release of all stored AdoRecordset objects
DbCommitTrans()Confirms transaction over connected database
DbConnectionParamsAdditional parameters of database connection
DbConnectionStringDatabase connection parameters
DbExecute()Executes the statement entered in the SQL language syntax
DbIsOpen()Test whether the PmaAdo object has the database connection
DbOpen()Connection of the PmaAdo object to the database
DbRollbackTrans()Cancells transaction over connected database
LastErrThe numeric error code of the result of the last executed method (property) of the PmaAdo object
LastTextErrThe text description of the last executed method (property) of the PmaAdo object
RsClose()Releases the stored AdoRecordset object with the specified identifier
RsGet()Returns the stored AdoRecordset object with the specified identifier, that has been created previously by calling the RsOpen method
RsIsOpen()Test the existence of the AdoRecordset object with the specified identifier
RsOpen()Executes the SQL query SELECT and provides the resulting data in the form of the AdoRecordset object (set of records)
Properties and methods inherited from the PmaObject object:
AddEvent()Registers a function into the specified event
GetInfo()Returns the Info object with the specified name
GetOwnedByIndex()Returns the subobject defined by its index
GetOwnedByName()Returns reference to the subobject defined by its name
GetOwnedByType()Array of references to the subobjects
GetOwnedNum()Returns number of subobjects in the object
GetPar()Reading the value of the Pma object parameter (or its parents)
GetPathName()Object name with the path to this object
GetPermission()Returns permission of corresponding operation from object
MethodsAccess to designer's methods of this object
NameObject name (without the path)
ParentReturns reference to the parent Pma object
Pm()Returns reference to the Pma object or to its implementation subobject
RemoveEvent()Unregisters the function in the specified event
RootReturns reference to the root application object PmaRoot
Events inherited from the PmaObject object:
onStartIs triggered for each object in runtime only once at the beginning
onStopIs triggered for each Pma object in runtime only once at the stop of the application
Configuration tabs:
ObjectGeneral information about the object
EventsDefinition of object events algorithms
ADOBasic settings for database access via the ADO
MethodsDefinition of designer's method of the object
Related objects:
AdoField(ADO Field) The ADO Field object contains the column information
AdoRecord(ADO Record) The ADO Record object represents a single record
AdoRecordset(ADO Recordset) The ADO Recordset object represents a set of records

History:
Pm9.00.00: Object name changed: PmAdo -> PmaAdo
Pm8.03.22: Generalization of methods DbOpen, DbExecute, RsOpen, DbBeginTrans, DbCommitTrans, DbRollbackTrans.
If you enter the parameter "return:map;", then the methods return moredetailed information regarding the results of method callings.
Pm8.03.09: new methods for transactions support: DbBeginTrans, DbCommitTrans and DbRollbackTrans.
Pm8.01.03: Some methods of the AdoRecordset object did not return the confirmation of completion/failure flag. Therefore the PROMOTIC system adds properties (Pm_LastErr and Pm_LastTextErr) into this object, that can be used for obtaining such confirmation.
Pm8.01.00: Created
PROMOTIC 9.0.27 SCADA system documentation MICROSYS, spol. s r.o.

Send page remarkContact responsible person
© MICROSYS, spol. s r.o.