BEA Logo BEA Tuxedo Release 7.1

  Corporate Info  |  News  |  Solutions  |  Products  |  Partners  |  Services  |  Events  |  Download  |  How To Buy

 

   Tuxedo Doc Home   |   Programming   |   Topic List   |   Previous   |   Next   |   Contents

   Programming a BEA Tuxedo Application Using FML

Mapping Field Names to Field IDs

Run-time mapping is done by the Fldid() and Fname() functions, which consult the set of field table files specified by the FLDTBLDIR and FIELDTBLS environment variables. (If FML32 is being used, the Fldid32() and Fname32() functions reference the FLDTBLDIR32 and FIELDTBLS32 environment variables.)

Fldid maps its argument, a field name, to a fieldid, as shown in the following code.

char *name;
extern FLDID Fldid();
FLDID id;
...
id = Fldid(name);

Fname does the reverse translation by mapping its argument, a fieldid, to a field name, as shown in the following code.

extern char *Fname();
name = Fname(id);
. . .

Identifier-to-name mapping is rarely used; it is rare that one has a field identifier and wants to know the corresponding name. One situation in which the field identifier-to-field name mapping can be used is in a buffer print routine designed to display, in an intelligible form, the contents of a fielded buffer.

See Also