formtools / core

The Form Tools Core.
https://formtools.org
207 stars 78 forks source link

Views and reports not working #537

Open ejgagne opened 5 years ago

ejgagne commented 5 years ago

Hello,

I have installed Form Tools on Apache/Windows/MySQL, and have it working well, or so it seems. However after having inputted some testing data, to test reports and searches, my new views (reports/filters) will not return any data, even though there is data to list for those views. The default of "Form Builder View" does work however, but shows everything. I need to be able to create views to sort my data based on about a dozen criteria. Am I missing something to get this to work properly? Any help would be great.

Many thanks, Eric

benkeen commented 5 years ago

Hey Eric,

No there's nothing special you should need to do to make it work. By default when you create a new View it'll just show all data, only limiting the fields that you enter in the View fields tab. It sounds like maybe you added filters to your Views? Could you describe exactly what you entered for that. You used Standard Filters? Sounds like possibly it's just not making a match on your data set.

Ben

ejgagne commented 5 years ago

Hey Ben,

Thanks so much for getting back with me on this. You are correct that I created a new view, and that I did apply a filter/filters to the view. I will attach some screen shots showing the data I entered (table), a copy of the view with filter, and results of the view (report). I should have data in there that matches, but anything is possible. Thanks in advance for all of your help.

Best Regards,

Eric Gagne [image: ViewResult.jpeg] [image: FormBuilderView.jpeg] [image: Views1.jpeg] [image: Views2.jpeg]

On Fri, Apr 26, 2019 at 12:54 AM Benjamin Keen notifications@github.com wrote:

Hey Eric,

No there's nothing special you should need to do to make it work. By default when you create a new View it'll just show all data, only limiting the fields that you enter in the View fields tab. It sounds like maybe you added filters to your Views? Could you describe exactly what you entered for that. You used Standard Filters? Sounds like possibly it's just not making a match on your data set.

Ben

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/formtools/core/issues/537#issuecomment-486925224, or mute the thread https://github.com/notifications/unsubscribe-auth/AL5NO5MZJFXCRVEZHLPXPG3PSKDGTANCNFSM4HIPEBGQ .

-- Eric J. Gagne Sr. Network Systems Engineer Northampton Public Schools Northampton, Massachusetts (413) 587-1371 - Direct Line

--

Please consider the environment before printing this email.Remember when writing or responding to email, the Massachusetts Secretary of State has determined that e-mail is a public record. All electronic messages sent from the Northampton Public Schools are archived in conformance with Massachusetts and Federal Public Records law.

ejgagne commented 5 years ago

Hi Ben,

Any thoughts on the filtering? I have a nice project, but really can't go further until I can get the views and search sorted out. I hope it's a simple thing I am not seeing or doing. Many thanks in advance.

Eric

benkeen commented 5 years ago

Sorry Eric, I meant to get back you. It doesn't look like the screenshots made it, unfortunately, so I can't see them. Mind trying to re-attach?

If you temporarily remove the filter from your View, do you get data?

Secondly, if you don't mind doing a little brain surgery, try this. Add back your View filter. Then, in your [form tools root]/global/code/Submission.class.php file, go down to line 1063. You should see this block:

// (1) our main search query that returns a PAGE of submission info
try {
    $db->query("
        SELECT $select_clause
        FROM   {PREFIX}form_{$form_id}
        WHERE  is_finalized = 'yes'
                       $search_where_clause
                       $filter_clause
                       $submission_id_clause
        ORDER BY $order_by
                       $limit_clause
    ");
    $db->execute();
} catch (Exception $e) {
    Errors::queryError(__CLASS__, __FILE__, __LINE__, $e->getMessage());
    exit;
}

That's the SQL command that's being used to query your database to get the list of results.

After that, add the following:

echo "
    SELECT $select_clause
    FROM   {PREFIX}form_{$form_id}
    WHERE  is_finalized = 'yes'
                   $search_where_clause
                   $filter_clause
                   $submission_id_clause
    ORDER BY $order_by
                       $limit_clause
";
exit;

Then refresh the admin/forms/submissions.php Form Tools page (the page that should be listing all the results in your view). That'll output the actual SQL command that's being executed to return results. Post it here and I'll see if anything looks fishy. Next, you could try running that directly on your database table via phpMyAdmin or any other DB tool you have available.

If it's not the data, either Form Tools is constructing an invalid query (doubt it, but we'll see!) or there's some oddity about your system that prevents the query from working properly.

