Bulk Insert Pictures to a Collection from a directory on your desktop

Hi, I have a directory that has ~1200ish small sized pictures that I want to bulk upload to my collection (database). For the collection all I am going to have for the fields would be the pictures saved name (which I believe automatically becomes the pictures title field in the collection and the picture itself as a field

Also I want to be able to update this collection periodically. Is there anyway to fully delete out the contents of the collection to then re-bulk insert again.

You can try importing data to your collection using code or a CSV file:
https://support.wix.com/en/article/corvid-tutorial-importing-and-exporting-collection-data-with-code
https://support.wix.com/en/article/importing-data-to-a-database-collection

In order to delete all database records you can implement a solution described in this forum post: https://www.wix.com/corvid/forum/community-discussion/all-row-delete-in-collections

Hi Angelina,

Thanks for the links for reference. Still stuck on both asks but let me try to get the delete portion correct before moving on to the import ask. Here’s where I have gotten so far based off referencing the links —

I have a database named “OTC Bar Charts 40D”. I created a page called “buttons” and added that database as a dataset to the page. The ID of that dataset is called #dataset1. I have button on the page that onClick will execute code to delete the items in the database. (Ref Pic 1) When I click the button in preview mode of the site I receive #dataset1 does not exist. (Ref Pic 2)

Pic 1:

Pic 2: (This is from when I was in preview mode of the website and clicking the button)

Oh I should add that in Pic one I did try for the name of the collection the actual name of the collection “OTC Bar Charts 40D”, “OTC Bar Charts” <— which is the name on the dataset icon on the page, and “dataset1” which is the id of the dataset because I thought the error could’ve been that I had the name of the collection wrong. Unfortunately none of them ended up working. Also forgot to add that the dataset on the page is set up for read write (Ref Pic 3)