Been playing around with code on and off for a few weeks now. It is great and I have managed to do a few things that I needed for my site. A few questions on database collections:
i) Is there a way of deleting an unused collection and removing from my site structure?
ii) Is there a way of wiping all records from a collection before I do a fresh bulk submission? (I managed to get the bulk submission working - yeah)
iii) Recently got the bulk submission working, but one of my fields contains a number which I use for filtering results. I want this field to be text, but after submission the database has a red line under each field with a comment saying " Cell value type is Number. Change to Text. " When I try to filter with changing to text it doesn't work. When I Change to Text it does.
The column itself is marked as TEXT. Any ideas?
Hey Hugh,
I hope this helps. If you need more details, feel free to ask.
i) Currently, you cannot delete an unused collection. We are working on this.
ii) You can delete all the records in a collection with a bit of code. First you would query the collection to get all its items. Then you can use the remove function to delete those items. See the wix-data API reference for more info.
iii) This could do with how you imported the data. I'm assuming you used a JSON object. If you want the numbers in your JSON object to be understood as text, you need to enclose them in quotes.