Consultor Eletrônico



Kbase P81325: Preceding spaces in the database record is being truncated when outputting to the web page using {&O
Autor   Progress Software Corporation - Progress
Acesso   Público
Publicação   07/09/2004
Status: Unverified

FACT(s) (Environment):

WebSpeed 3.1x

SYMPTOM(s):

Preceding spaces in the database record is being truncated when outputting to the web page using {&OUT} statement

Using <PRE> tag before and after the database field name.

The database record has the data with 10 preceding spaces as "      test" without the double quote

CAUSE:

The cause is unknown as to why the preceding spaces are being truncated but it should not when used the <PRE> tag.  A test was performed by entering data in the sports database in the state table and it worked as expected.  The preceding spaces was not truncated but the trailing spaces was truncated.

FIX:


The following code was tested in the WebSpeed workshop's scripting lab using sports database:

/******************************************/

FIND state where state = "TS" NO-ERROR.
{&OUT}
    "<PRE>start:" state "</PRE><BR>"
    "<PRE>start:" state-name "</PRE><BR>"
    "<PRE>start:" Region "-end</PRE><BR>"
    .

/******************************************/

The results displayed as:

start:TS

start:          Test

start:test-end