Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

copy rows from one worksheet to another

I have a master inventory sheet (cameras, support, lenses...) and would like to reference the master sheet to build smaller sub-sheets such as camera inventory and lens inventory.


In theory, all I need to do is a direct copy of the entire row from the 'Master' sheet to the 'Camera' sheet. What ever is updated in the master is automatically changed into the other sub-sheets.


Any suggestions would help! Also, if a cell is blank in the master, it will should remain blank in the sub.


-Alfeo

iMac, OS X Mountain Lion (10.8.2)

Posted on May 24, 2015 8:39 AM

Reply
7 replies

May 24, 2015 9:51 AM in response to Alfeo Dixon

Hi Alfeo,


Here are two approaches one robust and one simple.

The simple:

=master::A1

this goes into your summary table pointing at the row you want for that table. You fill it across.

User uploaded file

=INDEX(master::B,MATCH(A2,master::A,0), 1,area-index)

This formula will search in the master for the value in A2. I will use the found row to return a value. Fill it across. This will continue to work if the rows in the master are rearranged.


quinn

May 24, 2015 11:11 AM in response to t quinn

I see where your heading with this...


I can't quite figure out how to adapt it to my tables, I'm new to both of these functions.


BarCode

Description


Serial

Purchase

Replacement

Rate

Date Purchased

Vendor

Part #

Notes


CAMERA 100










101

Arri ALEXA XT Camera Body


6724

$69,600.00


2500


AbelCine

AR-800101




Arri ProRes Codec Option for Alexa


$5,196.00




AbelCine

AR-800301




Arri QuickTime File Format Option for Alexa


$742.00




AbelCine

AR-800302




Arri Anamorphic De-Squeeze License w. Camera


$920.00




AbelCine

AR-800349




Arri Alexa High Speed License (with Camera)


$2,100.00




AbelCine

AR-800324




Arri ALEXA Battery Adapter Back for Gold Mount (BAB-G)


$438.00




AbelCine

AR-801200


110

Arri ALEXA EVF-1 Electronic Viewfinder


2454

$4,950.00

$9,104.00



3rd Party

AR-800200


111

Arri Alexa Viewfinder Cable Short (0.35m/1.2ft) KC 150- S



$396.00




AbelCine

AR-800204


112

Arri Alexa Viewfinder Cable Medium (0.65m/2.1ft) KC



$413.00




AbelCine

AR-800208


113

Arri Alexa VMB-3 Viewfinder Mount



$1,110.00




AbelCine

AR-800214




More importantly is that I have to match up barcode numbers in the A Column and the barcodes are subdivided into 100's for camera, 200's for accessories and 300's for support... etc.


-Alfeo

May 24, 2015 11:23 AM in response to Alfeo Dixon

Hi Alfeo,


What are you saying about barcodes? Is that something you want to search for? Are they unique yet describe whether an item is a lens, camera, support, etc.? Not every row has one. They do not look useful as an index.


What you need to automatically pull rows into another table is a consistent descriptive. If you had a column for "camera", "lens", "support", etc. you could create an index column to alow you to pull, for instance, any new camera purchase into a camera table.


Another concideration is how you want the items to show up in your summary tables. Is date entered in the master sufficient? Is there another consistent approach across all types that you prefer?


quinn

May 24, 2015 7:59 PM in response to Alfeo Dixon

Hello


If I understand it correctly, you may try the following scheme using barcode ranges (100s, 200s, etc) to indentify categories (camera, accessory, etc). It introduces auxiliary columns L and M in MASTER and L in each summary table.



User uploaded file



