wwUtils::FlattenSql

Flatten a SQL command that contains CHR(13) or CHR(10) characters into a single line by stripping out the CR/LF values and replacing them with a space.

Useful in code so you can write SQL expressions using multi-line SQL between TEXT and ENDTEXT.

For example:

TEXT TO lcSql NOSHOW
SELECT id, title, description
    FROM albums
    ORDER BY title
ENDTEXT

lcSql = FlattenSql(lcSql)

&lcSql   && works
o.wwUtils.FlattenSql(lcSql)

Parameters

lcSql


See also:

Class wwUtils

© West Wind Technologies, 1996-2018 • Updated: 02/08/16
Comment or report problem with topic