RsGet - method of object PmAdo

Opens up the stored AdoRecordset object with defined identifier, that has been created previously by calling the RsOpen method.
RsGet(sId As String) As Object
Set oRecordset = oDb.RsGet(sId)
sId(String) Unique identifier used by the PmAdo object to store the specific AdoRecordset object.
Return Values:
If exists, then returns the stored AdoRecordset object with defined identifier. If doesn't exist, then returns the value Nothing.
ADO Record object:

Depending on the specific ADO Provider it is possible, that a single row SQL query result will not be returned as AdoRecordset object containing a single record, but as a AdoRecord object (represents the single row). Není to ale typické pro nejběžněji užívané ADO Provider. The AdoRecord object is usually returned by explicit operations, when the specific AdoRecord is returned from the existing AdoRecordset object. The AdoRecord object consists of multiple AdoField objects, similar as the AdoRecordset object. The difference is that the methods for moving the position of current record are not supported (e.g. MoveFirst). In order to keep the documntation simple, it will be referred only to the commonly returned object AdoRecordset, although in some special cases the system may also return the AdoRecord object.

Obtains the AdoRecordset object with defined unique identifier ("table1") from the PmAdo object("/TestAdoDb"). It checks if no error occurs and the method returned valid AdoRecordset object. Then all records in the AdoRecordset object are checked and the values of the first column of each record are written into the INFO system.
VBScriptSelect and copy to clipboard

Dim oDb, oRs, nLastErr2
Set oDb = pMe.Pm("/TestAdoDb")
Set oRs = oDb.RsGet("table1")

If Not oRs Is Nothing Then
  Do While Not oRs.EOF
    Pm.Debug "Field=" & oRs.Fields.Item(0)
End If
PROMOTIC 8.3.30 SCADA system documentation - MICROSYS, spol. s r.o.

Send page remarkContact responsible person
© MICROSYS, spol. s r. o.Tavičská 845/21 703 00 Ostrava-Vítkovice