But first: screenshots!

ejgagne commented 5 years ago

Hi Ben,

Sorry for the delay in updates from my end of things. I added the query statement you sent, and got the following on screen when I went to display the main view page in form tools:

SELECT submission_id, col_1, col_2, col_3, col_4, col_5, col_6, col_7, col_8, col_9, col_10, col_11, col_12, col_13, col_14, col_15, col_16, col_17, submission_date, last_modified_date, ip_address FROM {PREFIX}form_1 WHERE is_finalized = 'yes' AND ((col_1 = 'JFK')) AND ((col_3 LIKE '%10.3%')) ORDER BY submission_date desc, submission_id LIMIT 0, 10

Below is what I get when using an SQL tool - in my case Heidi SQL:

echo " SELECT $selectclause FROM {PREFIX}form{$form_id} WHERE is_finalized = 'yes' $search_where_clause $filter_clause $submission_id_clause ORDER BY $order_by $limit_clause "; / SQL Error (1064): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'echo " SELECT $select_clause FROM {PREFIX}fo' at line 1 / / Affected rows: 0 Found rows: 0 Warnings: 0 Duration for 0 of 2 queries: 0.000 sec. / SHOW CREATE TABLE mysql.db; SHOW COLLATION; SHOW ENGINES; / Affected rows: 0 Found rows: 0 Warnings: 0 Duration for 0 queries: 0.000 sec. /

I have re-tried attaching the screen shots - hopefully they will go through this time (fingers crossed). This web based database is a first for me, so I want to thank you for all of your help, and I am learning quite a bit in the process. I'll look forward to talking soon.

Best Regards,

Eric Gagne

On Tue, Apr 30, 2019 at 10:37 PM Benjamin Keen notifications@github.com wrote:

Sorry Eric, I meant to get back you. It doesn't look like the screenshots made it, unfortunately, so I can't see them. Mind trying to re-attach?

If you temporarily remove the filter from your View, do you get data?

Secondly, if you don't mind doing a little brain surgery, try this. Add back your View filter. Then, in your [form tools root]/global/code/Submission.class.php file, go down to line 1063. You should see this block:

// (1) our main search query that returns a PAGE of submission info try { $db->query(" SELECT $selectclause FROM {PREFIX}form{$form_id} WHERE is_finalized = 'yes' $search_where_clause $filter_clause $submission_id_clause ORDER BY $order_by $limit_clause "); $db->execute(); } catch (Exception $e) { Errors::queryError(CLASS, FILE, LINE, $e->getMessage()); exit; }

That's the SQL command that's being used to ping your database to get the list of results.

After that, add the following:

  echo "
            SELECT $select_clause
            FROM   {PREFIX}form_{$form_id}
            WHERE  is_finalized = 'yes'
                   $search_where_clause
                   $filter_clause
                   $submission_id_clause
            ORDER BY $order_by
                   $limit_clause
  ";
  exit;

Then refresh the admin/forms/submissions.php Form Tools page (the page that should be listing all the results in your view). That'll output the actual SQL command that's being executed to return results. Post it here and I'll see if anything looks fishy. Next, you could try running that directly on your database table via phpMyAdmin or any other DB tool you have available.

If it's not the data, either Form Tools is constructing an invalid query (doubt it, but we'll see!) or there's some oddity about your system that prevents the query from working properly.

But first: screenshots!

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/formtools/core/issues/537#issuecomment-488181378, or mute the thread https://github.com/notifications/unsubscribe-auth/AL5NO5NK5HMQYLRDBSILRTTPTD65BANCNFSM4HIPEBGQ .

