QuestionQ25

Data Operations and Support

A company’s data engineer must optimize the performance of SQL queries against tables. The company stores its data in an Amazon Redshift cluster. Because of budget limitations, the data engineer cannot increase the cluster size.

The company stores data in multiple tables and loads it by using the EVEN distribution style. Some tables are hundreds of gigabytes in size. Other tables are smaller than 10 MB.

Which solution will satisfy these requirements?

  • A Keep using the EVEN distribution style for all tables. Specify primary and foreign keys for all tables.
  • B Use the ALL distribution style for large tables. Specify primary and foreign keys for all tables.
  • C Use the ALL distribution style for rarely updated small tables. Specify primary and foreign keys for all tables.
  • D Specify a combination of distribution, sort, and partition keys for all tables.
Explanation

Amazon Redshift ALL distribution copies the complete table to every compute node, which can eliminate data redistribution for joins. It increases storage, loading, and update costs, so it is appropriate for small, slowly changing tables rather than large tables. Declared primary and foreign keys provide constraint metadata that the query optimizer can use. AWS: Distribution styles

Learn more

Community Discussion

No comments yet. Be the first to start the discussion!