esport Posted October 22, 2008 Share Posted October 22, 2008 Hi Guys, I have never experienced this before. Im not sure if this is a mysql question or php. I can insert the data into the table fine, but when I run a query to check 2 fields it doesnt work. The data is in the tables. However, when I go into phpMyAdmin, browse the row and without making any changes to the table and click go, my query works fine. Im baffled... :-\ :-\ :-\ Quote Link to comment https://forums.phpfreaks.com/topic/129503-solved-not-inserting-correctly-in-db/ Share on other sites More sharing options...
xtopolis Posted October 22, 2008 Share Posted October 22, 2008 Add or die(mysql_error()); to your mysql_query() statement mysql_query() or die(mysql_error()); What error does it give you? Quote Link to comment https://forums.phpfreaks.com/topic/129503-solved-not-inserting-correctly-in-db/#findComment-671434 Share on other sites More sharing options...
esport Posted October 22, 2008 Author Share Posted October 22, 2008 there are no errors, it inserts correclty but when i run a query it returns nothing, unless i goto phpMyAdmin browse the row and click go. I think I may have figured out the problem. The data was being sent by a flash application and input fields were set as multiline not single line, so I think this may have been the problem. It must of been putting white spaces either at the start or end of each field. Quote Link to comment https://forums.phpfreaks.com/topic/129503-solved-not-inserting-correctly-in-db/#findComment-671450 Share on other sites More sharing options...
xtopolis Posted October 22, 2008 Share Posted October 22, 2008 ok, otherwise we'll have to see some code to figure it out Quote Link to comment https://forums.phpfreaks.com/topic/129503-solved-not-inserting-correctly-in-db/#findComment-671459 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.