-- Eric J. Gagne Sr. Network Systems Engineer Northampton Public Schools Northampton, Massachusetts (413) 587-1371 - Direct Line

--

Please consider the environment before printing this email.Remember when writing or responding to email, the Massachusetts Secretary of State has determined that e-mail is a public record. All electronic messages sent from the Northampton Public Schools are archived in conformance with Massachusetts and Federal Public Records law.

ejgagne commented 5 years ago

Hi Ben,

I forgot to add that if I remove the filter from any of the views I create, I do indeed get data. When I add the filter back, I get no results.

Many thanks,

Eric Gagne

On Wed, May 8, 2019 at 12:44 PM Eric Gagne egagne@northampton-k12.us wrote:

Hi Ben,

Sorry for the delay in updates from my end of things. I added the query statement you sent, and got the following on screen when I went to display the main view page in form tools:

SELECT submission_id, col_1, col_2, col_3, col_4, col_5, col_6, col_7, col_8, col_9, col_10, col_11, col_12, col_13, col_14, col_15, col_16, col_17, submission_date, last_modified_date, ip_address FROM {PREFIX}form_1 WHERE is_finalized = 'yes' AND ((col_1 = 'JFK')) AND ((col_3 LIKE '%10.3%')) ORDER BY submission_date desc, submission_id LIMIT 0, 10

Below is what I get when using an SQL tool - in my case Heidi SQL:

echo " SELECT $selectclause FROM {PREFIX}form{$form_id} WHERE is_finalized = 'yes' $search_where_clause $filter_clause $submission_id_clause ORDER BY $order_by $limit_clause "; / SQL Error (1064): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'echo " SELECT $select_clause FROM {PREFIX}fo' at line 1 / / Affected rows: 0 Found rows: 0 Warnings: 0 Duration for 0 of 2 queries: 0.000 sec. / SHOW CREATE TABLE mysql.db; SHOW COLLATION; SHOW ENGINES; / Affected rows: 0 Found rows: 0 Warnings: 0 Duration for 0 queries: 0.000 sec. /

I have re-tried attaching the screen shots - hopefully they will go through this time (fingers crossed). This web based database is a first for me, so I want to thank you for all of your help, and I am learning quite a bit in the process. I'll look forward to talking soon.

Best Regards,

Eric Gagne

On Tue, Apr 30, 2019 at 10:37 PM Benjamin Keen notifications@github.com wrote:

Sorry Eric, I meant to get back you. It doesn't look like the screenshots made it, unfortunately, so I can't see them. Mind trying to re-attach?

If you temporarily remove the filter from your View, do you get data?

Secondly, if you don't mind doing a little brain surgery, try this. Add back your View filter. Then, in your [form tools root]/global/code/Submission.class.php file, go down to line 1063. You should see this block:

// (1) our main search query that returns a PAGE of submission info try { $db->query(" SELECT $selectclause FROM {PREFIX}form{$form_id} WHERE is_finalized = 'yes' $search_where_clause $filter_clause $submission_id_clause ORDER BY $order_by $limit_clause "); $db->execute(); } catch (Exception $e) { Errors::queryError(CLASS, FILE, LINE, $e->getMessage()); exit; }

That's the SQL command that's being used to ping your database to get the list of results.

After that, add the following:

 echo "
            SELECT $select_clause
            FROM   {PREFIX}form_{$form_id}
            WHERE  is_finalized = 'yes'
                   $search_where_clause
                   $filter_clause
                   $submission_id_clause
            ORDER BY $order_by
                   $limit_clause
 ";
 exit;

Then refresh the admin/forms/submissions.php Form Tools page (the page that should be listing all the results in your view). That'll output the actual SQL command that's being executed to return results. Post it here and I'll see if anything looks fishy. Next, you could try running that directly on your database table via phpMyAdmin or any other DB tool you have available.

If it's not the data, either Form Tools is constructing an invalid query (doubt it, but we'll see!) or there's some oddity about your system that prevents the query from working properly.

