pad, vpad

Declaration

cstring* function pad(cstring S, Char(1) C ,Integer I))

varchar function vpad(varchar S, Char(1) C ,Integer I))

Description

Pad returns a string of Length I by adding characters C to the end of String S

Example Stored Procedure

CREATE PROCEDURE test_vpad(S varchar(30), C char(1),I Integer)

RETURNS (result varchar(30)) AS

BEGIN

result = vpad(S,C,I);

END!!

WISQL - calling the example stored procedure

execute procedure test_vpad("abcd","1",10);

RESULT

==============================

abcd111111

execute procedure test_vpad("abcd","1",1);

RESULT

==============================

Bad parameters in rpad