Define Schema Filters

When you connect to a database, you can have  access only a small part of the database instead of reading the schema, including all tables, views, stored procedures, and database functions in the given schema. You can do this by defining schema filters. While defining your data source, you can define which parts of the database schema that you want  to read using regular expressions. You specify these as a list of Java regular expressions. There is no limit to the number of lines you can add.
lac40
When you connect to a database, you can have 
CA Live API Creator
 access only a small part of the database instead of reading the schema, including all tables, views, stored procedures, and database functions in the given schema. You can do this by defining schema filters. While defining your data source, you can define which parts of the database schema that you want
CA Live API Creator
 to read using regular expressions. You specify these as a list of Java regular expressions. There is no limit to the number of lines you can add.
Follow these steps:
  1. With your API open, in the Create section, click
    Data Sources
    .
    The Data Sources page appears. A list of existing data source connections display on the Connection tab.
  2. Click the 
    Schema Filters
    tab.
  3. Complete the following, and then save your changes:
    • Enter a line for each entity that you want to include or exclude into the 
      Include tables/views
       or 
      Exclude tables/views
       lists using Java regular expression syntax. Separate each line with a carriage return, a line feed, or a combination of these.
    • Enter a line for each stored procedure or database function that you want to include or exclude into the 
      Include stored procedures/functions
       or Exclude
      stored procedures/functions
       lists using Java regular expression syntax. Separate each line with a carriage return, a line feed, or a combination of these.
    Requirements:
    • If you do not enter an expression in the 
      Include tables/views
       list, 
      CA Live API Creator
       reads all tables and views.
    • If you do not enter an expression in the 
      Include stored procedures/functions
       list, 
      CA Live API Creator
       reads all stored procedures and database functions.
    • If you enter at least one expression in the 
      Include tables/views
       list, then 
      CA Live API Creator
       reads all the tables and views whose name satisfies at least one of the regular expressions and ignores all other tables and views. In particular, in the case of tables, if you do not include the parent and the child, 
      CA Live API Creator
       ignores the foreign keys.
    • If you enter at least one expression in the 
      Include stored procedures/functions
       list, then 
      CA Live API Creator
       reads all the stored procedures and database functions whose name satisfies at least one of the regular expressions and ignores all other stored procedures and database functions.
    • If you do not enter an expression in the 
      Exclude tables/views
       list, then 
      CA Live API Creator
       reads all database functions (subject to the entries in the 
      Include tables/views
       list).
    • If you do not enter an expression in the Exclude 
      stored procedures/functions
       list, then 
      CA Live API Creator
       reads all stored procedures and database functions (subject to the expressions you have specified in the 
      Include tables/views
       list).
    • If you enter at least one expression in the 
      Exclude tables/views
       list, then 
      CA Live API Creator
       ignores all tables and views that match at least one of the expressions you have specified in the list.
    • If you enter at least one expression in the Exclude 
      stored procedures/functions
       list, then 
      CA Live API Creator
       ignores all stored procedures and database functions that match at least one of the expressions you have specified in the list.
    Examples
    Description
    Java Regular Expression
    Read all objects whose name starts with A, B, a or b
    [ABab].*
    Read all objects whose name consists of two words, optionally separated by a dash
    \w[-]?\w
    Read the named objects
    MyTable
    MyOtherTable
    MyThirdTable
    If your stored procedures and database functions are contained in packages (for example, in Oracle databases), you can include or exclude the stored procedure or database function by the package name by defining schema filters that reference the package name.
    packA.procA
    For more information about the syntax for Java regular expressions, see the Oracle documentation.
You schema filters are defined.