But first: screenshots!

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/formtools/core/issues/537#issuecomment-488181378, or mute the thread https://github.com/notifications/unsubscribe-auth/AL5NO5NK5HMQYLRDBSILRTTPTD65BANCNFSM4HIPEBGQ .

-- Eric J. Gagne Sr. Network Systems Engineer Northampton Public Schools Northampton, Massachusetts (413) 587-1371 - Direct Line

-- Eric J. Gagne Sr. Network Systems Engineer Northampton Public Schools Northampton, Massachusetts (413) 587-1371 - Direct Line

--

Please consider the environment before printing this email.Remember when writing or responding to email, the Massachusetts Secretary of State has determined that e-mail is a public record. All electronic messages sent from the Northampton Public Schools are archived in conformance with Massachusetts and Federal Public Records law.

ejgagne commented 5 years ago

Hi Ben,

I wanted to touch bases to see if you have had any insight as to what may be happening, based on the info that hopefully made it via my last email. This concerned the filter not properly filtering, in that with actual data in the tables, it will not provide and filtered output despite data being in the table. With any luck you may have some idea of what may be happening. In the event that you need to see things, I can arrange for a remote session if that would make it easier and quicker to see what is happening.

Many thanks for all of your help.

Best Regards,

Eric Gagne

On Wed, May 8, 2019 at 12:49 PM Eric Gagne egagne@northampton-k12.us wrote:

Hi Ben,

I forgot to add that if I remove the filter from any of the views I create, I do indeed get data. When I add the filter back, I get no results.

Many thanks,

Eric Gagne

On Wed, May 8, 2019 at 12:44 PM Eric Gagne egagne@northampton-k12.us wrote:

Hi Ben,

Sorry for the delay in updates from my end of things. I added the query statement you sent, and got the following on screen when I went to display the main view page in form tools:

SELECT submission_id, col_1, col_2, col_3, col_4, col_5, col_6, col_7, col_8, col_9, col_10, col_11, col_12, col_13, col_14, col_15, col_16, col_17, submission_date, last_modified_date, ip_address FROM {PREFIX}form_1 WHERE is_finalized = 'yes' AND ((col_1 = 'JFK')) AND ((col_3 LIKE '%10.3%')) ORDER BY submission_date desc, submission_id LIMIT 0, 10

Below is what I get when using an SQL tool - in my case Heidi SQL:

echo " SELECT $selectclause FROM {PREFIX}form{$form_id} WHERE is_finalized = 'yes' $search_where_clause $filter_clause $submission_id_clause ORDER BY $order_by $limit_clause "; / SQL Error (1064): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'echo " SELECT $select_clause FROM {PREFIX}fo' at line 1 / / Affected rows: 0 Found rows: 0 Warnings: 0 Duration for 0 of 2 queries: 0.000 sec. / SHOW CREATE TABLE mysql.db; SHOW COLLATION; SHOW ENGINES; / Affected rows: 0 Found rows: 0 Warnings: 0 Duration for 0 queries: 0.000 sec. /

I have re-tried attaching the screen shots - hopefully they will go through this time (fingers crossed). This web based database is a first for me, so I want to thank you for all of your help, and I am learning quite a bit in the process. I'll look forward to talking soon.

Best Regards,

Eric Gagne

On Tue, Apr 30, 2019 at 10:37 PM Benjamin Keen notifications@github.com wrote:

Sorry Eric, I meant to get back you. It doesn't look like the screenshots made it, unfortunately, so I can't see them. Mind trying to re-attach?

If you temporarily remove the filter from your View, do you get data?

Secondly, if you don't mind doing a little brain surgery, try this. Add back your View filter. Then, in your [form tools root]/global/code/Submission.class.php file, go down to line 1063. You should see this block:

