Forum Discussion

KasperFB's avatar
KasperFB
Frequent Visitor
3 years ago
Solved

Add thick line between combine columns in table

Hi

I have the below table where each month column have two values and would like to add distinct lines between each month as the red ones (thank you MS paint).

I'm not able to find a relevant setting in the table settings. Does anyone know the correct setting?? 😀

 

 

  • In Power BI, adding distinct lines between combined columns in a table visual is not a built-in feature, and there's no direct setting in the table settings to achieve this. However, you can create the appearance of distinct lines by inserting a separate calculated column in your data that contains a delimiter (such as a vertical bar "|") between the combined columns. Then, you can use this calculated column in your table visual.

    Here are the steps to achieve this:

    1. Add a Calculated Column to Your Data:

      In Power BI's "Model" view or Power Query Editor, add a new calculated column to your data table. You can name it something like "Combined with Delimiter."

      In this calculated column, use a formula to combine the values from your existing columns along with a delimiter. For example, if you have two columns, [Month1] and [Month2], and you want to combine them with a vertical bar delimiter, your formula might look like this:

    Combined with Delimiter = [Month1] & " | " & [Month2]

     

    1. Adjust the formula to match your column names and desired delimiter.

    2. Use the Calculated Column in Your Table Visual:

      In your table visual, replace the existing columns with the "Combined with Delimiter" calculated column. Your table should now show the combined values with the delimiter.

    3. Format the Table Visual:

      To make the delimiter appear as a distinct line, you can format the table visual to emphasize it. Here's how:

      • Select the table visual.
      • In the "Visualizations" pane, under "Format," expand the "Table" section.
      • Adjust the "Text size" and "Font color" settings for the calculated column to make the delimiter larger and change its color to match the table borders.

      You may also want to adjust other formatting settings, such as row colors and column headers, to make the table appearance align with your desired style.

    By following these steps, you can create the illusion of distinct lines between combined columns in your table visual. Remember to customize the formatting to match your specific design preferences.

1 Reply

  • 123abc's avatar
    123abc
    Icon for Community Champion rankCommunity Champion

    In Power BI, adding distinct lines between combined columns in a table visual is not a built-in feature, and there's no direct setting in the table settings to achieve this. However, you can create the appearance of distinct lines by inserting a separate calculated column in your data that contains a delimiter (such as a vertical bar "|") between the combined columns. Then, you can use this calculated column in your table visual.

    Here are the steps to achieve this:

    1. Add a Calculated Column to Your Data:

      In Power BI's "Model" view or Power Query Editor, add a new calculated column to your data table. You can name it something like "Combined with Delimiter."

      In this calculated column, use a formula to combine the values from your existing columns along with a delimiter. For example, if you have two columns, [Month1] and [Month2], and you want to combine them with a vertical bar delimiter, your formula might look like this:

    Combined with Delimiter = [Month1] & " | " & [Month2]

     

    1. Adjust the formula to match your column names and desired delimiter.

    2. Use the Calculated Column in Your Table Visual:

      In your table visual, replace the existing columns with the "Combined with Delimiter" calculated column. Your table should now show the combined values with the delimiter.

    3. Format the Table Visual:

      To make the delimiter appear as a distinct line, you can format the table visual to emphasize it. Here's how:

      • Select the table visual.
      • In the "Visualizations" pane, under "Format," expand the "Table" section.
      • Adjust the "Text size" and "Font color" settings for the calculated column to make the delimiter larger and change its color to match the table borders.

      You may also want to adjust other formatting settings, such as row colors and column headers, to make the table appearance align with your desired style.

    By following these steps, you can create the illusion of distinct lines between combined columns in your table visual. Remember to customize the formatting to match your specific design preferences.