Cross-doc modify row: how to reference the right row to modify?

Hi guys :wave:

I’m trying to set up a Cross-doc Modify Row action, but I’m completely stuck.

I have a Doc A with Table A and a Doc B with a Table B. I want to merge the data from A & B to an Overview Doc with Table X.

When data first gets entered in Table A, I can push the data to Table X via a Cross-Doc Add Row button in Table A. So far so good.

But now I also need a Cross-Doc Modify Row button to push changes made to a row in Table A that was already created in Table X via the Cross-Doc Add Row action. For that to work I need to specify which row needs to be modified in Table X.

I already added a column to Table A with it’s UID (generated via Split(thisRow+ "", "/").Last() which i found in this forum, thanks! ). When the Cross-Doc Add Row is executed it also sends the UID from Table A to Table X. I thought I could come up with a way to reference that UID in the Cross-Doc Modify Row formula, but alas I can’t get it to work.

I also thought of trying to push the rowURL from Table X to Table A once the row is created in Table X via the Cross-Doc Add Row action so I can reference that, but I can’t get that to work either.

What am I doing wrong here? Is there a way to fix the formula or is my method wrong to begin with? I’m trying to “push” changes to Table X, but maybe I should “pull” from Table A? (I don’t think so?)

I’d appreciate any pointers as I’m super confused rn. :pray:

Here’s a sample source doc:

And here’s a sample target doc:

Could you enable copy doc so that we can help you? Either that or share it with me in private chat I can see if I can help

Oops, sorry. But I think it is already enabled at Share > Published > Interaction & Appearance > Add a "Copy" button to the top of your doc?

https://coda.io/d/Test-Cross-Doc-Modify-Row-SOURCE_dnQbzckDZTC

https://coda.io/d/Test-Cross-Doc-Modify-Row-TARGET_dLLgQLFFWHt

Cross doc is frankly a disastrous user experience. But I got it working for you.

The only thing I would ask is whether you need to do it this way?

Why do you need to use the Cross doc modify row action? It may be possible to avoid all this nonsense by changing your schema.

1 Like

Thanks @cnr! :pray:

Yeah I get that cross-doc is not exactly Coda’s finest… But I don’t see another solution for my needs.

Again, my needs are different tables in different docs (Table A, B, C, etc.) that need to be merged in another Main Doc / Main table. The reason for the different docs/tables is that they are operated by different users (customers) who are not allowed to see each others data. I can’t think of a way to do this in 1 doc with different views.

Your solution looks decent to me though. Do you think it’s unstable? / Would you recommend me not using it? It would be a critical part of our company work-flow, so I need it to be as solid as possible.

Thanks again!

Hey cnr,

I got into the same issue. Could you please let me know the solution so that It will helpful for me.

Thanks,
Elam

Hi Elam! I’d have to know more about your setup. Could you share a sample doc?