This example uses the PayrollItemWage table, however the same applies to the PayrollItemNonWage table.
The first step is to find the ListID for your Payroll Expense ledger account. This may be found by running the following query in VB Demo:
Select ListID, Name, AccountType from Account where AccountType = 'Expense'
From the above, the second line shows the ListID for Payroll Expenses is 540002-1071527489
Using this ListID as the ExpenseAccountRefListID you can then create the new PayrollItem using a INSERT command like this :
INSERT INTO PayrollItemWage (Name, IsActive, WageType, ExpenseAccountRefListID) VALUES ('QODBC Payroll Item', 1 ,'HourlyRegular', '540002-1071527489')
|