GET_ALIAS_FOR_TABLE SAP Method Returns alias name for given table









Below is documentation, parameters and attributes of ABAP Method GET_ALIAS_FOR_TABLE within SAP class /SCMTMS/CL_Q_SUPERCLASS. There is also a number of example ABAP code snipts to help you use the functionality of this method.

This method is available within SAP systems depending on your version and release level, you can view further information by entering the class name /SCMTMS/CL_Q_SUPERCLASS into the relevant SAP transactions such as SE24 or SE80, and then selecting the method you are interested in.


Method Type - Instance

This is an Instance Method so needs to be instantiated first before you can access any of the methods. I.e. you need to create a local variable of TYPE ref to the class.

The following technical details of method GET_ALIAS_FOR_TABLE can also be found below:

  • Importing parameters
  • Exporting parameters
  • Changing parameters
  • Returning parameters
  • Exceptions
  • Coding Examples


Parameters of Method GET_ALIAS_FOR_TABLE

.

NameTypeData TypeDescriptionDefault Value
IV_DB_ATTR_JOINImportingTYPE
FIELDNAME
Table Name
IV_DB_ATTR_JOIN_2ImportingTYPE
FIELDNAME
2nd Join Attribute Name of target table
IV_DB_ATTR_JOIN_2_CImportingTYPE
/SCMTMS/QENH_NODE_JOIN_C
Target Node Join Attribute Value from Constant or Type
IV_DB_ATTR_JOIN_2_VALImportingTYPE
/SCMTMS/QENH_NODE_JOIN_VAL
Target Node Join Attribute Value (IV_DB_ATTR_JOIN_2)
IV_DB_ATTR_JOIN_3ImportingTYPE
FIELDNAME
3rd Join Attribute Name of target table
IV_DB_ATTR_JOIN_3_CImportingTYPE
/SCMTMS/QENH_NODE_JOIN_C
Target Node Join Attribute Value from Constant or Type
IV_DB_ATTR_JOIN_3_VALImportingTYPE
/SCMTMS/QENH_NODE_JOIN_VAL
Target Node Join Attribute Value (IV_DB_ATTR_JOIN_3)
IV_DB_ATTR_ROOTImportingTYPE
FIELDNAME
Field Name
IV_DB_ATTR_ROOT_2ImportingTYPE
FIELDNAME
2nd Join Attribute Name of source table
IV_DB_ATTR_ROOT_JOINEDImportingTYPE
FIELDNAME
Field Name by which root table is joined
IV_DB_TABLE_JOINImportingTYPE
TABNAME
Table Name
IV_DB_TABLE_ROOTImportingTYPE
TABNAME
Table Name
IV_DB_ATTR_JOINImportingTYPE
FIELDNAME
Join Attribute Name of target table
IV_DB_ATTR_ROOTImportingTYPE
FIELDNAME
Join Attribute Name of source table
IV_DB_ATTR_ROOT_JOINEDImportingTYPE
FIELDNAME
Obsolete - better use the other parameters!
IV_DB_TABLE_JOINImportingTYPE
TABNAME
Table Name of joined table ('target table')
IV_DB_TABLE_ROOTImportingTYPE
TABNAME
Table Name of source table ('source table')
EV_ALIASExportingTYPE
STRING



Exceptions of Method GET_ALIAS_FOR_TABLE

This method does not have any exceptions

Example ABAP coding


DATA: lo_class TYPE REF TO /SCMTMS/CL_Q_SUPERCLASS.
DATA: lv_EV_ALIAS TYPE STRING,
lv_IV_DB_ATTR_JOIN TYPE FIELDNAME,
lv_IV_DB_ATTR_JOIN_2 TYPE FIELDNAME,
lv_IV_DB_ATTR_JOIN_2_C TYPE /SCMTMS/QENH_NODE_JOIN_C,
lv_IV_DB_ATTR_JOIN_2_VAL TYPE /SCMTMS/QENH_NODE_JOIN_VAL,
lv_IV_DB_ATTR_JOIN_3 TYPE FIELDNAME,
lv_IV_DB_ATTR_JOIN_3_C TYPE /SCMTMS/QENH_NODE_JOIN_C,
lv_IV_DB_ATTR_JOIN_3_VAL TYPE /SCMTMS/QENH_NODE_JOIN_VAL,
lv_IV_DB_ATTR_ROOT TYPE FIELDNAME,
lv_IV_DB_ATTR_ROOT_2 TYPE FIELDNAME,
lv_IV_DB_ATTR_ROOT_JOINED TYPE FIELDNAME,
lv_IV_DB_TABLE_JOIN TYPE TABNAME,
lv_IV_DB_TABLE_ROOT TYPE TABNAME,
lv_IV_DB_ATTR_JOIN TYPE FIELDNAME,
lv_IV_DB_ATTR_ROOT TYPE FIELDNAME,
lv_IV_DB_ATTR_ROOT_JOINED TYPE FIELDNAME,
lv_IV_DB_TABLE_JOIN TYPE TABNAME,
lv_IV_DB_TABLE_ROOT TYPE TABNAME,
lv_other TYPE c.

CALL METHOD lo_class=>GET_ALIAS_FOR_TABLE(
EXPORTING
IV_DB_ATTR_JOIN = lv_IV_DB_ATTR_JOIN
IV_DB_ATTR_JOIN_2 = lv_IV_DB_ATTR_JOIN_2
IV_DB_ATTR_JOIN_2_C = lv_IV_DB_ATTR_JOIN_2_C
IV_DB_ATTR_JOIN_2_VAL = lv_IV_DB_ATTR_JOIN_2_VAL
IV_DB_ATTR_JOIN_3 = lv_IV_DB_ATTR_JOIN_3
IV_DB_ATTR_JOIN_3_C = lv_IV_DB_ATTR_JOIN_3_C
IV_DB_ATTR_JOIN_3_VAL = lv_IV_DB_ATTR_JOIN_3_VAL
IV_DB_ATTR_ROOT = lv_IV_DB_ATTR_ROOT
IV_DB_ATTR_ROOT_2 = lv_IV_DB_ATTR_ROOT_2
IV_DB_ATTR_ROOT_JOINED = lv_IV_DB_ATTR_ROOT_JOINED
IV_DB_TABLE_JOIN = lv_IV_DB_TABLE_JOIN
IV_DB_TABLE_ROOT = lv_IV_DB_TABLE_ROOT
IV_DB_ATTR_JOIN = lv_IV_DB_ATTR_JOIN
IV_DB_ATTR_ROOT = lv_IV_DB_ATTR_ROOT
IV_DB_ATTR_ROOT_JOINED = lv_IV_DB_ATTR_ROOT_JOINED
IV_DB_TABLE_JOIN = lv_IV_DB_TABLE_JOIN
IV_DB_TABLE_ROOT = lv_IV_DB_TABLE_ROOT
IMPORTING
EV_ALIAS = lv_EV_ALIAS ).

Links to Related Class(s)

/SCMTMS/...
Full list of available SAP object classes

Search for further information about these or an SAP related objects



Comments on this SAP object

What made you want to lookup this SAP object? Please tell us what you were looking for and anything you would like to be included on this page!