I can't delete a category because it is a foreign key in the items table. How can I do it? How can I make a deletion in category and make $category_id null in the items table?
I tried making a delete function but it sends an error saying it can't because it is a foreign key.