// (1) our main search query that returns a PAGE of submission info try { $db->query(" SELECT $selectclause FROM {PREFIX}form{$form_id} WHERE is_finalized = 'yes' $search_where_clause $filter_clause $submission_id_clause ORDER BY $order_by $limit_clause "); $db->execute(); } catch (Exception $e) { Errors::queryError(CLASS, FILE, LINE, $e->getMessage()); exit; }

That's the SQL command that's being used to ping your database to get the list of results.

After that, add the following:

    echo "
            SELECT $select_clause
            FROM   {PREFIX}form_{$form_id}
            WHERE  is_finalized = 'yes'
                   $search_where_clause
                   $filter_clause
                   $submission_id_clause
            ORDER BY $order_by
                   $limit_clause
    ";
    exit;

Then refresh the admin/forms/submissions.php Form Tools page (the page that should be listing all the results in your view). That'll output the actual SQL command that's being executed to return results. Post it here and I'll see if anything looks fishy. Next, you could try running that directly on your database table via phpMyAdmin or any other DB tool you have available.

If it's not the data, either Form Tools is constructing an invalid query (doubt it, but we'll see!) or there's some oddity about your system that prevents the query from working properly.

But first: screenshots!

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/formtools/core/issues/537#issuecomment-488181378, or mute the thread https://github.com/notifications/unsubscribe-auth/AL5NO5NK5HMQYLRDBSILRTTPTD65BANCNFSM4HIPEBGQ .

-- Eric J. Gagne Sr. Network Systems Engineer Northampton Public Schools Northampton, Massachusetts (413) 587-1371 - Direct Line

-- Eric J. Gagne Sr. Network Systems Engineer Northampton Public Schools Northampton, Massachusetts (413) 587-1371 - Direct Line

-- Eric J. Gagne Sr. Network Systems Engineer Northampton Public Schools Northampton, Massachusetts (413) 587-1371 - Direct Line

--

Please consider the environment before printing this email.Remember when writing or responding to email, the Massachusetts Secretary of State has determined that e-mail is a public record. All electronic messages sent from the Northampton Public Schools are archived in conformance with Massachusetts and Federal Public Records law.

ejgagne commented 5 years ago

Hi Ben,

I just wanted to touch bases to see if you had a moment to look things over. I would like to continue with the project I have been working on, but am at a standstill until I'm able to figure out why the filter is acting as it is. If you have a moment, it would be great to hear back.

Kind Regards,

Eric Gagne

On Wed, May 8, 2019 at 12:44 PM Eric Gagne egagne@northampton-k12.us wrote:

Hi Ben,

Sorry for the delay in updates from my end of things. I added the query statement you sent, and got the following on screen when I went to display the main view page in form tools:

SELECT submission_id, col_1, col_2, col_3, col_4, col_5, col_6, col_7, col_8, col_9, col_10, col_11, col_12, col_13, col_14, col_15, col_16, col_17, submission_date, last_modified_date, ip_address FROM {PREFIX}form_1 WHERE is_finalized = 'yes' AND ((col_1 = 'JFK')) AND ((col_3 LIKE '%10.3%')) ORDER BY submission_date desc, submission_id LIMIT 0, 10

Below is what I get when using an SQL tool - in my case Heidi SQL:

echo " SELECT $selectclause FROM {PREFIX}form{$form_id} WHERE is_finalized = 'yes' $search_where_clause $filter_clause $submission_id_clause ORDER BY $order_by $limit_clause "; / SQL Error (1064): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'echo " SELECT $select_clause FROM {PREFIX}fo' at line 1 / / Affected rows: 0 Found rows: 0 Warnings: 0 Duration for 0 of 2 queries: 0.000 sec. / SHOW CREATE TABLE mysql.db; SHOW COLLATION; SHOW ENGINES; / Affected rows: 0 Found rows: 0 Warnings: 0 Duration for 0 queries: 0.000 sec. /

I have re-tried attaching the screen shots - hopefully they will go through this time (fingers crossed). This web based database is a first for me, so I want to thank you for all of your help, and I am learning quite a bit in the process. I'll look forward to talking soon.

Best Regards,

Eric Gagne

