Please enable JavaScript to view this site.

Returns the query result in a relational table format.

This version of GetTable is used to perform queries without schema information.

 

GET: api/v1/<apiresource>/crud/GetTable/None/<filename>

 

<apiresource> ApiResource name. e.g. apidemo.

 

<filename> Name of the file on which the operation is performed. e.g. LK.CUSTOMERS
e.g. api/v1/apidemo/crud/GetTable/None/LK.CUSTOMERS

 

 

Parameters

 

select_clause

string

Statement fragment specifies the selection condition. For example WITH CUSTOMER = '1'

sort_clause

string

Statement fragment specifies the selection order. If there is a selection rule Linkar will execute a SSELECT, otherwise Linkar will execute a SELECT. For example BY CUSTOMER

dict_clause

string

Space-delimited list of dictionaries to read. If this list is not set, all fields are returned. For example CUSTOMER DATE ITEM. In NONE mode you may use the format LKFLDx where x is the attribute number.

row_headers

string

Include headings in first row MAINLABEL (main headings), SHORTLABEL (short label headings), and NONE (without headings).

repeat_values

boolean

Repeat common atributes in MV and SV groups.

pagination

boolean

Indicates if pagination is being used or not.

reg_page

integer

In case of pagination it indicates the page number to obtain. Must be greater than 0.

num_page

integer

In case of pagination it indicates the page number to obtain. Must be greater than 0.

custom_vars

string

This is a free text field to send in the transaction. If not empty, subroutine SUB.LK.MAIN.CONTROL.CUSTOM will be called. Add custom code to that subroutine to define special behaviours for some or all transactions.

svr_timeout

integer

This is the maximum time in seconds that the client will wait for a response. Use 0 for no timeout.

(*) Mandatory

 

 

 

Request Body

Unused

 

 

 

Responses

On all kind of responses, an ERROR tag will list all possible errors during execution of the operation. This tag includes CODE tag with the error codes and MESSAGE tag with messages of each error.

In responses of type "text/plain" (LkString MV), error codes and messages are separated by multivalue marks.

 

application/json

This image shows an example of running an operation in the LK.CUSTOMERS file.  

In order to avoid a large example, select clause has been defined with the value “WITH ID = ’10’ ID = ‘11’” and the rest of parameters have their default values.                        

 

 

Below is displayed the operation result. The complete content of the response is inside the TABLE node. In this node, the separator between fields is tab (ASCII 9) and the rows separation is vertical tab (ASCII 11).

 

{ "TABLE": "F0\tF1\tF2\tF3\u000b11\tCUSTOMER 11\tADDRESS 11\t444 - 444 - 011\u000b10\tCUSTOMER 10\tADDRESS 10\t444 - 444 - 010" }

 

 

application/xml

This image shows an example of running an operation in the LK.CUSTOMERS file.  

In order to avoid a large example, select clause has been defined with the value “WITH ID = ’10’ ID = ‘11’” and the rest of parameters have their default values.    

 

 

Below is displayed the operation result, formatted to read it more clearly.

Inside CDATA node, the separator between fields is tab (ASCII 9) and the rows separation is vertical tab (ASCII 11).

 

<GETTABLE>

<TABLE><![CDATA[F0        F1        F2        F3

11        CUSTOMER 11        ADDRESS 11        444 - 444 - 011

10        CUSTOMER 10        ADDRESS 10        444 - 444 - 010]]>

</TABLE>

</GETTABLE>

 

                                         

text/plain

This image shows an example of running an operation in the LK.CUSTOMERS file.  

In order to avoid a large example, select clause has been defined with the value “WITH ID = ’10’ ID = ‘11’” and the rest of parameters have their default values.    

This response is a chain of characters structured in sections, named "LkString".

For more information about the different tags in this response, click here.

 

 

Below is displayed the operation result, formatted to read it more clearly.

Inside CDATA node, the separator between fields is tab (ASCII 9) and the rows separation is vertical tab (ASCII 11).

 

F0        F1        F2        F3

11        CUSTOMER 11        ADDRESS 11        444 - 444 - 011

10        CUSTOMER 10        ADDRESS 10        444 - 444 - 010