SQLData Systems, Inc.
Home | Products | Services | Documents | Support

SQLData  Script Language Function Reference


General Functions

Function :

Description:

Parameters:

Return :

Remark:


Function :

max(P1, P2);

Description:

The function returns the maximum value of P1 and P2.

Parameters:

P1 and P2 are both numeric values.

Return :

The maximum value of P1 and P2

Remark:


Function :

Min(P1, P2)

Description:

The function returns the minimum value of P1 and P2.

Parameters:

P1 and P2 are both numeric values.

Return :

The maximum value of P1 and P2

Remark:


Function :

Round(P1);

Description:

Round the given numeric value to the nearest integer.

Parameters:

P1 is a numeric value.

Return :

The nearest integer.

Remark:


Function :

strcpy(P1, P2)

Description:

Copy string P2 to P1.

Parameters:

P2 and P1 must both be strings.

Return :

The result string.

Remark:


Function :

strcat(P1, P2);

Description:

Concatenate string P2 to P1.

Parameters:

P1 and P2 must both be strings.

Return :

The concatenated string.

Remark:


Function :

strcmp(P1, P2);

Description:

Compare string p1 with p2.

Parameters:

P1 and P2 must be strings.

Return :

<0 : if P1<P2

=0 : if P1=P2

>0 : if P1>P2

Remark:

Socket Functions

Function :

Print(P1);

Description:

Write a string to the client browser through a socket.

Parameters:

P1 is the string to be sent.

Return :

The number of byte sent.

Remark:

You can use this function to create dynamic HTML pages, or construct component in a HTML page.

Database functions

Function :

OpenQuery(P1);

Description:

Open a query statement for processing. You must open a query before retrieving information from the result set.

Parameters:

P1 is a string that contain the SQL query statement

Return :

1 : if the query is successfully opened.

Remark:


Function :

CloseQuery();

Description:

Close the currently opened query. The language processor releases all resources allocated for the query. The processor will close the current query at end of the script automatically.

Parameters:

None.

Return :

None.

Remark:


Function :

Fetch();

Description:

Fetch a group of records from the opened query, and position the cursor to the next record to be fetched.

Parameters:

None

Return :

The number of records fetched.

Remark:

You normally need to fetch the records before accessing its values using GetRecord or GetFieldValue.


Function :

GetRecord(P1);

Description:

Get a record from the current fetched row set.

Parameters:

P1 is the row number in the row set starting from 0.

Return :

The record string. The string is formatted properly for screen display.

Remark:


Function :

GetHeader()

Description:

Get a string that contains all field names.

Parameters:

None

Return :

A formatted string that contains all field names start from field 0 to field n.

Remark:


Function :

GetFieldName(P1);

Description:

Get the name of the specified field.

Parameters:

P1 is a integer that represent the field number.

Return :

The field name.

Remark:


Function :

GetFieldValue(P1, P2);

Description:

Get a field value in the current fetched row set.

Parameters:

P1 : The row number in the result set, starting from 0.

P2 : The field number .

Return :

Field Value.

Remark:


Download | Purchase | ContactFeedback


Send mail to  info2-at-sqldata-dot-com with questions or comments about this web site.
Copyright 2008-2010 SQLData Systems, Inc.
Last modified: July 10, 2010