-6

We have table A like this:

Name Website Description
Freelensia https://www.example.com  "Interpreter reservation platform"
フリレンシア https://www.example.com/ja "通訳予約プラットフォーム" 
"Phi Liên Á" https://www.example.com/vi "Nền tảng đặt hẹn với phiên dịch viên trực tuyến"
非連亜 https://www.example.com/zh "口譯預約平台"

where Name is the unique IDKey for this table.

Now, once in a while we would like to batch update table A with new values from table B like this:

Name Website Description
Freelensia [blank] "Reserve interpreters online"
フリレンシア [blank] "オンラインで通訳者を予約する" 
"Phi Liên Á" [blank] "Đặt lịch trực tuyến với phiên dịch viên"
  • Name will be the same
  • Cells with blank value will be treated as no change
  • Only rows where there are new values would be included. You can see the 4th (ID=非連亜) row of table A is not in table B, as there is no new value to be updated here.

Is there a macro that does something similar to this out there?

The real table A has about 2,000 rows and 20 columns.

gre_gor
  • 6,669
  • 9
  • 47
  • 52
Freelensia
  • 402
  • 6
  • 18

1 Answers1

0

Assuming your table B is in sheet2 and table A is in sheet1 then

Sub test()
    Sheets("Sheet2").Range("TableB").Copy
    Sheets("Sheet1").Range("TableA").PasteSpecial Paste:=xlPasteValues, _
                                                  Operation:=xlNone, SkipBlanks:=True, Transpose:=False
End Sub
Imran Malek
  • 1,709
  • 2
  • 13
  • 14
  • Thanks Imran, this looks promising especially the SkipBlanks attribute. However what if the 2 tables are not the same size? Table A is the master table, so it will include all of the rows (thousands), while table B is just for update purposes, it may have 5-6 rows at max. This macro will not work, I don't think.. – Freelensia Oct 11 '17 at 12:11
  • From your given example I could only figure that the cells which are not changing will be blank and the table size will be same.Could you give a proper screenshot of the both the tables ? – Imran Malek Oct 11 '17 at 12:27