Data Dictionary and Metadata Refresh Database and Objects

Database
Enthusiast

Data Dictionary and Metadata Refresh Database and Objects

What query do you run to refresh database/object for Data Dictionary and Metadata Refresh?

 

For dictionary, do you run CT (new db.table) as (original db.table) WITHO NO DATA AND STATS?

 

What about for metadata refresh with Data Refresh and metadata naming convention?

And what is the query for metadata refresh Full refresh on Bmap  metadata tables but Schema only on Bkey tables?

 

 

Thanks

 

10 REPLIES 10
Ambassador

Re: Data Dictionary and Metadata Refresh Database and Objects

Hi,

Not really sure where this question is coming  from, I'm guessing that you're used to another dbms environment.

 

The dictionary data in Teradata is dynamic, so you don't need to manually refresh it.

 

If you're talking about one of the common query tools (SQLA or TDStudio) then that is something else.

 

Or are you talking about statistics data on columns etc.? (I don't think so).

 

If you could give us some context to this question, or an example of what you're trying to do then we can probably help further.

 

Cheers,

Dave

Ward Analytics Ltd - information in motion
www: http://www.ward-analytics.com
Enthusiast

Re: Data Dictionary and Metadata Refresh Database and Objects

Hello Dave,

 

Thanks for your quick response first of all.

Yes, I am using SQLA

 

Basically I am supposed to refresh database.table from Production to Test environment's database.table

As an example, refresh ProductionDB.TableName to TestDB.Tablename for

1) Data Dictionary (It should be like  Create Table TestDB.Tablename as ProductionDB.TableName WITH NO DATA AND STATS? 

2) What is the query for MetaData Refresh with Data and metadata name convention?

3) What is the query for Metadata Refresh (Full Refresh on BMAP metadata tables, but SCHEMA only on BKEY Table?)

 

 

Many Thanks

 

 

Ambassador

Re: Data Dictionary and Metadata Refresh Database and Objects

Hi,

 

Looking at your questions from below:

 

1) Data Dictionary (It should be like Create Table TestDB.Tablename as ProductionDB.TableName WITH NO DATA AND STATS?

DW: The 'create table as' will copy the table definition into a new database (TestDB).

2) What is the query for MetaData Refresh with Data and metadata name convention?

DW: In your environment, what do you class as 'metadata'? In a standard Teradata system the only metadata is the dictionary. They are the same, so the 'create table as' command handles this as well.

3) What is the query for Metadata Refresh (Full Refresh on BMAP metadata tables, but SCHEMA only on BKEY Table?)

DW: see my answer for #2

 

Cheers,

Dave

 

 

Ward Analytics Ltd - information in motion
www: http://www.ward-analytics.com
Enthusiast

Re: Data Dictionary and Metadata Refresh Database and Objects

So there's no difference between metadata and data dictionary in terms of terminology?

And for #3 question, you don't write any query for aside create table as?? (Full Refresh on BMAP metadata tables, but SCHEMA only on BKEY Table?)

 

Cheers

Highlighted
Enthusiast

Re: Data Dictionary and Metadata Refresh Database and Objects

Also back to #1, data dictionary always creates a table with no data and stats correct?
Ambassador

Re: Data Dictionary and Metadata Refresh Database and Objects

Hi,

 

In terms of standard Teradata features, there is no difference between metadata and dictionary data. The dictionary (DBC) is where all metadata is stored. Of course your system may have another application that it uses to store 'metadata' but that is not what the Teradata dbms uses.

 

Your question "Also back to #1, data dictionary always creates a table with no data and stats correct? " makes no sense in a Teradata system. When you issue a successful 'create table' statement, the table definition is stored in the dictionary.

 

"And for #3 question, you don't write any query for aside create table as?? (Full Refresh on BMAP metadata tables, but SCHEMA only on BKEY Table?)"

You can code a 'create table as' command, or use 'create table' in which case you supply the full table definition. Have a look here for the syntax for these commands.

 

The terms BKEY and BMAP do not have a meaning in a Teradata system.

 

HTH

Dave

Ward Analytics Ltd - information in motion
www: http://www.ward-analytics.com
Ambassador

Re: Data Dictionary and Metadata Refresh Database and Objects

BKEY and BMAP are Global Control FrameWork lingo, but I don't know which is the right forum GCFR questions...

Ambassador

Re: Data Dictionary and Metadata Refresh Database and Objects

That'll probably be the Teradata Account Team Forum... Smiley Happy

Ward Analytics Ltd - information in motion
www: http://www.ward-analytics.com
Teradata Employee

Re: Data Dictionary and Metadata Refresh Database and Objects

BMAP and BKEY appear to refer to concepts implemented as part of the GCFR framework for developing Teradata applications.

In that context, perhaps "metadata refresh" means "copy the contents" (e.g. CREATE TABLE AS WITH DATA) and "schema only" could mean "copy the structure but not the contents" (WITH NO DATA). But that's only a guess. You'd be better off contacting the requester to get more clarity on what is being requested.