Jump to content

Ledger DB


Jakes

Recommended Posts

Good day,

I have for some reason not a phpvms_ledger table. I do not understand why, maybe because I doesnt have the latest update. I did not do the update due to the many modifations. The site function fine, but the finances does not update when selling/repairing aircraft, not showing the expenses, sales income.

Any help, or a SQL query that can add the table?

Best Regards,

Jakes

Link to comment
Share on other sites

Here is the error log:

(all my tables have a prefix MySQL)

Time: 10.22.13 13:31:58

Backtrace: DB::write_debug > DB::get_row > LedgerData::getPaymentForMonth > FinanceData::calculateFinances > PIREPData::getIntervalDataByMonth > Finance->viewmonthchart > call_user_func_array > MainController::RunAllActions

Query: SELECT SUM(`amount`) as `total` FROM `phpvms_MySQLledger` WHERE DATE_FORMAT(submitdate, '%Y-%m') = DATE_FORMAT(FROM_UNIXTIME(1374509881), '%Y-%m') AND `paysource` = 2

Error: (1146) - Table 'jdsarcco_UVSAAF.phpvms_MySQLledger' doesn't exist

Link to comment
Share on other sites

  • Administrators

This should fix you up. If you are not using phpvms_ as a table prefix you will have to change that part but other than that it should create the missing table.

CREATE TABLE IF NOT EXISTS `phpvms_ledger` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`pilotid` int(11) NOT NULL,
`pirepid` int(11) NOT NULL DEFAULT '0',
`paysource` tinyint(4) NOT NULL,
`paytype` int(11) NOT NULL DEFAULT '3',
`amount` float(7,2) NOT NULL DEFAULT '0.00',
`submitdate` datetime NOT NULL,
`modifieddate` datetime NOT NULL,
PRIMARY KEY (`id`),
KEY `pilot_id` (`pilotid`),
KEY `pirepid` (`pirepid`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=1 ;

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...