On Tue, Apr 30, 2019 at 10:37 PM Benjamin Keen notifications@github.com wrote:

Sorry Eric, I meant to get back you. It doesn't look like the screenshots made it, unfortunately, so I can't see them. Mind trying to re-attach?

If you temporarily remove the filter from your View, do you get data?

Secondly, if you don't mind doing a little brain surgery, try this. Add back your View filter. Then, in your [form tools root]/global/code/Submission.class.php file, go down to line 1063. You should see this block:

// (1) our main search query that returns a PAGE of submission info try { $db->query(" SELECT $selectclause FROM {PREFIX}form{$form_id} WHERE is_finalized = 'yes' $search_where_clause $filter_clause $submission_id_clause ORDER BY $order_by $limit_clause "); $db->execute(); } catch (Exception $e) { Errors::queryError(CLASS, FILE, LINE, $e->getMessage()); exit; }

That's the SQL command that's being used to ping your database to get the list of results.

After that, add the following:

 echo "
            SELECT $select_clause
            FROM   {PREFIX}form_{$form_id}
            WHERE  is_finalized = 'yes'
                   $search_where_clause
                   $filter_clause
                   $submission_id_clause
            ORDER BY $order_by
                   $limit_clause
 ";
 exit;

Then refresh the admin/forms/submissions.php Form Tools page (the page that should be listing all the results in your view). That'll output the actual SQL command that's being executed to return results. Post it here and I'll see if anything looks fishy. Next, you could try running that directly on your database table via phpMyAdmin or any other DB tool you have available.

If it's not the data, either Form Tools is constructing an invalid query (doubt it, but we'll see!) or there's some oddity about your system that prevents the query from working properly.

But first: screenshots!

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/formtools/core/issues/537#issuecomment-488181378, or mute the thread https://github.com/notifications/unsubscribe-auth/AL5NO5NK5HMQYLRDBSILRTTPTD65BANCNFSM4HIPEBGQ .

-- Eric J. Gagne Sr. Network Systems Engineer Northampton Public Schools Northampton, Massachusetts (413) 587-1371 - Direct Line

-- Eric J. Gagne Sr. Network Systems Engineer Northampton Public Schools Northampton, Massachusetts (413) 587-1371 - Direct Line

--

Please consider the environment before printing this email.Remember when writing or responding to email, the Massachusetts Secretary of State has determined that e-mail is a public record. All electronic messages sent from the Northampton Public Schools are archived in conformance with Massachusetts and Federal Public Records law.

ejgagne commented 5 years ago

Hi Ben,

I'm hoping to get to his project up and running for our department in the near future. Would you be able to drop me a line to help me figure out why the filter is not acting quite right? I'm so close but yet so far with getting this workable.

Many thanks,

Eric Gagne

On Mon, Jun 10, 2019 at 2:05 PM Eric Gagne egagne@northampton-k12.us wrote:

Hi Ben,

I just wanted to touch bases to see if you had a moment to look things over. I would like to continue with the project I have been working on, but am at a standstill until I'm able to figure out why the filter is acting as it is. If you have a moment, it would be great to hear back.

Kind Regards,

Eric Gagne

On Wed, May 8, 2019 at 12:44 PM Eric Gagne egagne@northampton-k12.us wrote:

Hi Ben,

Sorry for the delay in updates from my end of things. I added the query statement you sent, and got the following on screen when I went to display the main view page in form tools:

SELECT submission_id, col_1, col_2, col_3, col_4, col_5, col_6, col_7, col_8, col_9, col_10, col_11, col_12, col_13, col_14, col_15, col_16, col_17, submission_date, last_modified_date, ip_address FROM {PREFIX}form_1 WHERE is_finalized = 'yes' AND ((col_1 = 'JFK')) AND ((col_3 LIKE '%10.3%')) ORDER BY submission_date desc, submission_id LIMIT 0, 10

Below is what I get when using an SQL tool - in my case Heidi SQL:

