Consultor Eletrônico



Kbase P84691: Dynamics: modifying an SDO query with European numeric format fails to return any records.
Autor   Progress Software Corporation - Progress
Acesso   Público
Publicação   6/18/2004
Status: Unverified

FACT(s) (Environment):

Dynamics

SYMPTOM(s):

Dynamics: modifying an SDO query with European numeric format fails to return any records.

Modifying an SDO query with AddQueryWhere fails to return any records when the session is using European number format.

Decimal values such as _obj fields, in an SDO query fail to return any records.

Using -E or -numsep 46 -numdec 44

CAUSE:

The problem is because the decimal field needs to be enclosed in quotes when passed to the query.

FIX:

Pass the decimal _obj field to the function enclosed in quotes. For example in the following intializeObject override the CurrentOrganisationObj is enclosed in single quotes:

RUN SUPER.
DEFINE VARIABLE cQuery AS CHARACTER NO-UNDO.

cQuery = "login_company_obj EQ '" +
DYNAMIC-FUNCTION('getPropertyList':U IN gshSessionManager,
"CurrentOrganisationObj":U, FALSE) + "'".

DYNAMIC-FUNCTION('AddQueryWhere':U IN TARGET-PROCEDURE,
INPUT cQuery,
INPUT "",
INPUT "":U).

DYNAMIC-FUNCTION('openQuery':U IN TARGET-PROCEDURE).


Alternatively, you could use the Quoter function to enclose the _obj value in quotes. e.g.

cQuery = "login_company_obj EQ " +
QUOTER(DYNAMIC-FUNCTION('getPropertyList':U IN gshSessionManager,
"CurrentOrganisationObj":U, FALSE)).