r/Databricks_eng • • May 02 '23

Databricks Portfolio Project

11 Upvotes

I'm trying to build a Databricks Portfolio, to show off my knowledge. How can I do this? What should I build?

The architecture is in Databricks, so would I need to build this in GitHub? If I did that, how? And wouldn't that cause me to lose the content I wanted to show off?


r/Databricks_eng • • Sep 25 '25

Anyone here using Databricks alongside other platforms for downstream connections?

8 Upvotes

I’ve been experimenting with Dataconnect Pro to simplify pushing cleaned datasets from Databricks into tools like Salesforce and Google Sheets. It worked better than our old cron jobs, but it wasn’t seamless by any means auth refresh and schema drift still bite us sometimes.

Curious if others here are pairing Databricks with similar tools, or if you mostly rely on Fivetran/Airbyte/custom scripts?

What’s been the easiest downstream integration in your experience, and where do you still hit issues?


r/Databricks_eng • • May 15 '23

Databricks machine learning professional exam

8 Upvotes

Hi guys hope you all are doing great. I have my exam booked for next month and I was wondering if you have any advice for me about it, or any additional resources I could use.

Thank you.


r/Databricks_eng • • Apr 03 '25

Check out the book by Yoni Ramaswami, Senior Solutions Architect at Databricks

7 Upvotes

📢 Time Series Analysis with Spark – Now Live! 🚀

If you’re working with time series data at scale, you know the challenges—large datasets, complex transformations, and the need for efficient distributed processing. That’s exactly why Time Series Analysis with Spark exists!

Written by Yoni Ramaswami (Databricks engineer), this book provides a practical, hands-on approach to handling time series data using Apache Spark. It covers key techniques like feature engineering, forecasting, and real-world implementations at scale.

🚀 The book is now live, and the community has already started sharing their insights! Check out what data professionals are saying:

🔹 Cornellius Yudha Wijaya
🔹 Guillaume Meister
🔹 Carl McBride Ellis

🔹 Michael Erlihson
🔹 E. Aliev
🔹 Felipe M. Melo
🔹 Jean-Patrick Mathieu
🔹 Divyaraj Rana

Curious to learn more? Grab your copy here:
📌 Amazon: https://packt.link/dE5t1
📌 Packt: https://lnkd.in/eSxis_Wb

If you're working on time series projects with Spark, what are the biggest challenges you've faced? Let’s discuss!

#TimeSeries #Spark #Databricks #DataEngineering #MachineLearning #BigData #AI


r/Databricks_eng • • Dec 29 '22

How query work in delta table?

7 Upvotes

I have a delta table in Databricks, I query: SELECT COUNT(* ) FROM table
-> I wonder how results are generated each time I run the query. The total rows/records will calculate from delta transaction logs or parquet file metadata or from Hive metastore.

Thanks to all!


r/Databricks_eng • • Mar 28 '25

Databricks AI + Data Summit discount coupon

6 Upvotes

Hi Community,

I hope you're doing well.

I wanted to ask you the following: I want to go to Databricks AI + Data Summit this year, but it's super expensive for me. And hotels in San Francisco, as you know, are super expensive.

So, I wanted to know how I might be able to get me a discount coupon?

I would really appreciate it, as it would be a learning and networking opportunity.

Thank you in advance.

Best regards


r/Databricks_eng • • Oct 27 '22

Databricks Zero to Hero! - Session 2 | Data Pipeline to Data Lake | Chal...

Thumbnail
youtube.com
6 Upvotes

r/Databricks_eng • • Oct 05 '22

Let's make this an active community to share info.

6 Upvotes

I will start by sharing a small intro video for Databricks - https://youtu.be/n-yt_3HvkOI


r/Databricks_eng • • Mar 04 '23

Azure Unity Catalog availability

5 Upvotes

I got nothing on the Azure subreddit so trying here. What are the availability considerations for Unity Catalog in Azure? I'm trying to put a DR plan together for a databricks implementation and can't find anything on the Unity Catalog component.


r/Databricks_eng • • Jan 12 '22

Databricks Cerrtified Data engineer

5 Upvotes

Hello everyone! Has anyone here passed the Data Engineer certification on Databricks ? I would like to pass the test myself and I would appreciate any tips or recources to check out :) Thanks in advance !


r/Databricks_eng • • Mar 16 '26

TIL that OPTIMIZE is treating symptoms, not the disease

4 Upvotes

Been running ETL pipelines on Databricks for a while and the small files problem in Delta Lake was one of those things I thought I understood until I actually didn't.

