Lasso Soft Inc. > Home

[ string->encodeSQL92 ]

Method

[string->encodeSQL92] encodes illegal characters in SQL string literals by escaping them with a single quote mark. Helps to prevent SQL injection attacks and ensures that SQL statements only contain valid characters. This method can be used to encode values for JDBC, SQLite and most other SQL-compliant data sources, but not MySQL.

  • Syntax
'String Value'->encodeSQL92
Examples
  • Beginner

To encode illegal characters in SQL string literals:

Use the [string->encodeSQL92] method. The following example escapes illegal characters with a single quote mark.

Code

"Rhino's horn"->encodesql92

Result

Rhino''s horn

Recent Comments

No Comments found

Please note that periodically LassoSoft will go through the notes and may incorporate information from them into the documentation. Any submission here gives LassoSoft a non-exclusive license and will be made available in various formats to the Lasso community.

LassoSoft Inc. > Home

 

 

©LassoSoft Inc 2015 | Web Development by Treefrog Inc | PrivacyLegal terms and Shipping | Contact LassoSoft