Submitting more than 8000 textfields
Moderator: General Moderators
Re: Submitting more than 8000 textfields
I'm not going to warn or ban anyone in this thread because I'm part of it and I don't want people to accuse me of abusing my mod status to settle arguments. Needlesstosay though, I have brought it to the attention of other mods, and it will be reviewed. Until then stick to the topic at hand without arguing or insulting one another please.
Re: Submitting more than 8000 textfields
Correct, I echoed the 8200 results and I get them in the other page without any problem (No MySQL Queries executed).onion2k wrote:Having a huge number of fields isn't necessarily a problem...
Yes that was the problem, after some testing I found out that I was performing the 8200 updates, even if the evaluation did not changed, so at first I tried adding in the UPDATE statement a "WHERE n_evaluation!=$MyNewEvaluation" but I still had the problem that I was executing the 8200 updates, soo, what I did is I queried all of the information from the DB and stored it in a PHP variable, and before the update I check if the new value is different to the stored value, if it isn't then I perform the update, otherwise I continue with the rest of the skills. This seems to work even for 11,000 recordsonion2k wrote:...although doing thousands of queries to process the form definitely is a problem...
I know that having the 8200 records is not the best option for usability, and I talked to the people who wanted the application but they want it that way, I will still try to make them change their mind.
Thanks everyone for your help!
- Christopher
- Site Administrator
- Posts: 13596
- Joined: Wed Aug 25, 2004 7:54 pm
- Location: New York, NY, US
Re: Submitting more than 8000 textfields
From reading this post, it sounds like they really want a web page that acts like a spreadsheet. You might want to rethink the whole form idea and move to edit-in-place using a Javascript library. That way you display all the data with one SELECT. Then you only do UPDATEs and INSERTs on the cells/rows they are actually working on. You would have fewer net database queries and they would be more spread out over time. And you'd have a much cooler interface. I recently used jQuery to do edit-in-place and it was very easy to implement.
(#10850)
Re: Submitting more than 8000 textfields
I have not used JQuery, I'm going to google it and see how to implement it. Thanks!arborint wrote:You might want to rethink the whole form idea and move to edit-in-place using a Javascript library.