Q01. How will you pass variables or arguments from one notebook to another in Databricks? A01. There are two ways to accomplish this, Firstly, using %run and secondly, using the dbutils.notebook API. %run When you use %run, … Read more ›...
Q01. How will you pass variables or arguments from one notebook to another in Databricks? A01. There are two ways to accomplish this, Firstly, using %run and secondly, using the dbutils.notebook API. %run When you use %run, … Read more ›...
Q16: What are built-in functions in pyspark? A16: There are 4 types of functions in pyspark 1) Built-in function:: from org.apache.spark.sql.functions like to_date(Column e), to_utc_timestamp(Column e), etc. … Read more ›...
Q62. Can you explain the difference between HDFS blocks and input splits? A62. A block is a physical representation of data, and a Split is a logical division of your data or records. For example, an input split might split a large text file at the end of a record...
Below question is popular in SQL coding interviews. SQL syntaxes are very easy to learn, but lots of practice is required to be able to understand the business intent, and convert that into SQL statements with proper what if considerations. Break down the requirements to construct the SQL statements.
…
Data skipping is a performance optimization that aims at speeding up queries that contain filters (i.e. WHERE clauses). Data can be skipped using partitioning and z-ordering techniques. Q01. What is data partitioning in Databricks? A01. Partitioning involves putting different rows into different folders. … Read more ›...
Given the below employee.csv file in /tmp folder:
|
1 2 3 4 5 6 7 8 9 |
emp_id,emp_name,emp_city,emp_salary 1, John, Sydney, 35000.00 2, Peter, Melbourne, 45000.00 3, Sam, Sydney,55000.00 4, Danny, Melbourne, 45000.00 7, Roger, Sydney, 35000.00 8, Lisa, Sydney, 25000.00 |
Q22: What is the difference between RANK(), ROW_NUMBER(), and DENSE_RANK() windows functions? A22: RANK() assigns the same rank to rows with equal values, … Read more ›...
Q71. Can ETL in traditional data management (E.g. RDBMs) be migrated to EDH (i.e. Enterprise Data Hub) powered by Hadoop eco system? A71. Yes, it can be migrated, but it is not a direct & straight forward migration as there is a mismatch in underpinning concepts & … Read more...
This post covers an SQL scenario, and how to solve it with NON ANSI 92 aggregate functions. Refer to your database documentation for the additional aggregate functions. In this post let’s look at how to implode or concatenate multiple row column values into a single column. Problem statement &… Read...
Here are more performance optimization techniques in Databaricks. Q01. What is Delta Lake liquid clustering? A01. Delta Lake liquid clustering replaces table partitioning and ZORDER to simplify data layout decisions and optimize query performance. Liquid clustering provides flexibility to redefine clustering keys without rewriting existing data, … Read more ›...
Given the below file employee_by_prog_lanuguage.csv in a folder named /tmp.
|
1 2 3 4 5 6 7 8 9 |
emp_id, emp_name, prog_lang 1, John, Java 2, Peter, Scala 2, Peter, Python 2, Peter, Spark 1, John, JEE 6, Elliot, Unix |
Q24: Given the above file, how will display all prog_lang as a list against each emp_name? Each emp_name should be on a single row. A24: The functions in pyspark.sql.functions module collect_list(..) to the rescue with the groupBy function in...
This extends Apache Hive basics interview questions & answers. Q76. What are the 3 key considerations in processing data in HDFS compared to traditional RDBMS or EDW (i.e. Enterprise Data Warehouse)? AQ76. 1) partitioning, 2) bucketing, … Read more ›...
Q01: How do you back up an external with Data? A01 You can use CTAS (i.e. CREATE TABLE AS SELECT ) statement as shown below.
|
1 2 3 4 |
hive> CREATE TABLE mydb.my_table_20211117 AS SELECT * FROM mydb.my_table; |
Q02: What if the table you are backing up is partitioned? … Read more ›...
A distributed system consists of multiple software components that are on multiple computers (aka nodes), but run as a single system. These components can be stateful, stateless, or serverless, and these components can be created in different languages running on hybrid environments, using open-source technologies, open standards, and interoperability.
Q01.
…
I have a good news, I got job offer. I like to share with you from my bottom of my heart feeling thankful to you.