Friday, 8 January 2016

"Central Table Error" and its Solution

FREQUENTLY FACED ISSUES IN HANA

Issues encountered while creating Analytical views.
Let me explain this in an elaborated form:

Error Message:- “Central table not unique. Attributes defined for different tables.”

CASE 1:- when we take a counter.

Problem Description:-
When we create an analytical view with tables and attribute views with a counter for any field. As Counter is itself a measure, we don’t need to define any other measure. When we validate and activate it. We will get the error as shown below:

SAP HANA Certifications, SAP HANA Material


Steps to recreate the error:

1.  Create an analytical view.

SAP HANA, SAP-HANA-Table
2. Create a Counter.

sap, hana, sap central table error

SAP HANA Certifications

3.  Activate the view.

SAP HANA Central

Here you will get the error.

Now,
4. Delete the counter you created and mark the same field as a measure in semantics.

SAP HANA Central, SAP HANA Certifications

There is no error now.

If you re designate the measure as an attribute in the semantics and create a counter in the same way. It will be activated successfully.

SAP HANA Table

REASON: For successful activation of an Analytical view, it requires a unique central table. For example when we create an attribute view with multiple tables, then we need to define a “key attribute” without which central table identification is not possible. Thus a “key attribute” is essential for successful activation of an Attribute view with multiple tables. In case of Analytical view as shown in the above example, when we define a measure, the table of the field which has been used as measure will automatically get designated as “central table” by HANA. In this case when we took a counter on Material Number (or any field for that matter can be taken as example) , the system was not able to identify a unique central table and an error message was generated. Now when we removed the counter and took the material number as measure in the semantics and marked it as count, the view was successfully activated.  Now, when we change material number back to attribute from measure and define the same counter on material number again, the before mentioned error will not be encountered again. Strange? The reason is that when we took material number as measure and activated the view, HANA identified the table of the field taken as measure (MARA in this case) as the central table which was not available earlier. Now even after changing Material number to attribute and creating a counter, the error message will not be seen as system is already aware of a central table for the view.

CASE 2: When we do not take any measure and mark the “Data Category” as Blank.

Steps to recreate the error:
1.  Create an analytical view.

SAP, SAP HANA, SAP HANA Certifications

2. Mark the Data Category as Blank and not Cube as we are not going to take any measure.

SAP Error, SAP HANA Central

3.  Activate the view.

SAP HANA Table Error

Here you will get the error message as “Central Table not Unique”.

SAP HANA Central Table Error

SAP HANA Table

It could not Identify the Central table. As an evidence we can see here that the "central entity" is blank:

Central Table Error

4.  Now, Mark any field in the Semantics as Measure and activate it. The view will successfully be activated.

SAP HANA Tutorial

Now, Lets see the Central Entity in the Properties section:

SAP HANA Certifications

Here It automatically took the table as central table from which the field was given
as measure.

5.  Now, after reverting the change i.e. again marking the field as an attribute and    activating the view. It will activate successfully.

SAP Certifications

If the system is not able to pick the central table, we can anytime choose the central table for the central entity to avoid the error.

This Content is tested for both version SPS08 and SPS09 of HANA.

Source: scn.sap.com

No comments:

Post a Comment