Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error after submission history activated #5

Open
sklmteacher opened this issue Feb 8, 2018 · 15 comments
Open

error after submission history activated #5

sklmteacher opened this issue Feb 8, 2018 · 15 comments
Labels

Comments

@sklmteacher
Copy link

following error showed when I updated a record through individual login after activated submission history

Problem with this query in sh_add_history_row(): SQLSTATE[01000]: Warning: 1265 Data truncated for column 'sh___change_account_type' at row 1

@benkeen benkeen added the Bug label Feb 9, 2018
@benkeen
Copy link
Member

benkeen commented Feb 9, 2018

Hi @sklmteacher, excellent thanks for logging this. Basically the problem is that it's just attempting to write some data into that field that's too big. But this should NOT occur because that field isn't customizable. Thanks! I'll give it a look.

@sklmteacher
Copy link
Author

sklmteacher commented Feb 9, 2018 via email

@benkeen
Copy link
Member

benkeen commented Feb 9, 2018

Yeah I'd imagine it'll occur with all data changes on the form. Are you able to glance at the form table in the database? I'm looking at the field and it's an ENUM: enum('admin', 'client', 'unknown') meaning it gets fed specific values. I just wanted to confirm it looks the same on your end; I'm kind of puzzled by the error message.

@benkeen
Copy link
Member

benkeen commented Feb 10, 2018

Hey @sklmteacher, I haven't been able to reproduce this I'm afraid. Let me know about the database table column structure to just confirm that's not the issue.

@sklmteacher
Copy link
Author

I found same values enum('admin','client','unknown') NULL
at column sh___change_account_type .

@benkeen
Copy link
Member

benkeen commented Feb 10, 2018

Cool thanks. And you're logging in as a client/admin account when you see the error?

@sklmteacher
Copy link
Author

sklmteacher commented Feb 10, 2018 via email

@benkeen
Copy link
Member

benkeen commented Feb 10, 2018

Ahhh! Sorry, how daft of me. Thanks.

@benkeen
Copy link
Member

benkeen commented Feb 10, 2018

Still no luck reproducing this on my end, but I do think I see what may be the problem. Try this. Change the values for the sh___change_account_type database field in your history table to this:

'admin','client','user','unknown' (note the addition of user).

Then try logging out of FT, logging in via the Submission Accounts user and updating the data.

@sklmteacher
Copy link
Author

sklmteacher commented Feb 10, 2018 via email

@sklmteacher
Copy link
Author

sklmteacher commented Feb 10, 2018 via email

@benkeen
Copy link
Member

benkeen commented Feb 10, 2018

Oops! Better not post passwords here, this is a public place.

Want to email me your database name and I'll log in via that URL you posted and take a look. I'm at: [email protected]

@sklmteacher
Copy link
Author

Thanks for your suggestion,
I could prevent errors by changing the values for the database columns as
sh___change_account_type / enum('admin','client','user','unknown')
sh___change_account_id / mediumtext NULL
However, History of the particular updated submission is not being retrieved in admin login.
History of the submission made retrievable if the values 'user' in sh___change_account_id changed manually to '0'.

@crazamahdi
Copy link

I installed submission history module but it is not working for version 3.0.9 any idea how to run that module for latest version. @benkeen

@crazamahdi
Copy link

On clicking load history(submission history) nothing is displayed it is not working @benkeen

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants