Function: GetStamTabelRecords
This function allows you to retrieve data from a master table.
Click on the line to show the available fields of the table.
Nb. If a table has no link to the available fields, but you need these please contact KING Software.
Possible WHERE-OPERATORS are:
=
>
> =
<
<=
LIKE
Any combination of WHEREFIELDS / WHEREOPERATORS / WHEREVALUES provide an AND combination. If you want to create an OR query, then you can combine the search fields in one WHEREFIELD.
example:
WHEREFIELDS= NAME, LOCATION
WHEREOPERATORS = LIKE
WHEREVALUES =%A%
This returns all debtors / creditors / prospects where the name or location contains A.
For most master tables it is possible to use an extra TAG next to the TAGS WEREFIELDS/WHEREOPERATORS and WHEREFIELDS namely : MUTDATE_VA, in which case you can use the value from this tag to specify the date from which you want to retrieve the data.
Note 1: Als in de WHEREFIELDS/WHEREOPERATORS/WHEREVALUES-clausule meerdere velden zijn opgenomen. dan moeten deze velden worden gescheiden door een TAB character. (Char(9))
Note 2: When passing data within PHP, keep in mind that the characters such as & and> or <can not simply be passed on. Use the character data indication <! [CDATA [Test <less than]]> for this.
- MUTDATE_VA For most master tables it is possible to use an extra TAG next to the TAGS WEREFIELDS/WHEREOPERATORS and WHEREFIELDS namely : MUTDATE_VA, in which case you can use the value from this tag to specify the date from which you want to retrieve the data.
- PDF_BESTAND
This can be used for tables:
-
- ART (Products)
- Land (Countries )
- ORDKOP (Sales orders headers)
- ORDRG (Sales orders lines)
- Click here for the dutch page with available master tables.
GetStamtabelRecords(ByVal PartnerKey As String, ByVal Omgevingscode As String, ByVal SessionId As String, ByVal Selectie As DataSet, ByRef Records As DataSet, ByRef foutmelding As String) As Boolean
SOAP request:
<?xml version="1.0" encoding="utf-8"?> <soap12:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://www.w3.org/2003/05/soap-envelope"> <soap12:Body> <GetStamtabelRecords xmlns="https://cloudswitch.imuisonline.com/"> <PartnerKey>string</PartnerKey> <Omgevingscode>string</Omgevingscode> <SessionId>string</SessionId> <Selectie> <xsd:schema>schema</xsd:schema><![CDATA[zie voorbeeld]]></Selectie> <Records> <xsd:schema>schema</xsd:schema>xml</Records> <Foutmelding>string</Foutmelding> </GetStamtabelRecords> </soap12:Body> </soap12:Envelope>
Example for tag <Selection></ Select>, for retrieving data:
Please note, if in the WHERE clause of SELECTFIELDS-clause multiple fields are included, then these fields must be separated by a TAB character. (Char(9))
To sort descending a :D must be added to the ORDERBY.
<NewDataSet>
<Table1>
<TABLE>tabelnaam</TABLE>
<SELECTFIELDS>velden</SELECTFIELDS>
<WHEREFIELDS>veld</WHEREFIELDS>
<WHEREOPERATORS>operator</WHEREOPERATORS>
<WHEREVALUES>waarde</WHEREVALUES>
<MUTDATE_VA >datum</MUTDATE_VA > (Optional)
<ORDERBY>veld</ORDERBY>
<MAXRESULT>0</MAXRESULT>
<PAGESIZE>10000</PAGESIZE>
<SELECTPAGE>1</SELECTPAGE>
</Table1>
</NewDataSet>
SOAP response:
<?xml version="1.0" encoding="utf-8"?> <soap12:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://www.w3.org/2003/05/soap-envelope"> <soap12:Body> <GetStamtabelRecordsResponse xmlns="https://cloudswitch.imuisonline.com/"> <GetStamtabelRecordsResult>true</GetStamtabelRecordsResult> <Records> <xsd:schema>schema</xsd:schema>xml</Records> <Foutmelding></Foutmelding> </GetStamtabelRecordsResponse> </soap12:Body> </soap12:Envelope>
Example for retrieving a debtor:
<NewDataSet>
<Table1>
<TABLE>DEB</TABLE>
<SELECTFIELDS>NR ZKSL NAAM NAAM2 ADRES PLAATS</SELECTFIELDS>
<WHEREFIELDS>NR</WHEREFIELDS>
<WHEREOPERATORS>=</WHEREOPERATORS>
<WHEREVALUES>10000</WHEREVALUES>
<MUTDATE_VA >01-01-2016</MUTDATE_VA > (Optional)
<ORDERBY>NR</ORDERBY>
<MAXRESULT>0</MAXRESULT>
<PAGESIZE>10000</PAGESIZE>
<SELECTPAGE>1</SELECTPAGE>
</Table1>
</NewDataSet>
Example for retrieved data <records></records>
<NewDataSet>
<METADATA>
<RECORDCOUNT>1</RECORDCOUNT>
<TOTALPAGES>1</TOTALPAGES>
</METADATA>
<DATA>
<NR>10000</NR>
<ZKSL>fiets paradijs</ZKSL>
<NAAM>Multi User Informatie Systemen B.V.</NAAM>
<NAAM2>J. de Vries</NAAM2>
<ADRES>De Trompet 2880</ADRES>
<PLAATS>HEEMSKERK</PLAATS>
</DATA>
</NewDataSet>