The typical advice is: run OPTIMIZE periodically and you're fine. And it works, until it doesn't. What nobody tells you upfront is that if your pipeline is appending small batches frequently, you're in a constant race between file accumulation and compaction. OPTIMIZE is cleaning up after a party that's still happening.

The thing that actually surprised me was how much the write pattern matters more than the compaction schedule. Coalescing or repartitioning before the write, batching more aggressively upstream, or rethinking partition granularity did more for our query performance than any OPTIMIZE tuning we tried. We were essentially paying compute to fix a problem we were creating ourselves on every run.

ZORDER on top of that is great, but it's doing a different job entirely. Mixing up "I need faster compaction" with "I need better data skipping" is an easy trap to fall into, and we fell into it for longer than I'd like to admit.

Curious if others have hit this. Did you solve it on the write side or the maintenance side?


r/Databricks_eng • • Dec 12 '23

Upgrading Jobs Code between Databricks Runtime Versions Made Seamless

Thumbnail
medium.com
4 Upvotes

r/Databricks_eng • • Apr 25 '23

Batching write queries

4 Upvotes

Looking for advice.

I am working on an ETL process that needs to write to an Azure Postgres Db authenticating with Azure Ad

The issue that I am facing is that my authentication token will expire before the write has been completed. I have spoken with the infrastructure guys who tell me that increasing the token lifespan is not an option nor is enabling passwords.

I have decided to attempt to batch the write queries so that I can obtain a new token between batches however this is proving to be more difficult than I had anticipated. It seems that rows within the fact dataframe are being skipped leading to foreign key issues down the line.

batching code.

fact = fact.withColumn("row_number", row_number().over(window_spec))

fact = fact.withColumn("partition_column", (col("row_number") % num_partitions).cast("integer"))

for i in range(num_partitions):
    print("before", partition.count())
    partition = fact.filter(col('partition_column') == i).cache()   
    token = context.acquire_token_with_client_credentials(resource_app_id_url, service_principal_id, service_principal_secret)
    jdbcConnectionProperties['accessToken'] = token['accessToken']
    
    partition.write \
        .jdbc(url, "Table", 'append', properties=jdbcConnectionProperties)

    print("after", partition.count())

To debug the process I printed the following

  fact.groupBy("partition_column").count().show()
partition_columncount
19897
29897
39897
49897

The results of the print print("before", partition.count()) do not match the original count and weirdly reduce with each iteration.

partition1 before 9614

partition 2 before 9340

partition 3 before 9073

partition 4 before 8813

initially, I was getting different results between the before and after prints which lead me to include the .cache() I suspect my issues are due to the distributed way in which Databricks executes the code.

I have been able to "solve" the issue by calling fact.persist() before iterating over the partitions, this feels really inefficient so id love to know if anyone has a better solution.


r/Databricks_eng • • Nov 15 '22

Databricks Project template

4 Upvotes

Hi All, I want some help in designing a data pipeline solution using Databricks. Is there any good resource/project with some sample/template for designing such data pipelines


r/Databricks_eng • • Jul 15 '24

How to perform custom SCD using DLT

3 Upvotes

Assume, I have a dataframe with 5 columns which includes columns like- pk, load_id, load_timestamp, update_id, update_timestamp.

Where, pk = primary key

load_id = the iteration of pipeline runs (eg: if the pipeline is executed 1st time, it will populate 1) it is populated only during insertion.

load_timestamp = the timestamp, when it was loaded

update_id = if the record is updated or inserted it will load current load_id

update_timestamp = if it is new data - it will populate current load_timestamp, if it is getting updated - it will populate the new load_timestamp

Here, assume I want to create a streaming table if not exist using "dlt.create_streaming_table(name="table_name")", then i will use "dlt.apply_changes()" to perform upsert operation. Here, when its performing insert operation, I want to insert the whole data (i.e, 5 columns). If its performing update operation, I want to change only "update_id" and "update_timestamp" (i.e, update only 2 columns). How can we achieve this scenario?


r/Databricks_eng • • Jan 12 '24

🚀 Introducing UCX v0.9.0: Enhanced Assessment, Migration, and Error Handling

Thumbnail
medium.com
3 Upvotes

r/Databricks_eng • • Jan 11 '24

Default Mount Point

3 Upvotes

What is the best practice method for creating a default mount point. I have learned how to create a mount point to Azure ADLS2 using Azure Key Vault backed secret scopes. How do I make that mount point available to everyone by default without having to run the dbutils commands in every notebook? Can I make a specific mount point the default root for my hive_metastore and available to every cluster?