echo " SELECT $selectclause FROM {PREFIX}form{$form_id} WHERE is_finalized = 'yes' $search_where_clause $filter_clause $submission_id_clause ORDER BY $order_by $limit_clause "; / SQL Error (1064): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'echo " SELECT $select_clause FROM {PREFIX}fo' at line 1 / / Affected rows: 0 Found rows: 0 Warnings: 0 Duration for 0 of 2 queries: 0.000 sec. / SHOW CREATE TABLE mysql.db; SHOW COLLATION; SHOW ENGINES; / Affected rows: 0 Found rows: 0 Warnings: 0 Duration for 0 queries: 0.000 sec. /

I have re-tried attaching the screen shots - hopefully they will go through this time (fingers crossed). This web based database is a first for me, so I want to thank you for all of your help, and I am learning quite a bit in the process. I'll look forward to talking soon.

Best Regards,

Eric Gagne

On Tue, Apr 30, 2019 at 10:37 PM Benjamin Keen notifications@github.com wrote:

Sorry Eric, I meant to get back you. It doesn't look like the screenshots made it, unfortunately, so I can't see them. Mind trying to re-attach?

If you temporarily remove the filter from your View, do you get data?

Secondly, if you don't mind doing a little brain surgery, try this. Add back your View filter. Then, in your [form tools root]/global/code/Submission.class.php file, go down to line 1063. You should see this block:

// (1) our main search query that returns a PAGE of submission info try { $db->query(" SELECT $selectclause FROM {PREFIX}form{$form_id} WHERE is_finalized = 'yes' $search_where_clause $filter_clause $submission_id_clause ORDER BY $order_by $limit_clause "); $db->execute(); } catch (Exception $e) { Errors::queryError(CLASS, FILE, LINE, $e->getMessage()); exit; }

That's the SQL command that's being used to ping your database to get the list of results.

After that, add the following:

    echo "
            SELECT $select_clause
            FROM   {PREFIX}form_{$form_id}
            WHERE  is_finalized = 'yes'
                   $search_where_clause
                   $filter_clause
                   $submission_id_clause
            ORDER BY $order_by
                   $limit_clause
    ";
    exit;

Then refresh the admin/forms/submissions.php Form Tools page (the page that should be listing all the results in your view). That'll output the actual SQL command that's being executed to return results. Post it here and I'll see if anything looks fishy. Next, you could try running that directly on your database table via phpMyAdmin or any other DB tool you have available.

If it's not the data, either Form Tools is constructing an invalid query (doubt it, but we'll see!) or there's some oddity about your system that prevents the query from working properly.

But first: screenshots!

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/formtools/core/issues/537#issuecomment-488181378, or mute the thread https://github.com/notifications/unsubscribe-auth/AL5NO5NK5HMQYLRDBSILRTTPTD65BANCNFSM4HIPEBGQ .

-- Eric J. Gagne Sr. Network Systems Engineer Northampton Public Schools Northampton, Massachusetts (413) 587-1371 - Direct Line

-- Eric J. Gagne Sr. Network Systems Engineer Northampton Public Schools Northampton, Massachusetts (413) 587-1371 - Direct Line

-- Eric J. Gagne Sr. Network Systems Engineer Northampton Public Schools Northampton, Massachusetts (413) 587-1371 - Direct Line

--

Please consider the environment before printing this email.Remember when writing or responding to email, the Massachusetts Secretary of State has determined that e-mail is a public record. All electronic messages sent from the Northampton Public Schools are archived in conformance with Massachusetts and Federal Public Records law.

glitterball commented 4 years ago

I am having a similar issue: The only solution seems to be to recreate the form from scratch and resubmit all of the forms again.

benkeen commented 4 years ago

@glitterball, any chance I could debug this issue directly on your server? I think it would greatly simplify things - it's extremely hard doing back and forth. I do feel bad not responding to Eric but there was just too much going on & I missed this. A second person encountering the very same issue sounds rather suspicious, like it may be a bug.

If so, email me at ben.keen@gmail.com and we'll chat.