Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
jolulo
New Member

Tabla de clientes sin facturas en un periodo determinado

Buenas tardes!

Antes de nada decir que soy nuevo en el foro y en Power bi, por lo que os pido disculpas de antemano si no es el sitio adecuado para este Post. Paso a exponer mi problema sin mas dilacion:

 

Tengo un fichero de clientes, con los campos tipicos: Codigo de cliente, Nombre del cliente, Direccion, ... (logicamente la clave unica del fichero es el codigo de cliente). Y un fichero de facturas con tambien los campos tipicos: Nº de Factura (Clave Unica), Fecha de factura, Código de cliente (para relacionarlo con el fichero de cliente), importe factura... etc.

 

Logicamente la relacion clientes -- facturas en 1:n

Pues Bien: 

Necesito visalizar una tabla con la relacion de clientes a los que no se les ha emitido una factura en un periodo seleccionado por pantalla.

 

He probado con una medida y una nueva columna con un contador de facturas por cliente, pero en cuanto aplico el filtro por fechas, logicamente no me funciona.

 

No se si me he explicado bien

 

Alguna Idea?

 

Muchas Gracias por vuestra ayuda

 

Un Saludo

 

Jose Luis

1 ACCEPTED SOLUTION
BA_Pete
Super User
Super User

Hi Jose Luis,

 

Create a proper calendar table for your model (there's plenty of examples online of how to do this) and relate this to your Invoices table on Calendar[Date] 1:n Invoices[Invoice Date].

Create a basic measure in your Invoices table like this:

_noofInvoices = DISTINCTCOUNT(Invoices[Invoice Number])

Then add Clients[Client Name] into a table visual, and add a visual-level filter that is [_noofInvoices] = 0 or [_noofInvoices] is Blank.

Right-click on Clients[Client Name] in the Values section on the Visualisations pane and choose 'Show items with no data'.

Use Calendar[Date] for the page slicers to select the period to view.

 

I've attached a working PBIX at the bottom of this post.

 

Pete



Now accepting Kudos! If my post helped you, why not give it a thumbs-up?

Proud to be a Datanaut!




View solution in original post

2 REPLIES 2
BA_Pete
Super User
Super User

Hi Jose Luis,

 

Create a proper calendar table for your model (there's plenty of examples online of how to do this) and relate this to your Invoices table on Calendar[Date] 1:n Invoices[Invoice Date].

Create a basic measure in your Invoices table like this:

_noofInvoices = DISTINCTCOUNT(Invoices[Invoice Number])

Then add Clients[Client Name] into a table visual, and add a visual-level filter that is [_noofInvoices] = 0 or [_noofInvoices] is Blank.

Right-click on Clients[Client Name] in the Values section on the Visualisations pane and choose 'Show items with no data'.

Use Calendar[Date] for the page slicers to select the period to view.

 

I've attached a working PBIX at the bottom of this post.

 

Pete



Now accepting Kudos! If my post helped you, why not give it a thumbs-up?

Proud to be a Datanaut!




Hi Pete!

Thank you very much for your help!

I'm going to try it right now

 

Regards

Helpful resources

Announcements
Europe Fabric Conference

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

AugPowerBI_Carousel

Power BI Monthly Update - August 2024

Check out the August 2024 Power BI update to learn about new features.

August Carousel

Fabric Community Update - August 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors
Top Kudoed Authors