MASTER (excerpt) A1 BarCode A2 100 A3 101 A4 A5 A6 110 A7 111 A8 A9 200 A10 201 A11 A12 A13 202 A14 L1 L2 =IF(LEN(A2)>0,A2,OFFSET(L$1,ROW()-2,0)) L3 =IF(LEN(A3)>0,A3,OFFSET(L$1,ROW()-2,0)) L4 =IF(LEN(A4)>0,A4,OFFSET(L$1,ROW()-2,0)) L5 =IF(LEN(A5)>0,A5,OFFSET(L$1,ROW()-2,0)) L6 =IF(LEN(A6)>0,A6,OFFSET(L$1,ROW()-2,0)) L7 =IF(LEN(A7)>0,A7,OFFSET(L$1,ROW()-2,0)) L8 =IF(LEN(A8)>0,A8,OFFSET(L$1,ROW()-2,0)) L9 =IF(LEN(A9)>0,A9,OFFSET(L$1,ROW()-2,0)) L10 =IF(LEN(A10)>0,A10,OFFSET(L$1,ROW()-2,0)) L11 =IF(LEN(A11)>0,A11,OFFSET(L$1,ROW()-2,0)) L12 =IF(LEN(A12)>0,A12,OFFSET(L$1,ROW()-2,0)) L13 =IF(LEN(A13)>0,A13,OFFSET(L$1,ROW()-2,0)) L14 =IF(LEN(A14)>0,A14,OFFSET(L$1,ROW()-2,0)) M1 M2 =INT(L2/100)*100&"-"&COUNTIFS(OFFSET(L$1,0,0,ROW(),1),">="&INT(L2/100)*100,OFFSET(L$1,0,0,ROW(),1),"<"&INT(L2/100+1)*100) M3 =INT(L3/100)*100&"-"&COUNTIFS(OFFSET(L$1,0,0,ROW(),1),">="&INT(L3/100)*100,OFFSET(L$1,0,0,ROW(),1),"<"&INT(L3/100+1)*100) M4 =INT(L4/100)*100&"-"&COUNTIFS(OFFSET(L$1,0,0,ROW(),1),">="&INT(L4/100)*100,OFFSET(L$1,0,0,ROW(),1),"<"&INT(L4/100+1)*100) M5 =INT(L5/100)*100&"-"&COUNTIFS(OFFSET(L$1,0,0,ROW(),1),">="&INT(L5/100)*100,OFFSET(L$1,0,0,ROW(),1),"<"&INT(L5/100+1)*100) M6 =INT(L6/100)*100&"-"&COUNTIFS(OFFSET(L$1,0,0,ROW(),1),">="&INT(L6/100)*100,OFFSET(L$1,0,0,ROW(),1),"<"&INT(L6/100+1)*100) M7 =INT(L7/100)*100&"-"&COUNTIFS(OFFSET(L$1,0,0,ROW(),1),">="&INT(L7/100)*100,OFFSET(L$1,0,0,ROW(),1),"<"&INT(L7/100+1)*100) M8 =INT(L8/100)*100&"-"&COUNTIFS(OFFSET(L$1,0,0,ROW(),1),">="&INT(L8/100)*100,OFFSET(L$1,0,0,ROW(),1),"<"&INT(L8/100+1)*100) M9 =INT(L9/100)*100&"-"&COUNTIFS(OFFSET(L$1,0,0,ROW(),1),">="&INT(L9/100)*100,OFFSET(L$1,0,0,ROW(),1),"<"&INT(L9/100+1)*100) M10 =INT(L10/100)*100&"-"&COUNTIFS(OFFSET(L$1,0,0,ROW(),1),">="&INT(L10/100)*100,OFFSET(L$1,0,0,ROW(),1),"<"&INT(L10/100+1)*100) M11 =INT(L11/100)*100&"-"&COUNTIFS(OFFSET(L$1,0,0,ROW(),1),">="&INT(L11/100)*100,OFFSET(L$1,0,0,ROW(),1),"<"&INT(L11/100+1)*100) M12 =INT(L12/100)*100&"-"&COUNTIFS(OFFSET(L$1,0,0,ROW(),1),">="&INT(L12/100)*100,OFFSET(L$1,0,0,ROW(),1),"<"&INT(L12/100+1)*100) M13 =INT(L13/100)*100&"-"&COUNTIFS(OFFSET(L$1,0,0,ROW(),1),">="&INT(L13/100)*100,OFFSET(L$1,0,0,ROW(),1),"<"&INT(L13/100+1)*100) M14 =INT(L14/100)*100&"-"&COUNTIFS(OFFSET(L$1,0,0,ROW(),1),">="&INT(L14/100)*100,OFFSET(L$1,0,0,ROW(),1),"<"&INT(L14/100+1)*100)



