amir Posted May 7, 2015 Report Posted May 7, 2015 Hello guys. i've got a problem that when someone sends a pirep (neither with client nor manual) , the pirep will not be added to database !! however i'm getting the notification email. other functions are working correctly . there were nothing in error_log and i did not change any thing !! Quote
Members Vangelis Posted May 8, 2015 Members Report Posted May 8, 2015 turn debug on and let as see the log please Quote
amir Posted May 8, 2015 Author Report Posted May 8, 2015 turn debug on and let as see the log please thanks. i will really appreciate your help i turned the debugging on and finally an error !! ===== Time: 05.08.15 19:26:00 ===== Time: 05.08.15 19:26:00 Backtrace: DB::write_debug > DB::query > PilotData::updateProfile > Auth::ProcessLogin > Login->ProcessLogin > Login->login > Login->index > call_user_func_array > MainController::RunAllActions Query: UPDATE phpvms_pilots SET `lastlogin`=NOW(), `lastip`='188.159.202.242' WHERE `pilotid`= Error: (1064) - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1 ===== ===== ===== Time: 05.08.15 19:26:28 ===== Time: 05.08.15 19:26:28 Backtrace: DB::write_debug > DB::query > PIREPData::fileReport > PIREPS->SubmitPIREP > PIREPS->viewpireps > PIREPS->mine > call_user_func_array > MainController::RunAllActions Query: INSERT INTO phpvms_pireps( `pilotid`, `code`, `flightnum`, `depicao`, `arricao`, `route`, `route_details`, `distance`, `aircraft`, `flighttime`, `flighttime_stamp`, `landingrate`, `submitdate`, `accepted`, `log`, `load`, `fuelused`, `expenselist`, `source`, `exported`, `rawdata`) VALUES ( 1, 'IRA', '310', 'OIAW', 'OIII', 'EGVAX G667 SAV', 'a:0:{}', '291.60776761176', '6', '1', '1:00', '0', NOW(), 0, '', '137', '1000', '0', 'manual', 0, '') Error: (1364) - Field 'price' doesn't have a default value ===== ===== ===== Time: 05.08.15 19:30:17 ===== Time: 05.08.15 19:30:17 Backtrace: DB::write_debug > DB::query > PIREPData::fileReport > PIREPS->SubmitPIREP > PIREPS->viewpireps > PIREPS->mine > call_user_func_array > MainController::RunAllActions Query: INSERT INTO phpvms_pireps( `pilotid`, `code`, `flightnum`, `depicao`, `arricao`, `route`, `route_details`, `distance`, `aircraft`, `flighttime`, `flighttime_stamp`, `landingrate`, `submitdate`, `accepted`, `log`, `load`, `fuelused`, `expenselist`, `source`, `exported`, `rawdata`) VALUES ( 1, 'IRA', '402', 'OIAW', 'OIMM', 'ITIBI W6 ISN G202 ORSOK G663 RAMIL', 'a:0:{}', '617.79542779912', '5', '1', '1:00', '0', NOW(), 0, '', '219', '1000', '0', 'manual', 0, '') Error: (1364) - Field 'price' doesn't have a default value ===== ===== Quote
Members Vangelis Posted May 8, 2015 Members Report Posted May 8, 2015 just to confirm do you have a price ticket in all your schedules ? if not the you have to put a price Quote
amir Posted May 8, 2015 Author Report Posted May 8, 2015 just to confirm do you have a price ticket in all your schedules ? if not the you have to put a price yes i do. this is a new problem we have 200 pireps with no problems Quote
Members Vangelis Posted May 9, 2015 Members Report Posted May 9, 2015 This is a kinda sloppy fix but it will do the trick run this code in phpadmin ALTER TABLE `phpvms_pireps` CHANGE `price` `price` FLOAT NOT NULL DEFAULT '100' Quote
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.