Transferring data from Columns to rows, not using a Pivot table

russelldt

Board Regular
Joined
Feb 27, 2021
Messages
158
Office Version
  1. 365
Platform
  1. MacOS
I am reposting this, as I have not had a workable response - probably due to me not describing the problem eloquently.

I have a excel file with 2 sheets.

Sheet 1 has "Job Number" in Column C, and empty cells for Invoice numbers, in columns M, N, O, P, Q and R

Sheet 2 has a dump from an accounting package, and the data is organized in columns. Column A has Job Number, Column B has the invoice number and Column C has the Paid flag. There are many invoices per job.


I need the invoice numbers and Paid status from Sheet 2 to go into Sheet 1against the correct job number. The first invoice number for a Job, to go in column M, the second on N, and so on. Once the invoice is flagged as paid, the invoice number must show a P after (e.g 1956, and once paid 1956P).

Any of the geniuses out there able to help?
 

Excel Facts

Will the fill handle fill 1, 2, 3?
Yes! Type 1 in a cell. Hold down Ctrl while you drag the fill handle.
It would be easier to help if you could use the XL2BB add-in (icon in the menu) to attach screenshots (not pictures) of your two sheets. Alternately, you could upload a copy of your file to a free site such as www.box.com or www.dropbox.com. Once you do that, mark it for 'Sharing' and you will be given a link to the file that you can post here. Explain in detail what you want to do referring to specific cells, rows, columns and sheets using a few examples from your data (de-sensitized if necessary).
 
Upvote 0
With Excel 365 in your hand that is very much possible with XLOOKUP if I'm not wrong.

If you can figure out, that's good. Else share a sample data using XL2BB to help you out
 
Upvote 0
an example:

Book2
ABCDEFGHIJ
1JobInvoicePaidJobInvoices
2852057749TRUE123040623P464276404975582
3123040623TRUE336218079
4671777302FALSE366738665P
5852074448FALSE671775497P77302
6123064049FALSE841655639
7852094210FALSE852022062P57749P7444894210
8841655639FALSE870960800P
9870960800TRUE
10852022062TRUE
11123046427FALSE
12336218079FALSE
13366738665TRUE
14123075582FALSE
15671775497TRUE
16
Sheet1
Cell Formulas
RangeFormula
E2:E8E2=SORT(UNIQUE(A2:A15))
F2:I2,F7:I7,F5:G5,F3:F4,F6,F8F2=LET(a,SORT(FILTER($A$2:$C$15,$A$2:$A$15=E2),2), i, INDEX(a,,2),p, INDEX(a,,3),TRANSPOSE( IF(p, i&"P", i)))
Dynamic array formulas.
 
Upvote 0
an example:

Book2
ABCDEFGHIJ
1JobInvoicePaidJobInvoices
2852057749TRUE123040623P464276404975582
3123040623TRUE336218079
4671777302FALSE366738665P
5852074448FALSE671775497P77302
6123064049FALSE841655639
7852094210FALSE852022062P57749P7444894210
8841655639FALSE870960800P
9870960800TRUE
10852022062TRUE
11123046427FALSE
12336218079FALSE
13366738665TRUE
14123075582FALSE
15671775497TRUE
16
Sheet1
Cell Formulas
RangeFormula
E2:E8E2=SORT(UNIQUE(A2:A15))
F2:I2,F7:I7,F5:G5,F3:F4,F6,F8F2=LET(a,SORT(FILTER($A$2:$C$15,$A$2:$A$15=E2),2), i, INDEX(a,,2),p, INDEX(a,,3),TRANSPOSE( IF(p, i&"P", i)))
Dynamic array formulas.
an example:

Book2
ABCDEFGHIJ
1JobInvoicePaidJobInvoices
2852057749TRUE123040623P464276404975582
3123040623TRUE336218079
4671777302FALSE366738665P
5852074448FALSE671775497P77302
6123064049FALSE841655639
7852094210FALSE852022062P57749P7444894210
8841655639FALSE870960800P
9870960800TRUE
10852022062TRUE
11123046427FALSE
12336218079FALSE
13366738665TRUE
14123075582FALSE
15671775497TRUE
16
Sheet1
Cell Formulas
RangeFormula
E2:E8E2=SORT(UNIQUE(A2:A15))
F2:I2,F7:I7,F5:G5,F3:F4,F6,F8F2=LET(a,SORT(FILTER($A$2:$C$15,$A$2:$A$15=E2),2), i, INDEX(a,,2),p, INDEX(a,,3),TRANSPOSE( IF(p, i&"P", i)))
Dynamic array formulas.
an example:

Book2
ABCDEFGHIJ
1JobInvoicePaidJobInvoices
2852057749TRUE123040623P464276404975582
3123040623TRUE336218079
4671777302FALSE366738665P
5852074448FALSE671775497P77302
6123064049FALSE841655639
7852094210FALSE852022062P57749P7444894210
8841655639FALSE870960800P
9870960800TRUE
10852022062TRUE
11123046427FALSE
12336218079FALSE
13366738665TRUE
14123075582FALSE
15671775497TRUE
16
Sheet1
Cell Formulas
RangeFormula
E2:E8E2=SORT(UNIQUE(A2:A15))
F2:I2,F7:I7,F5:G5,F3:F4,F6,F8F2=LET(a,SORT(FILTER($A$2:$C$15,$A$2:$A$15=E2),2), i, INDEX(a,,2),p, INDEX(a,,3),TRANSPOSE( IF(p, i&"P", i)))
Dynamic array formulas.

Thanks John exactly what I am looking for, but my version of Excel does not include Dynamic Array.

Is there another solution you could suggest?
 
Upvote 0
It would be easier to help if you could use the XL2BB add-in (icon in the menu) to attach screenshots (not pictures) of your two sheets. Alternately, you could upload a copy of your file to a free site such as www.box.com or www.dropbox.com. Once you do that, mark it for 'Sharing' and you will be given a link to the file that you can post here. Explain in detail what you want to do referring to specific cells, rows, columns and sheets using a few examples from your data (de-sensitized if necessary).
With Excel 365 in your hand that is very much possible with XLOOKUP if I'm not wrong.

If you can figure out, that's good. Else share a sample data using XL2BB to help you out
Hello Sanjay, unfortunately I don't have the latest version that used Dynamic Array

I have the XL2BB add-on loaded, and sample data added. What do I need to do next.

Thank you
 
Upvote 0
I see the sample data from JGordon but I don't see the data you posted.
 
Upvote 0
I see the sample data from JGordon but I don't see the data you posted.
1664896722724.png
 
Upvote 0
What does Sheet1 look like?
 
Upvote 0
What does Sheet1 look like?
I was thinking that the solution could be added to this sheet, and I will link the cells in sheet 1 to the sheet. The layout proposed by JGorden is perfect, as I can then add the links to sheet 1 from there. So in effect, sheet I does not need to be part of the solution.

I dont Have dynamic ranges, so can’t use the sort and other functions
 
Upvote 0

Forum statistics

Threads
1,215,528
Messages
6,125,338
Members
449,218
Latest member
Excel Master

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top