Made too large form and while saving information to database had following MySQL problem
"Row size too large (> 8126). Changing some columns to TEXT or BLOB or using ROW_FORMAT=DYNAMIC or ROW_FORMAT=COMPRESSED may help."
For me its not possible to make some columns to text or blob so I decided to split table in three parts.
My quess is that this needs 3 times "DB Save". The problem is that "DB save" saves everything. The question is how can I select which values are saved in each table. Primary key should be id for each table so information stays in order when updating in future.
"Row size too large (> 8126). Changing some columns to TEXT or BLOB or using ROW_FORMAT=DYNAMIC or ROW_FORMAT=COMPRESSED may help."
For me its not possible to make some columns to text or blob so I decided to split table in three parts.
My quess is that this needs 3 times "DB Save". The problem is that "DB save" saves everything. The question is how can I select which values are saved in each table. Primary key should be id for each table so information stays in order when updating in future.
Hello kmikko,
I'm not a Chrono professional, but after checking your new post, I think that the following links may help:
How do I save form data to a database table?
How can I show data linked to a drop-down option?
How to load record data from a database table into your form
How can I build a chart to show data?
P.S: I'm just an automated service😉
I'm not a Chrono professional, but after checking your new post, I think that the following links may help:
How do I save form data to a database table?
How can I show data linked to a drop-down option?
How to load record data from a database table into your form
How can I build a chart to show data?
P.S: I'm just an automated service😉
Some update.
Made test with 2 tables and first table gets all information that needed but second table doesn't save anything. Both tables have
chronoforms columns id, uniq_id, user_id, created and modified.
Tested this http://www.chronoengine.com/forums/posts/f2/t97328.html?page=2
Didn't work. Result was 2 same rows in table1. Just little confused.
Made test with 2 tables and first table gets all information that needed but second table doesn't save anything. Both tables have
chronoforms columns id, uniq_id, user_id, created and modified.
Tested this http://www.chronoengine.com/forums/posts/f2/t97328.html?page=2
Didn't work. Result was 2 same rows in table1. Just little confused.
Another update.
Hadto create tables again so they where in sync with id.
Now the problem is that CF saves columns id, uniq_id, user_id, created and modified. All the actual data is left somewhere.
Here is debug
Hadto create tables again so they where in sync with id.
Now the problem is that CF saves columns id, uniq_id, user_id, created and modified. All the actual data is left somewhere.
Here is debug
Data array
Array
(
[option] => com_chronoforms5
[chronoform] => Datav1add
[event] => submit
[name] => test
[acronym] => test
[host] => test
[address] => test
[zipcode] => test
[country] => Belgium
[www] => test
[site] => test
[owner] => test
[year] => test
[button37] => Submit
[Data] => Array
(
[id] => 2
)
[2nd_table_pkey] =>
[Information] => Array
(
[id] => 2
)
[ip_address] => xx.xxx.x.xxx
)
Errors
Array
(
)
Debug info
Array
(
[8] => Array
(
[DB Save] => Array
(
[Queries] => Array
(
[0] => INSERT INTO `Datameasurements` (`user_id`, `uniq_id`, `created`) values ('0', '2yae5dd221901a0b15cb9c4be5cc930693e5537f', '2015-05-22 10:50:34');
)
)
)
[5] => Array
(
[DB Save] => Array
(
[Queries] => Array
(
[0] => INSERT INTO `Datainformation` (`user_id`, `uniq_id`, `created`) values ('0', '46714989efc34a0323933e640d848177f237fb94', '2015-05-22 10:50:34');
)
)
)
Hi kmikko,
Unless you have an enormous number of columns I would suggest that you adjust the column sizes to reduce the number of VARCHAR(255) columns - often VARCHAR(8) or (64) is enough. Please see this FAQ
Bob
Unless you have an enormous number of columns I would suggest that you adjust the column sizes to reduce the number of VARCHAR(255) columns - often VARCHAR(8) or (64) is enough. Please see this FAQ
Bob
Hi Bob ant thank you for your answer.
I allready tried to make smaller columns and had this same error
"Row size too large (> 8126). Changing some columns to TEXT or BLOB or using ROW_FORMAT=DYNAMIC or ROW_FORMAT=COMPRESSED may help." So I quess this is restrict with server and I don't have rights to make table larger.
Do you have any suggestions for what goes wrong whit this 2 table save.
I can see that DB save arrays doesn't get all the information they need. How can I update that info.
What I have now
There is 2 DB saves with different Model ID and
before second DB save there is custom code
I allready tried to make smaller columns and had this same error
"Row size too large (> 8126). Changing some columns to TEXT or BLOB or using ROW_FORMAT=DYNAMIC or ROW_FORMAT=COMPRESSED may help." So I quess this is restrict with server and I don't have rights to make table larger.
Do you have any suggestions for what goes wrong whit this 2 table save.
I can see that DB save arrays doesn't get all the information they need. How can I update that info.
What I have now
There is 2 DB saves with different Model ID and
before second DB save there is custom code
<?php
$form->data["2nd_table_pkey"] = $form->data["id"];
unset($form->data["id"]);
?>
This topic is locked and no more replies can be posted.