Previous Topic: Teradata Browser Editor for Functions, Script Templates, and Stored ProceduresNext Topic: Attach or Detach a Teradata Table or View to a Stored Procedure


Attach or Detach a Teradata Table or View to a Macro

The Macro Browser is available when your target DBMS is Teradata. Use the Macro Browser to see the tables and views that are attached to a macro and to view the code that is used by a particular macro template. You can also attach tables and views in your model to existing macros.

To attach or detach a Teradata table or view to a macro

  1. Click the browser icon Macro/Stored Procedure Browser Icon on the Macros dialog.

    The Teradata Macro Browser opens.

  2. Work with the following options:
    Template Name

    Lists the name of each table-level macro template in the model.

    Template Code

    Displays the first line of the macro template, which can include SQL statements and macros.

    Unattached Object

    Lists all tables and views in the model that are not attached to the selected macro template. Use the arrow to attach the selected table or view to the selected macro template.

    Attached Object

    Lists the tables and views that are attached to the selected macro template. Use the arrow to detach the selected table or view from the selected macro template.

    Template [Read Only]

    Displays the template code for the selected macro template. You change the code for the macro template in the Macros dialog.

    Template Expansion [Read Only]

    Displays the expanded code for the selected macro template. Expanded code is the code that will appear in the schema script when the schema is generated.

    Attach To New Table

    Select this check box to attach the macro template to each new table that you create. Clear this check box if you want to manually attach the macro template to new tables.

  3. Click Close.

    The Teradata Macro Browser dialog closes.