CAMERA (excerpt) A1 BarCode A2 =IF(LEN($L2)=0,"",IF(ISBLANK(INDEX(MASTER::$A:$K,$L2,COLUMN())),"",INDEX(MASTER::$A:$K,$L2,COLUMN()))) B1 Description B2 =IF(LEN($L2)=0,"",IF(ISBLANK(INDEX(MASTER::$A:$K,$L2,COLUMN())),"",INDEX(MASTER::$A:$K,$L2,COLUMN()))) C1 C2 =IF(LEN($L2)=0,"",IF(ISBLANK(INDEX(MASTER::$A:$K,$L2,COLUMN())),"",INDEX(MASTER::$A:$K,$L2,COLUMN()))) D1 Serial D2 =IF(LEN($L2)=0,"",IF(ISBLANK(INDEX(MASTER::$A:$K,$L2,COLUMN())),"",INDEX(MASTER::$A:$K,$L2,COLUMN()))) E1 Purchase E2 =IF(LEN($L2)=0,"",IF(ISBLANK(INDEX(MASTER::$A:$K,$L2,COLUMN())),"",INDEX(MASTER::$A:$K,$L2,COLUMN()))) F1 Replacement F2 =IF(LEN($L2)=0,"",IF(ISBLANK(INDEX(MASTER::$A:$K,$L2,COLUMN())),"",INDEX(MASTER::$A:$K,$L2,COLUMN()))) G1 Rate G2 =IF(LEN($L2)=0,"",IF(ISBLANK(INDEX(MASTER::$A:$K,$L2,COLUMN())),"",INDEX(MASTER::$A:$K,$L2,COLUMN()))) H1 Date Purchased H2 =IF(LEN($L2)=0,"",IF(ISBLANK(INDEX(MASTER::$A:$K,$L2,COLUMN())),"",INDEX(MASTER::$A:$K,$L2,COLUMN()))) I1 Vendor I2 =IF(LEN($L2)=0,"",IF(ISBLANK(INDEX(MASTER::$A:$K,$L2,COLUMN())),"",INDEX(MASTER::$A:$K,$L2,COLUMN()))) J1 Part # J2 =IF(LEN($L2)=0,"",IF(ISBLANK(INDEX(MASTER::$A:$K,$L2,COLUMN())),"",INDEX(MASTER::$A:$K,$L2,COLUMN()))) K1 Notes K2 =IF(LEN($L2)=0,"",IF(ISBLANK(INDEX(MASTER::$A:$K,$L2,COLUMN())),"",INDEX(MASTER::$A:$K,$L2,COLUMN()))) L1 100 L2 =IFERROR(MATCH(L$1&"-"&ROW()-1,MASTER::M,0),"")





Notes.


Formulae in MASTER::L2:M2 can be filled down.


Formula in CAMERA::L2 can be filled down.


Formula in CAMERA::A2 can be filled down and right across CAMERA::A:K.


CAMERA and ACCESSORY tables are identical except for the value in L1, which specifies the base barcode value for the category.


You need to specify base barcode values in MASTER::A such as 100 in A2 and 200 in A9.


You can hide MASTER::L:M and CAMERA::L etc if you want to.


You can add or remove rows in MASTER. (As far as I can tell with Numbers v2, formulae in MASTER::M:L will be correctly filled in added rows even when inserted in-between.)


Tables are built with Numbers v2.



Good luck,

H


EDIT: replaced screen shot with correct one.

May 26, 2015 4:09 PM in response to Hiroto

Thanks Hiroto,


but it seems that I'm having a problem with the code grabbing the actual row instead of looking for the barcode.


User uploaded file


