Open In App

How to Group Adjacent Columns or Rows Separately or Independently in Excel?

Last Updated : 04 Jan, 2023
Improve
Improve
Like Article
Like
Save
Share
Report

Excel comes with a range of tools and functions to work with complex spreadsheets easily. There are various options to organize content so that it makes more sense and lets one work effectively. Grouping adjacent rows and columns are one such feature that we can use to organize data effectively in Excel. But there is a catch. What if we want to make a number of independent groups out of adjacent rows or columns and not one? Well, we can do that but not with the normal group function that groups the entire rows or columns into one. Let us learn how we can group adjacent rows or columns independently in Excel. 

Steps to Group Adjacent Columns or Rows Separately or Independently in Excel

Here, we have an excel sheet where we want to make two groups out of these columns, subjects, and marks. 

Dataset

 

Now, let us try grouping the three subjects and the three marks into separate groups by using the Group function of Excel. First, select the three subject columns and go to the group section in the Data tab. A pop-up box will appear and ask if you want to group rows or columns. For this case, we will select columns. 

Group-function

 

Now, when you will click on ok, you will see that a group is formed that you can collapse or expand. 

Group-in-data

 

Now repeat the same steps to group the marks columns together. Did you notice that instead of two groups, the entire six columns are merged together to form a single group? Here is how it looks now. 

Group-function

 

So now, you understand how the group function is not helping us in creating independent groups. Let’s see how we can solve this problem and how we can avoid this mixing of two groups into one.  Follow the below steps to achieve two different groups of columns or rows. Note that here, we are grouping the columns, but the steps for grouping the rows also remain the same, except that you have to choose the rows option in the below pop-up.

Group-pop-up

 

Step 1: Click on column E and go to the insert option in the cells tab. Choose insert cells and a pop-up will appear where you have to select the entire column option and click ok. 

Choosing-insert-cell

 

Step 2: Once you click on ok, you will see a blank column in between the columns subject 3 and marks 1. 

Blank-column

 

Step 3: Now re-group the subject columns and mark columns separately using the group function as we did earlier. You will get the following output-

Separately-grouped-columns

 

You can see that although this method is not very clever, it still solves the problem and functions well. This time there are two outlines on the top showing the two different groups. If you collapse both groups, it will look like this, 

Collapsed-groups

 


Like Article
Suggest improvement
Share your thoughts in the comments

Similar Reads