Skip to main content
Version: v1.13 print this page

Views

Amorphic Views helps you create views on underlying structured Datasets. These Views can be shared with authorized users and groups across the organization.

Views

Note

Views with same name can now be created throughout the application.; i.e., More than one view can have the same name throughout the application but should be unique under a specified Domain. DomainName will now be visible along with ViewName throughout the Amorphic application.

Amorphic Views page consists of options to list views or create a new View. Views are available to select in the Amorphic Views for listing purpose. You can sort through the Views using the Domain filters, create new View or view View's details.

Create New Views

You can create new Views in Amorphic by using the “New View” functionality of Amorphic application.

Create_View

In order to create a new view, you would require information like Domain, Target Location, View Type etc. An amorphic view can only be created on structured datasets that the user has access to.

Following are the main information required to create a new view:

  • View Name: View name must be 3-50 alphanumeric, _ characters only. View name must be unique under a given Domain
  • Description: Description of the view being created
  • View Type: Type of view. Eg: Standard, Materialized
  • Domain: Logical grouping of views. This will be used as schema name in datawarehouse
  • Target Location: Type of datawarehouse where you want to create the view
  • Auto Refresh: It is applicable only for materialized views. Redshift performs auto refresh on the view based on workload. It can be either enabled or disabled. You will still be able to perform manual refresh.
  • Keywords: Comma separated list of keywords. Keywords are indexed and searchable within the application. Please choose keywords which are meaningful to you and others. You can use these to flag related datasets with the same keywords so that you can easily find them later.
  • Data Classifications: List of classifications created based on different categories to protect the data more efficiently.
  • Sql statement: Sql statement used to create a view or edit a view Eg: create view as select * from amorphic.tables;

User can also create the view by using the "Navigator" which would direct the user to View Creation page from any where in the application. To get the option displayed, the user need to double tap on "Ctrl" button in the keyboard.

Below is a simple graphic to demonstrate Navigator:

Navigator

For a Multi tenancy deployment, Amorphic provides user capabilities to run cross tenant/database queries and creates view on top of them. You can query other tenant objects using fully qualified object names expressed with the three-part notation. The full path to any tenant object consists of three components: tenant name, schema, and name of the object. You can access any object from any other tenant/database using the full path notation, tenant_name.schema_name.object_name. To access a particular column, use tenant_name.schema_name.object_name.column_name.

View Details

Standard Views:

View_Details

Upon clicking on view details under a View, the user will be able to see all the following details of the view:

  1. View Name
  2. Description
  3. View Type
  4. Target Location
  5. IsActive
  6. Domain
  7. ViewStatus
  8. SQL Statement
  9. Keywords
  10. Data Classification
  11. Authorized Users
  12. Authorized Groups

Two important fields to consider in view details are:

  • IsActive: Specifies the user whether there exists a valid view on data warehouse to query.
  • View Status: Status can be create_complete, create_failed, update_rollback_complete, update_complete, create_in_progress, update_in_progress.

Along with the user input view Details like View Name, Domain, View Type etc, the details page would have:

  • Created By: User Name if the user who created the view and the Creation Date-Time of the view
  • Last Modified By: User Name of the user who last modified the metadata of the view

While creating the view:

  • If a view is successfully created IsActive is marked yes and View Status will be create_complete
  • If a view is fails to get created IsActive is marked no, View Status will be create_failed and Error Message is displayed

Materialized Views:

Materialized_View_Details

Upon clicking on view details under a View, the user will be able to see all the following details of the view:

  1. View Name
  2. Description
  3. View Type
  4. Target Location
  5. IsActive
  6. Domain
  7. ViewStatus
  8. AutoRefresh
  9. RefreshStatus
  10. LastRefreshCompletionTime
  11. SQL Statement
  12. Keywords
  13. Data Classification
  14. Authorized Users
  15. Authorized Groups

Apart from basic view details, Important fields to consider in materialized view details are:

  • AutoRefresh: Redshift performs refresh on the view based on workload. It can be either enabled or disabled. You will still be able to perform manual refresh.
  • RefreshStatus: The status of the refresh. For example statuses, check the Refresh Status documentation.
  • LastRefreshCompletionTime: Time when the materialized view completed the last refresh.

Edit Views

Standard Views:

An edit view statement should start with create or replace view. Following graphic shows the process of editing a view:

Edit_View

While updating the view:

  • If an update fails on a failed view IsActive will stay no and View Status will be create_failed and Error Message is displayed
  • If an update is successful on a failed view IsActive will change to yes and View Status will be create_complete
  • If an update fails on a successful view IsActive will stay yes and View Status will be update_rollback_complete and Error Message is displayed
  • If an update is successful on a successful view IsActive will stay yes and View Status will be update_complete

A view cannot be edited or deleted when the View Status is create_in_progress or update_in_progress.

Materialized Views:

An edit view statement should start with create materialized view (only applicable for non-active views). An active materialized view cannot be edited. Only metadata fields can be updated.

Following graphic shows the process of editing a materialized view:

Edit_Materialized_View

While updating the view:

  • If an update fails on a failed view IsActive will stay no and View Status will be create_failed and Error Message is displayed
  • If an update is successful on a failed view IsActive will change to yes and View Status will be create_complete
  • If an update is successful on a successful view IsActive will stay yes and View Status will be update_complete

A materialized view cannot be edited or deleted when the View Status is create_in_progress or update_in_progress.

Note

View actions such as creation and updation etc are time bound with a maximum duration of 15 minutes. If such an action is not completed within the time limit, view status is moved to failed with Request Timed out error message. Users needs to debug and re-trigger the respective action. For example, A long running create view query can result time out errors as it was not able to finish. Users needs to make the necessary updates to the query and re-trigger the creation.

Refresh Materialized View

A materialized view can be refreshed either manually or by selecting auto refresh option. If auto refresh phrase is in included sql statement and auto refresh option is selected during view creation/updation, auto refresh option at view level takes precedence.

Following graphic shows a materialized view being refreshed manually:

Refresh_Materialized_View

You can enable/disable auto refresh on materialized view any time by editing the view.

List Views

Users will be able to see the list of views they have access to. They can also limit the results shown per page using Results Per Page option, and can sort the them based on desired field and its order.

List_Views

Authorized Users

This tab shows the list of users authorized to perform operations on the view. The owner, user who created or have owner access to the view, can provide view access to any other user in the system.

There are two type of access types:

  • Owner: This User has permissions to edit the view, provide access to other user for the dataset and query the view in datawarehouse.
  • Read-only: This user has limited permission to view, such as view the details and query the view in datawarehouse.

Authorized Groups

This tab shows the list of groups authorized to perform operations on Views. A group is a list of users given access to a resource, in this case view. Groups are created by going to User Profile -> Profile & Settings -> Groups

There are two type of access types:

  • Owner: This group of users has permissions to edit the view, provide access to other user/groups for the view and query the view in datawarehouse.
  • Read-only: This group has limited permission to resources, such as view the details and query the view in datawarehouse.