Progress
AppBuilder
Developer’s Guide


AppBuilder Database Table Names (adeuib/_dbtbnam.p)

Use the adeuib/_dbtbnam.p procedure to have AppBuilder correctly generate table names based on setting the “Qualify Database Fields with Database Names” user preference:

Calling Sequence
RUN adeuib/_dbtbnam.p
  ( INPUT p_id , 
    INPUT p_name_in 
    OUTPUT p_name_out
  ) . 

Input Parameters

The adeuib/_dbtbnam.p procedure uses the following input parameters:

pi_context

The context ID of the current procedure (to obtain this ID, use adeuib/_uibinfo.p).

pc_name_in

A table name. This name might or might not be qualified with a database name.

Output Parameter

The adeuib/_dbtbnam.p procedure uses the following output parameter:

pc_name_out

A table name that meets the settings of the “Qualify Database Fields with Database Names” user preference.

Example

DEFINE VAR  db-tbl     AS CHAR       NO-UNDO.
DEFINE VAR  proc-id    AS INTEGER    NO-UNDO.
DEFINE VAR  ch         AS CHAR       NO-UNDO.

/* 
**  Get the context of the current procedure.
*/
RUN adeuib/_uibinfo.p (INPUT ?, INPUT ?, INPUT "PROCEDURE":U, OUTPUT ch).
proc-id = INTEGER (ch).
/*
**  The user may have wanted to suppress the db name in AppBuilder. 
**  Ask AppBuilder to set up the database/table name.
*/
RUN adeuib/_dbtbnam.p (proc-id, "Sports.Customer":U, OUTPUT db-tbl).
MESSAGE db-tbl.  


Copyright © 2004 Progress Software Corporation
www.progress.com
Voice: (781) 280-4000
Fax: (781) 280-4095