Get certified for free when you join Fabric Data Days 2026 and dive into Fabric, Power BI, SQL, AI, and other essential data skills.
Join nowJuly 7 - July 17 | Round 2 of the Power BI Dataviz World Championships. Don't miss your chance! Learn more
Good afternoon everyone, I need help bringing information from my previous line, I will describe here what I am doing.
Based on the table below:
From this table I need to add another column named "Recurso" where I must put the name that comes before the dates.
Use the formula below to find the name:
= Table.AddColumn(#"Inserção de Coluna Index", "Recurso", each
let
CurrentData = [Data],
PreviousData = if [Index] > 0 then {[Index]-1}[Recurso] else null
in
if Text.Contains(CurrentData, "/") then PreviousData else CurrentData
)
What I'm not able to solve is copying the information from the previous line "Recurso" and rewriting it in the "Recurso" column when my column is a date, below is the image of the result obtained:
Solved! Go to Solution.
Do you mean you want to get the name for each section on the same row as the date?
--
I think the code provided can be simplified:
if Text.Contains([Data], "/") then null else [Data])
then do a Fill.Down on the column
Do you mean you want to get the name for each section on the same row as the date?
--
I think the code provided can be simplified:
if Text.Contains([Data], "/") then null else [Data])
then do a Fill.Down on the column
You're right, I didn't understand at first, setting everything to null I can do the filldown later.
Thank you very much.
What I need is that when it doesn't identify the "/" of the date, it retrieves the information from the previous line that I'm filling in.
Example, if you don't find "/" take the name information and write it in "Recurso", if you don't find "/" return the name placed on the previous line of "Recurso"
Join us in Barcelona for FabCon and SQLCon, the Fabric, Power BI, SQL, and AI community event. Save €200 with code FABCMTY200.
Join Fabric Data Days 2026: 60 days of free live/on-demand sessions, challenges, study groups, and certification opportunities.
| User | Count |
|---|---|
| 8 | |
| 6 | |
| 5 | |
| 5 | |
| 4 |