You are viewing limited content. For full access, please sign in.

Question

Question

Forms Reports in SQL

asked on January 26, 2022

I am trying to run a SQL query that pulls Forms data.  I have successfully located the fields and field data using the cf_bp_data, cf_fields, cf_submissions and cf_bp_main_instances tables. I am getting multiple results for each Form (multiple submissions).  Our goal is to retrieve only 1 result for each form showing only the latest data.  Has anyone been able to successfully accomplish this?

0 0

Replies

replied on January 26, 2022

I did something similar for a process, but I didn't pull from the cf_bp_data table. I was only retrieving specific variables for one business process, so I used the formatted_variables table.

That table should only have one value per field per instance, and the attribute_id column identifies which variable/field the value belongs to.

Note that in that formatted_variables table, different data types are stored in different columns, text would be in value_string, numeric would be in value_decimal, and so on.

4 0
You are not allowed to follow up in this post.

Sign in to reply to this post.