I have a Files table connected to other tables such as Projects, Contacts, Tasks, and more.
Each project should have one row in the Files table containing all related files.
The issue I’m facing is that, in Projects, for example, when I set the field to be a File, I get this error:
Values in this column are calculated by a formula and can’t be manually changed.
This occurs across all relational tables linked to Files, and I haven’t found a way to resolve it. I need a normal file field where users can add or drop files directly.
Has anyone dealt with this before? Looking for a workaround or best approach.
I really sounds like something is wrong in your setup - what you want to do is entirely possible (although I don’t understand why you need a separate Files table.
Please share a (dummy or copy) doc that has the problem, I am sure one of us can help you.
I’m new to Coda and coming from Notion, so I might be approaching this the wrong way. However, at this point, I’d like to understand from a technical perspective why my approach isn’t working and what the best solution would be.
The general idea was to isolate as much data as possible into databases, allowing for more flexibility in how we work with the data down the line.
For example, in the Files database, we can add a checkbox column to mark files as private, effectively controlling who can and cannot access them.
@joost_mineur - i think there’s a bug currently? My last use was on the weekend when i was able to drag files into linked relation column in Table A (where the other linked table’s (i.e. Table B) display column is a file column). Currently if you want to add a file this way, you have to click “+ Add new” and then it creates a row in Table B automatically and names it row number i.e. #r13. Kinda like Coda is treating the File Column as formulaic column now?
There are too many things to make it easy to explain what how and why.
Please copy my copy with the changes to the Tasks table.
You have to be careful about setting the display column, because it affects filtering - it’s fixable, but it becomes complicated for a less experienced maker.
What I did to fix:
remove the formula from Files in the Task table
make the files column type text (because you want to show the files from another table, it is not a file column
in the table Files, make Projects the Display Column|
in the table Tasks, add a formula to the Files column: Files.Filter(Tasks.Contains(thisRow)).Files
I am not sure there is a bug. My corrections to what (I think) Edan is trying to do - I haven’t encountered any other issues.
The hard part is to really understand the logic of your (own) document. A file column is where you drop files, so you don’t want a file column with a formula (at least, that’s my perception).
demo of schema below.
on the weekend, i was able to drag a file into the “Files” column in Projects table. Then a row would be created in the FIles table with the file added to the “File” column.
Now when i drag a file into the “Files” colunmn in Projects table, nothing happens. and there are no rows added to Files table.
Im not saying it was a formulaic column, im saying its now like Coda treats the Files type column which is a Display column as a formulaic column e.g. not editable. and hence why i think its a bug?
adding manual files won’t work for obvious reasons.
instead you can remove the formula and create an automation that - once you added a file manually via drag & drop - creates a new row in the table of your liking.
I guess @joost_mineur can explain this better than I can
im gonna be brave and ask the higher ups if this behaviour (drag drop file into linked relation column of connected table with file column as display) has changed recently. i swear it worked on the weekend and im not gaslighting myself
but in the meantime, heres a possible solution to achieving your desired workflow
set linked relation column to display as “Open Button” and not “Value”.
the user should be able to click the table icon in the files cell and it will open up the modal to db files table. If there’s no row yet for the project, user can just click the “+” symbol at bottom of table and a row will be created with the project field auto populated with corresponding project.
user can drag and drop to the file column on db files.
attached below doc for your reference
Oh, on a side note- can you please enlighten us the use case/why in the DB Files table is set up in particular to 1 project = 1 line?
would you consider 1 file = 1 line and then group it by Project?
there are people with clunky fingers out there, and it would be less damage control involved if someone did a whoopsies and took out the files cell in one fell swoop.
At least in the 1 file = 1 line approach, if they wiped that cell, youll be able to rectify easier?
@Christiaan_Huizer pointed out (to me privately) that this can be done - @Melanie_Teh is already showing how to get started.
If you set the related column as Display as Open button, you can indeed edit the files in a two way sync matter - I was not aware of that.
You can set the Allow multiple selections to false, but in the modal you can still add extra items in existing rows.
Having said all that: I think using this setup will require pretty strict procedures regarding the use by your team. I played with this setup for a couple of minutes and I was able to introduce a couple of (for me) unwanted situations while adding or deleting files.
At this point in time I think I will not use it like this myself and I think I cannot really recommend it (even though, as said, it does work). Therefore this is probably my last comment in this particular thread.