Skip to main content
Question

delete field attachments

  • March 18, 2024
  • 0 replies
  • 174 views

Hello Quickbase community!

I can mass delete field attachments, using a date range, for example from 2016 to 2019, delete the data of that field, not the entire record.



------------------------------
Herberth Solano
------------------------------
This topic has been closed for replies.

Forum|alt.badge.img+9
  • Registered
  • March 18, 2024

Are you asking how you can? The API is the fastest way if you combine it with a Pipeline. You can use the Quickbase 'Request' action to hit the QB api and delete a file using an API_EditRecord like: 

<qdbapi>
<usertoken></usertoken>
<rid>[Record ID#]</rid>
<field fid="YOUR FIED" filename="delete"></field>
</qdbapi>

Your Pipeline would search for the records you want deleted, and the Request would delete the file.



------------------------------
Chayce Duncan
------------------------------

MarkShnierYou
Forum|alt.badge.img+24

You can use a Pipeline.  I suggest testing it on a demo app first or running the Pipeline with a small limit of say 5.

Actually I need to do this soon for a client because they are over there file attachment limits with Quickbase and rather than buy more space there are some that we can delete.   So, your lucky day, I just build a pipeline so I would know how to do it. 

In my case I started with a search where I was filtering on a checkbox formula field called [OK to delete file attachment] and the search specified the file attachment field and that checkbox field in the results.  Obviously I filtered on [OK to delete file] is Yes.

Inside the for each loop I did a native QuickBase Make Request step with this syntax  

(note my file attachment field ID was 7)

https://mycopany.quickbase.com/db/xxxxxxxx?act=API_EditRecord&rid={{a.id}}&_fid_7=&delfile_fid_7=1

(note because this is writing, it needs to set to "POST" method). 

That's it. Just a two step pipeline. Search and then for each loop to delete. 



------------------------------
Mark Shnier (Your Quickbase Coach)
mark.shnier@gmail.com
------------------------------