Refresh database schema
If the tables available to Count through its database credentials change, then you will need to ask Count to fetch the latest schema to see those changes reflected your workspace.
Option 1: from the connection settings
Select your connection from the workspace home page, then Manage connection. The option to refresh the schema is available near the bottom of the page.
If your database contains a large number of tables, Count may not import all of them. To reduce the number of tables that Count attempts to import, an optional filter may be applied that is applied to the schema of the table.
There are two options for the form of this filter.

- Javascript regular expression. This regular expression is applied to the schema of each row of table metadata streamed to Count's servers. For example, to only fetch schema that begin with the text "production", the filter should be
^production
. To only fetch schema that end with the text "_prod", the filter should be_prod$
. - Database native expression. This regular expression is applied to the query executed on your database to retrieve the table metadata. As this is applied to the query, not the table metadata stream, this may give improved performance when executing database schema refreshes. However, the regex itself is database dependent (see table below) and may not be as expressive as the JavaScript filter above. The table below, shows how each filter is implemented.
To test your regular expression, you may want to use a free tool such as RegExr.
A common difference between JavaScript regex and Database native regexes is that the former will match on substring matches by default, but Database native regexes will match the full string. To perform partial matches in Database native regex, you will need to explicitly add a wildcard parameter (e.g. %
).
Database regex engine
Database | Filter implementation | Documentation link |
---|---|---|
Postgres | schemaName SIMILAR TO <database-regex> in WHERE clause | https://www.postgresql.org/docs/current/functions-matching.html#FUNCTIONS-SIMILARTO-REGEXP |
Redshift | schemaName SIMILAR TO <database-regex> in WHERE clause | https://docs.aws.amazon.com/redshift/latest/dg/pattern-matching-conditions-similar-to.html |
Other | Supported soon - watch this space! |
Option 2: from a canvas
You can also refresh the schema directly from the canvas by clicking the refresh icon in the data bar
