Home | About SQeeL | Document | DownLoad | Mail Japanese
Home > Document > SQeeL Reference
A B C D E F G H I J L M N O P R S T U X Y  

T

  • Built-in variable
  • Built-in function
  • TIME
    Description
    Current Time (HH:MM:SS)
    Read / Write
    r
    Type
    string
    initial value
    undefined
    Topへ
    TRACE
    Description
    Specify a trace level to control information output to a log at execution.
    Specify any number from 0 to 6. Larger number outputs more detailed information.
    If you want to use this function within eval (including ${}), you need to be aware of the following:
    Trace level automatically decreases by 1 in eval. If TRACE is referred to, return value will be a value minus 1.
    Even though the trace level is changed in eval, the original level is still effective unless it goes out of eval.
    Read / Write
    rw
    Type
    number
    initial value
    1
    See Also
    Requirements
    dboralib.slb
    Topへ
    TRACEOUT
    Description
    Destination log file
    Read / Write
    rw
    Type
    string
    initial value
    eellog.txt
    See Also
    Requirements
    dboralib.slb
    Topへ
    TRUE
    Description
    Boolean value (TRUE)
    Read / Write
    r
    Type
    number
    initial value
    1
    Topへ
    to_char()
    Description
    Converts a given number to a string with a specified format
    The following are format elements for the to_char function
    9 : Outputs value with the specified number of digits. If there is no number, it returns blank space.
    0 : Outputs value with the specified number of digits. It there is no number, it returns a zero.
    . : Outputs a decimal point, which is a period (.) in the specified position
    , : Outputs a comma (,) in the specified position
    s : Outputs the value with plus sign (+) or minus sign (-). If it (S) is specified in the first position of a number format model, it outputs the value with a leading sign.
    If it's specified in the last position, it outputs the value with a trailing sign.
    mi : If the value is negative, it outputs negative value with a trailing minus sign (-)
    pr : If the value is negative, it outputs negative value in
    eeee : Outputs number with fixed‐point part and two digit exponent part. Before 'e', it outputs fixed-point part. After 'e', it outputs plus (+) or minus (-) sign and exponential part.
    Syntax
    ret = to_char(num,format)
    Parameters
    num:Numerical value
    format:Format
    Return Value
    NULL:Fail or converted character string
    string:Converted character string
    System Return Value
    ERROR
    0Success
    1Argument error
    Example
    //[result example]
    //
    // input number : 123456.07
    //    +123,456.070
    //
    
    run()
    exit
    
    function run()
    
    	local input_num
    	local output_num
    
    	input_num = getopt('input number : ')
    
    	output_num = to_char(input_num, 's999,999,990.000')
    
    	print(output_num, stdout)
    
    endfunction
    
    Topへ
    translate()
    Description
    Replace ""search_string"" in ""string"" with ""replacement_string
    If ""search_string"" in ""string"" is not found, it is not replaced.
    If search_string contains character strings more than replacement_string and if remaining character strings in search_string is found within string, these character strings are deleted and returned.
    Syntax
    ret = translate(string,search_string,replacement_string)
    Parameters
    string:Character string to be converted
    search_string:Character string containing a letter to be converted
    replacement_string:Character string containing a converted letter corresponding to from
    Return Value
    string:Converted character string
    System Return Value
    ERROR
    0Success
    1Argument error
    Example
    //[result example]
    // 1:ABCDEFG@****
    // 2:
    //
    
    run()
    exit
    
    function run()
    	local a = 'ABCDEFG 1234'
    	local b = ' 0123456789'
    	local c = '1122334455'
    	print(translate(a, b, '@**********'))
    	print(translate(c, b, ''))
    
    
    endfunction
    
    
    Topへ

    © Insight Technology, Inc. 1996-2003 All Rights Reserved.