ASP SUBSTRING FUNCTIONS

ASP SUBSTRING FUNCTIONS

Left

The left function returns the specified no of characters from the left side of the string.

syntax:

Left(string,length)

Parameter Description:

string - Required. The string in which the substring has to be find.

length - Required. The no of characters to retrieve from the given string from the left side. If the length specified is zero then empty string is returned. If the length is greater than or equal to the length of the string then the function returns the entire string.

Right 

The right function returns the specified no of characters from the right side of the string.

syntax:

Right(string,length)

Parameter Description:

string - Required. The string in which the substring has to be find.

length - Required. The no of characters to retrieve from the given string from the right side. If the length specified is zero then empty string is returned. If the length is greater than or equal to the length of the string then the function returns the entire string.

Mid

The mid function returns the specified no of characters from the given string.

syntax:

Mid(string,start,length)

Parameter Description:

string - Required. The string in which the substring has to be find.

start - Required. It is the starting position of the substring in the given string. If the starting position specified is greater than the length of the string then empty string is returned.

length - Optional. It is the no of characters to return. If not specified the function retrieves the characters till the end of the string.

Leave a Reply

You must be logged in to post a comment.


All material @ copyrighted by chrisranjana.com. If you want to link to this article you are welcome to do so. Unauthorized publication is strictly prohibited. This developer tutorial website contains articles by Php programmers , Software developers, Mysql programmers and asp c# programmers. This website also contains ajax tutorials and advanced mysql sql stored procedures and functions tutorials and sample codes.