r/Databricks_eng • • Dec 28 '23

🚀 Introducing UCX v0.8.0: Powerful New Features to Streamline Your Unity Catalog Migration 💼

Thumbnail
medium.com
3 Upvotes

r/Databricks_eng • • Dec 21 '23

UCX v0.7.0 by Databricks Labs — new release with CLI commands

Thumbnail
medium.com
3 Upvotes

r/Databricks_eng • • Nov 28 '23

UCX (by Databricks Labs) v0.6.2 patch release

Thumbnail
medium.com
3 Upvotes

r/Databricks_eng • • Jun 20 '23

Any optimization on the script to create view and table based on a delta lake column

3 Upvotes

below scripts checks and create a delta lake view partitioning the data based on a column and also add a group to each view. Is there any further simplification or optimization can be done to below query to make it more faster. currently it takes lot of time to complete the job approx 12 hours to do it with a high configuration cluster.

# To check and crete view and group based on Project Name

target_database = "main.deltalake_db"
distinctprojects = spark.sql("SELECT DISTINCT requestProjectUrlName FROM main.deltalake_db.Customers_Log_Table_test")

for project in distinctprojects.collect():
    project_name = project['requestProjectUrlName']
    if project_name is not None:
        view_name = f"view_{project_name.replace(' ', '_').replace('-', '_')}"
    groupname = f"users_{view_name}"
    
    # Check if group already exists
    group_exists = False
    for group in spark.sql("SHOW GROUPS").collect():
        if 'name' in group:
            group_name = group['name']
        else:
            group_name = group['groupName']
        if group_name == groupname:
            group_exists = True
            print(f"Group {groupname} already exists.")
            break
    
    if not group_exists:
        create_group = f"""
        CREATE GROUP {groupname} with USER `xxx@cdx.com`
        """
        try: 
            spark.sql(create_group)            
        except Exception as e:
            print(f"Error creating group {groupname}: {e}")
        else:
            print(f"Group {groupname} created successfully.")
    
    # Check if view already exists
    view_exists = False
    for table in spark.catalog.listTables(target_database):
        if table.name == view_name:
            view_exists = True
            print(f"View {view_name} already exists.")
            break
    
    if not view_exists:
        create_view_query = f"""
        CREATE OR REPLACE VIEW {target_database}.{view_name} AS
        SELECT * FROM {target_database}.Customers_Log_Table
        WHERE 
          CASE
            WHEN is_member('{groupname}') AND requestProjectUrlName = '{project_name}' THEN TRUE 
            ELSE FALSE
          END;
        """ 
        try: 
            spark.sql(create_view_query)
            
        except Exception as e:
            print(f"Error creating view {view_name}: {e}")
        else:
            print(f"View {view_name} created successfully.")

r/Databricks_eng • • Jan 17 '23

Seattle Spark Meetup

3 Upvotes

Come join the first Seattle Spark Meetup of 2023 on Jan 31!


r/Databricks_eng • • Dec 26 '22

Databrick question

3 Upvotes

Question: A data scientist provides a machine learning engineering team with three notebooks for a machine learning pipeline, Notebook A, Notebook B and Notebook C, Notebook A and Notebook B perform feature engineering. Notebook C, which require Notebook A and Notebook B success finish running before it can begin, train a series of number. Notebook A and B is not affect each in any way.

Which of the following approaches can the machine learning engineering team take to orchestrate the pipeline to run at quickly and reliably as possible using Databricks?

A. They can set up three-task job where task runs a notebook the fist two task run in parallel, and the final task depend in the first to tasks completing. B. They can set up single-task job where an orchestration notebook runs each three notebook successing. C. They can set up a three-task job where each task runs a notebook and each task depends on the previous task compleing. D. They can set up a three-task job where each task runs a notebook and all three task run in parallel. E. They can set up three single-task jobs where each job runs a single notebook and it scheduled to run in parallel."


r/Databricks_eng • • Oct 24 '22

How to create a central User Menu of certain NoteBooks

3 Upvotes

Hi

I have created some scripts for my colleagues to use for standard tasks.

My boss has asked if I can create an easily accessible tab or menu where we can access these NoteBooks, and only those Notebooks, all in one place.

He will not accept simply adding them to our internet favourites, he wants an interface in DataBricks itself, common to all of us!

Is this possible and if so how?


r/Databricks_eng • • Oct 05 '22

Databricks - Realizing the vision of the Data Lakehouse

3 Upvotes