---
name: "DBD::Firebird::TableInfo::Basic"
section: "3pm"
platform: "linux"
package: "libdbd-firebird-perl"
version: "1.39-2"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/DBD::Firebird::TableInfo::Basic"
---

# DBD::Firebird::TableInfo::Basic(3pm)

A base class for lowest-common denominator Firebird table\_info() querying.

## NAME

DBD::Firebird::TableInfo::Basic - A base class for lowest-common denominator Firebird table\_info() querying.

## SYNOPSIS

```
    # Add support for a hypothetical IB derivative
    package DBD::Firebird::TableInfo::HypotheticalIBDerivative
    @ISA = qw(DBD::Firebird::TableInfo::Basic);
    # What table types are supported?
    sub supported_types {
        ('SYSTEM TABLE', 'TABLE', 'VIEW', 'SPECIAL TABLE TYPE');
    }
    sub table_info {
        my ($self, $dbh, $table, @types) = @_;
    }
```

## INTERFACE

- *list\_catalogs*

  ```
      $ti->list_catalogs($dbh);  # $dbh->table_info('%', '', '')
  ```

  Returns a statement handle with an empty result set, as IB does not support the DBI concept of catalogs. (Rule 19a)

- *list\_schema*

  ```
      $ti->list_schema($dbh);    # $dbh->table_info('', '%', '')
  ```

  Returns a statement handle with an empty result set, as IB does not support the DBI concept of schema. (Rule 19b)

- *list\_tables*

  ```
      $ti->list_tables($dbh, $table, @types); # $dbh->table_info('', '',
                                              #                  'FOO%',
                                              #                  'TABLE,VIEW');
  ```

  Called in response to `$dbh`-\>table\_info($cat, `$schem`, `$table`, `$types`).  `$cat` and `$schem` are presently ignored.

  This is the workhorse method that must return an appropriate statement handle of tables given the requested `$table` pattern and `@types`.  A blank `$table` pattern means "any table," and an empty `@types` list means "any type."

  `@types` is a list of user-supplied, requested types. `"DBD::Firebird::db::table_info"` will normalize the user-supplied types, stripping quote marks, uppercasing, and removing duplicates.

- *list\_types*

  ```
      $tbl_info->list_types($dbh);  # $dbh->table_info('', '', '', '%')
  ```

  Called in response to `$dbh`-\>table\_info('', '', '', '%'), returning a statement handle with a TABLE\_TYPE column populated with the results of *supported\_types*.  (Rule 19c)

  Normally not overridden.  Override *supported\_types*, instead.

- *supported\_types*

  ```
      $tbl_info->supported_types($dbh);
  ```

  Returns a list of supported DBI TABLE\_TYPE entries.  The default implementation supports 'TABLE', 'SYSTEM TABLE' and 'VIEW'.

  This method is called by the default implementation of `"list_types"`.
