DA0-002 Data Concepts and Environments Practice Question
A financial services company is migrating its customer data from a legacy on-premises relational database to a cloud-based data warehouse. The legacy database uses a denormalized schema with a single table 'customer_master' that contains all customer attributes, including repeated groups for multiple accounts per customer (account1_type, account1_balance, account2_type, account2_balance, etc.). The data warehouse team wants to implement a normalized star schema with separate dimension and fact tables. During the ETL process, the team encounters an error: 'Data truncation: string data right truncation' when loading account_type values into the dim_account table. The account_type column in dim_account is defined as VARCHAR(10), but the source data contains account types like 'SavingsPlus' (11 characters) and 'CheckingPremium' (15 characters). The team must resolve this issue without losing data. Which course of action should the team take?
⚠ Common exam trap
Many exam-takers choose truncation (Option A) or NULL insertion (Option C) as quick fixes, overlooking the requirement to preserve data integrity, or mistakenly think TEXT (Option B) is a safe catch-all without considering performance implications in a data warehouse context.
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
Increase the VARCHAR length of dim_account.account_type to accommodate the longest account type.
Increasing the VARCHAR length of dim_account.account_type to accommodate the longest account type (e.g., VARCHAR(15) for 'CheckingPremium') resolves the data truncation error without data loss. This aligns with the star schema design principle of preserving source data integrity while ensuring the column definition matches the actual data length. The team must avoid truncation or NULL insertion to maintain accurate dimensional attributes for analytics.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
Truncate the account_type values to 10 characters during ETL.
Why it's wrong here
Truncating to 10 characters turns 'CheckingPremium' into 'CheckingPr', collapsing distinct account types into one and destroying data, which the stem forbids. It is tempting as a quick loader fix, yet truncation is only acceptable when the excess characters are known padding, not meaningful category names.
- ✗
Change the data type of dim_account.account_type to TEXT.
Why it's wrong here
TEXT removes the length ceiling but prevents the warehouse from indexing or comparing the column efficiently, and it does not address the real cause: the column is simply too narrow. Widening to VARCHAR(15) or more is the targeted fix; TEXT suits genuinely unbounded free-text fields, not short categorical codes.
- ✗
Ignore the error and continue loading with NULL values for truncated rows.
Why it's wrong here
Nulling truncated rows silently discards the account type for every affected customer, breaching the no-data-loss requirement and corrupting downstream fact joins. Ignoring load errors is tempting when only a few rows fail, but it is defensible only for genuinely optional columns, not a dimension's core attribute.
- ✓
Increase the VARCHAR length of dim_account.account_type to accommodate the longest account type.
Why this is correct
The truncation error occurs because dim_account.account_type is VARCHAR(10) while source values reach 15 characters. Widening the column to the longest value preserves every account type during load, satisfying the no-data-loss constraint without altering source records.
Visual reference
Go deeper
Related to this question
About these practice questions
This DA0-002 question is part of Courseiva's 1,004-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This DA0-002 practice question is part of Courseiva's free CompTIA certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the DA0-002 exam.