LeetQuiz Logo
Privacy Policy•contact@leetquiz.com
© 2025 LeetQuiz All rights reserved.
Databricks Certified Data Engineer - Associate

Databricks Certified Data Engineer - Associate

Get started today

Ultimate access to all questions.


Consider a scenario where you are tasked with extracting data from a directory of JSON files located at /data/logs. Each file contains log entries with fields timestamp, user_id, and action. Your goal is to create a DataFrame that includes only the entries where the action field is 'login'. Which of the following code snippets is NOT correct for this task?

Simulated



Explanation:

Option A is NOT correct because it uses the CSV reader to read JSON files, which will not parse the data correctly. Options B, C, and D all use appropriate methods to read JSON files and filter for the required entries.

Powered ByGPT-5