Hey all,
Hoping someone could help me out with this weird MySQL problem.
I have a Table with 30 Columns/Fields. Whenever I try to run a query to insert data into it, nothing gets inserted. Even worse is that NO Errors are being generated.
Originally, 13 of the Columns/Fields were of type TEXT; and 17 were of type INT(11). I suspected that maybe the column TYPES were causing an issue so I ran a test and only attempted to insert data into only a few columns at a time.
To my surprise, I was only able to insert data into only 5 columns/fields. Inserting into anything more than 5 would not work.
I then changed all the TEXT columns to VARCHAR() Type and ran another test.
In this test, I am able to insert data into only 14 columns/fields. Inserting into more than 15 doesn't work.
Again, no error is being generated. In fact, when checking my queries with IF-Else control, I get a "query successful" each time!
By the way, I've tested this for hours. The mysql/php syntax is correct. My code is not missing a comma, or quote, or anything else.
Anyone else encounter this? Is there some sort of limitation MySQL has when inserting into more than "x" number of columns/fields?
As I mentioned, I suspected this may be being caused by my declaration of column types. Can someone confirm that this may be the cause?
All comments are welcome.
Thanks in advance for the help.
Best!
- Tyhand
Hoping someone could help me out with this weird MySQL problem.
I have a Table with 30 Columns/Fields. Whenever I try to run a query to insert data into it, nothing gets inserted. Even worse is that NO Errors are being generated.
Originally, 13 of the Columns/Fields were of type TEXT; and 17 were of type INT(11). I suspected that maybe the column TYPES were causing an issue so I ran a test and only attempted to insert data into only a few columns at a time.
To my surprise, I was only able to insert data into only 5 columns/fields. Inserting into anything more than 5 would not work.
I then changed all the TEXT columns to VARCHAR() Type and ran another test.
In this test, I am able to insert data into only 14 columns/fields. Inserting into more than 15 doesn't work.
Again, no error is being generated. In fact, when checking my queries with IF-Else control, I get a "query successful" each time!
By the way, I've tested this for hours. The mysql/php syntax is correct. My code is not missing a comma, or quote, or anything else.
Anyone else encounter this? Is there some sort of limitation MySQL has when inserting into more than "x" number of columns/fields?
As I mentioned, I suspected this may be being caused by my declaration of column types. Can someone confirm that this may be the cause?
All comments are welcome.
Thanks in advance for the help.
Best!
- Tyhand