Objective. Students will independently build a complete, documented ETL pipeline from a new data source to a PostgreSQL target database and conduct a structured peer review using a rubric drawn from DAMA CDMP and DP-300 exam criteria.
This lesson, its worked examples and its practice questions has not yet been verified by an industry-certified professional or by a certification or approval body. It is a study draft and may contain errors. Do not use it as instructions for work on a job site or on live equipment. Always follow your instructor, your supervising professional, and current official references and regulations.
VoTechWorks program approval and accreditation are still in progress. Credentials are issued only by the certifying bodies named in each program, after their own exams.
This lab brings together every skill from the ETL course into a single, assessed deliverable: a complete pipeline you design, build, document, and then review with a classmate. By working through an unfamiliar specification under realistic conditions, you practice the kind of independent problem-solving employers expect from a working database administrator.
A complete ETL pipeline is more than working code. It has four visible layers that an employer or auditor can inspect:
1. Architecture — a diagram showing the source system, any staging area, transformation logic, and the target database, with data-flow arrows and notes on connection method.
2. Code — extract, transform, and load scripts that are readable, version-controlled, and include inline comments explaining non-obvious decisions.
3. Documentation — written explanation of data source characteristics, every transformation rule, the load strategy chosen (full refresh vs. incremental/upsert), error-handling design, and a run log proving the pipeline executed successfully.
4. Operational evidence — the run log itself: timestamps, row counts in and out, any warnings, and confirmation that the target table matches expectations.
When you receive the instructor's new specification, read it completely before writing a single line of code. Identify the source schema, check for null-able columns or type mismatches, and note any business rules embedded in the transformation instructions. Sketch the architecture diagram first; gaps in the diagram reveal gaps in your understanding before they become bugs.
Correctness means the pipeline loads exactly the right data, no more and no less. Test each stage in isolation: run the extract and inspect a sample of rows; apply transformations and verify a calculated field against a hand-checked record; load to a test schema before touching production. Use row-count assertions — compare source row count to target row count after each run and raise an error if they diverge beyond an expected tolerance.
Security is a first-class concern at every stage. Never hard-code database credentials in your script. Store connection strings and passwords in environment variables or a secrets file that is excluded from version control (add it to `.gitignore`). When connecting with psycopg2, use parameterized queries for any dynamic SQL to prevent SQL injection. Limit the database user your pipeline runs as to only the privileges it needs — typically INSERT and UPDATE on the target table, SELECT on source objects, nothing else. These practices align directly with DP-300 security objectives and DAMA CDMP data governance principles.
For error handling, wrap each stage in a try/except block. Log the exception with enough context (stage name, timestamp, row identifier if available) to diagnose the failure without re-running. Decide explicitly whether a failed row should stop the entire pipeline (fail-fast) or be written to a quarantine table for later review (partial-load). Document your choice and the reason.
Your documentation must state which load strategy you used and why. The three common choices are:
Your justification should reference the source data's characteristics as given in the specification — update frequency, volume, and whether a watermark column exists.
Good pipeline documentation is written for a colleague who was not in the room when you built it. Each required section serves a purpose:
The peer review is not proofreading — it is a technical audit. Work through the rubric item by item. For each criterion, cite specific evidence from the code or documentation: a line number, a section heading, or a log entry. If something is missing or incorrect, describe it precisely and suggest a fix. Vague comments such as "error handling could be better" are not acceptable; write "the load function has no exception handler around the `cursor.execute` call at line 47; if the INSERT fails the script will crash without logging the failed row."
Before submitting your written review, discuss your findings with your peer. They may clarify intent that was not obvious from the code, or you may identify an issue together that neither of you caught alone. Revise your written review after the discussion if new information changes your assessment.
This is a software lab; physical hazards are minimal. However, always follow your program's acceptable-use policy for shared servers. Do not store real personally identifiable information in lab databases. Shut down test database connections when you finish to free server resources for classmates.
Answer each question, then check it. Nothing is recorded; this is your own practice.
A free tech program — complimentary, as our commitment to get America working. Help us build VoTechWorks. Tell us what works, what doesn’t, and what you want to learn.