DC_Querybuild syntax

This forum is for eXpress++ general support.
Post Reply
Message
Author
Victorio
Posts: 633
Joined: Sun Jan 18, 2015 11:43 am
Location: Slovakia

DC_Querybuild syntax

#1 Post by Victorio »

Hi,

I have used this function in program. I have this as universal filter to filtering database.
How can I put to browse field own description to select browse table ?
In table for select fields is column Field description, Field name, field type, field len..."

I want change Field description to not see same field name but write here own description, for example
Field description Field name...
Telephone number PHONENUM
Street STR
Town TWN...


I see in source, that DC_QueryBuild has 4 parameters
cQueryExpr,cQueryName,cField, aFieldItems.

What is aFieldItems ? This parameter is for filtering in array only ?

I do not understand, how structure has aFieldItems.

Victorio
Posts: 633
Joined: Sun Jan 18, 2015 11:43 am
Location: Slovakia

Re: DC_Querybuild syntax

#2 Post by Victorio »

I examine put parameter as aray own field description, but error here :

LOCAL fd[10]
fd[1]="1 field"
fd[2]="2 field"
fd[3]="3 field"
fd[4]="4 field"
fd[5]="5 field"...

and then :

cQuery := DC_QueryBuild_sk(cQuery,,,fd)
...

Program stop with erron in this row in DC_QueryBuild()

ELSE
FOR i := 1 TO LEN(aFieldItems)
IF Len(aFieldItems) < 8
ASize(aFieldItems,8) **** here
ENDIF
NEXT
ENDIF
..

error is some like wrong data type error (now I have not modify source at home, because this stay in business PC)


I want change own description here :

DCSETPARENT TO oDCQUERY_BROW_FIELDS
DCBROWSECOL ELEMENT DCFLD_DESC WIDTH 15 HEADER 'Field Description' **** here
DCBROWSECOL ELEMENT DCFLD_NAME WIDTH 7 HEADER 'Field Name'
DCBROWSECOL ELEMENT DCFLD_TYPE WIDTH 3 HEADER 'Type'
DCBROWSECOL ELEMENT DCFLD_LEN WIDTH 3 HEADER 'Len'
DCBROWSECOL ELEMENT DCFLD_DEC WIDTH 3 HEADER 'Dec'

Post Reply