Form not saving all fields to DB

How to fix new form fields not saving to the database.

Overview

The issue occurs because ChronoForms caches the database table structure, so newly added columns are not recognized immediately.
After adding columns to your database table, clear the CF cache by clicking the Delete Cache icon in the Forms Manager to update its records and allow the new fields to save.

Answered
ph pharms 03 Dec, 2014
I had the form saving the required fields to a DB table, but then I added some more fields to the form that I also want to save.

I deleted the DB table and recreated it after adding the fields, I deleted the Save DB event and re-created it, but the form refuses to save the new field data. I've done this a couple times, but the fields that get saved do not update.

I've attached the debug output as a file, the correct fields are displayed in the array but the "insert into " command does not have all the fields ([delivery_options] and [recording_type] are missing, even though they have data).

The DB structure is correct (it was created by chronoforms) - the fields names match the column names.

Sensitive data has been removed from the debug output.

Any help gratefully appreciated!

Peter
Gr GreyHead 03 Dec, 2014
Answer
1 Likes
Hi Peter,

You can add new columns to an existing table but you then need to click the Delete Cache icon in the Forms Manager to update CF's records as it keeps these for 24 hours. Please see this FAQ

Bob
ph pharms 04 Dec, 2014
Thanks Bob, it's now working, and I will buy you a coffee...
This topic is locked and no more replies can be posted.