IF(LEN($L1)=0,"",IF(ISBLANK(INDEX('Updated: Wednesday, April 15, 2015'::$A:$Notes,$L1,COLUMN(cell))),"",INDEX('Updated: Wednesday, April 15, 2015'::$A:$Notes,$L1,COLUMN(cell))))


User uploaded file

IFERROR(MATCH(L$1&"-"&ROW()−1,#REF!,0),"")


'Updated: Wednesday, April 15, 2015' is my Sheet 1 "CAMERA" which I previously referred to as MASTER and Alexa SxS Subrental Inventory is what you are calling "Camera" and Sheet 2 will be my "Support" etc.


I was succesful in putting in my index and BarCode Index as you suggested... this is quite handy


User uploaded file

May 27, 2015 6:18 AM in response to Alfeo Dixon

Hello


Couple of comments.


1) You'd better uncheck "use header cell names for reference" in preferences especially when debugging formulae.



2) Numbers containers have following containment hierarchy:


document > sheet > table > range



And the full referencing descriptor in formula is in the form as sheet::table::range. If the table name is unique in document or referent table is in the same sheet as the table where referencing formula resides, you may omit sheet name.


E.g. In my example bulit with Numbers v2, MASTER is a table name in sheet 'Sheet 1' and its full descripter is 'Sheet 1'::MASTER. In your example, CAMERA is a sheet name and 'Updated: Wednesday, April 15, 2015' is a table name and its full descriptor is CAMERA::'Updated: Wednesday, April 15, 2015'.


In other words, mapping table between my references and yours would be:


'Sheet 1'::MASTER => CAMERA::'Updated: Wednesday, April 15, 2015' 'Sheet 1'::CAMERA => 'Alexa SxS Subrental Inventory'::? * I don't know the table name in your latter sheet.




3) You're using wrong cell address $L1, which should have been $L2, in your formula in A2 in a summary table. Also your formula in L2 contains reference error (#REF!). Correct formulae would have been as follows.



Formulae (excerpt) for sheet = Alexa SxS Subrental Inventory table = ? A1 BarCode A2 =IF(LEN($L2)=0,"",IF(ISBLANK(INDEX(CAMERA::'Updated: Wednesday, April 15, 2015'::$A:$K,$L2,COLUMN())),"",INDEX(CAMERA::'Updated: Wednesday, April 15, 2015'::$A:$K,$L2,COLUMN()))) A3 =IF(LEN($L3)=0,"",IF(ISBLANK(INDEX(CAMERA::'Updated: Wednesday, April 15, 2015'::$A:$K,$L3,COLUMN())),"",INDEX(CAMERA::'Updated: Wednesday, April 15, 2015'::$A:$K,$L3,COLUMN()))) A4 =IF(LEN($L4)=0,"",IF(ISBLANK(INDEX(CAMERA::'Updated: Wednesday, April 15, 2015'::$A:$K,$L4,COLUMN())),"",INDEX(CAMERA::'Updated: Wednesday, April 15, 2015'::$A:$K,$L4,COLUMN()))) . . . L1 100 L2 =IFERROR(MATCH(L$1&"-"&ROW()−1,CAMERA::'Updated: Wednesday, April 15, 2015'::M,0),"") L3 =IFERROR(MATCH(L$1&"-"&ROW()−1,CAMERA::'Updated: Wednesday, April 15, 2015'::M,0),"") L4 =IFERROR(MATCH(L$1&"-"&ROW()−1,CAMERA::'Updated: Wednesday, April 15, 2015'::M,0),"")



* Sheet name "CAMERA" may be optional if the table name is unique in document.


* If you check "use header cell names for reference" in preferences, the column reference M in formulae in L will be replaced with header cell name that is Index such as


CAMERA::'Updated: Wednesday, April 15, 2015'::Index



which might be problematic due to name conflict with function name (INDEX) and indeed would be the cause of reference error you're getting. At least it must be quoted such as


CAMERA::'Updated: Wednesday, April 15, 2015'::'Index'




Hope this may help,

H


EDIT: fixed typos

copy rows from one worksheet to another

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple ID.