Member Login

Username
Password
Forget Password
New Sign Up
Search Forum

Buy Support
Incidents

If you can't find your answer in the FREE PUBLIC QDeveloper Forum, require URGENT Priority Support, or you need to send us private or confidential information:

Click Here
If you can't login and post questions or you are having trouble viewing forum posts:
Click Here
Callback
Support

If you live in USA, UK, Canada, Australia or New Zealand, you can leave us details on your question and request us to call you back and discuss them with you personally  (charges apply).

Click Here
 
Buy Support
Incidents
If you can't find your answer in the FREE PUBLIC QDeveloper Forum, require URGENT Priority Support, or you need to send us private or confidential information:
Click Here

Forum : Operating Expense - Using filters with SP_REPORTSearch Forum

Forum Home > QODBC - ODBC Driver for QuickBooks > QODBC SQL Support Forum

 New Topic 
 
 Post Reply 
[1]  
 Operating Expense - Using filters with SP_REPORT 
 Author   Message 
  bobbo 
  
 Group: Members 
 Posts: 5 
 Joined: 2006-09-01 
 Profile
 Posted : 2006-09-01 11:17:53
Does anyone know the SQL needed to pull just operating expenses from QuickBooks? I would even be happy to know which table(s) are involved.

I am able to get some data from BillExpenseItem, but that doesn't include Employee Compensation.

TIA,
Bob 

  Top 
  Tom 
  6c3c1_sdk-qodbc.gif
 Group: Administrator 
 Posts: 5510 
 Joined: 2006-02-17 
 Profile
 Posted : 2006-09-01 18:49:35

You can run all the QuickBooks reports directly using a SQL statement. So just choose the report that gives what you're looking for!

See: How do I use the QuickBooks Reporting Engine with QODBC? I've heard something about sp_report ? 

If on the other hand you just want to see want you have paid for, see: How do I locate the Date Paid for a check payment? 

 

  Top 
  bobbo 
  
 Group: Members 
 Posts: 5 
 Joined: 2006-09-01 
 Profile
 Posted : 2006-09-02 01:58:16
I've already tried that route.

All I really want is a grand total of all operating expense year to date.

I am able to get a total of operating expense from the BillExpenseLine table. However, this total is missing all the Employee Compensation amounts. I can't find the table that holds these data.

I can run a custom P&L report in QuickBooks to get the list of Operating Expense items, but there is no stored procedure report that provides that. And I am not able to pass a custom Account parameter using the sp P&L reports.

Thanks.

 

  Top 
  Tom 
  6c3c1_sdk-qodbc.gif
 Group: Administrator 
 Posts: 5510 
 Joined: 2006-02-17 
 Profile
 Posted : 2006-09-04 09:04:01

We have actually tried to provide a great deal of flexabilty in our stored procedure SP_REPORT. Most of the QuickBooks filters can be found using QODBC. For example:

Can by found by running:

sp_parameters ProfitAndLossDetail

Which shows the filters for Account as:

|AccountsPayable|AccountsReceivable|AllowedFor1099|APAndSalesTax|APOrCreditCard
|ARAndAP|Asset|BalanceSheet|Bank|BankAndARAndAPAndUF|BankAndUF|CostOfSales|CreditCard
|CurrentAsset|CurrentAssetAndExpense|CurrentLiability|Equity|EquityAndIncomeAndExpense
|ExpenseAndOtherExpense|FixedAsset|IncomeAndExpense|IncomeAndOtherIncome|Liability
|LiabilityAndEquity|LongTermLiability|NonPosting|OrdinaryExpense|OrdinaryIncome
|OrdinaryIncomeAndCOGS|OrdinaryIncomeAndExpense|OtherAsset|OtherCurrentAsset
|OtherCurrentLiability|OtherExpense|OtherIncome|OtherIncomeOrExpense|

So if we are only interested in ExpenseAndOtherExpenses, we can run the report like this:

sp_report ProfitAndLossDetail show Text, Blank, TxnType, Date, RefNumber, Name, Memo,
ClearedStatus, SplitAccount, Debit, Credit, RunningBalance
parameters DateMacro = 'ThisYearToDate', AccountFilterType = 'ExpenseAndOtherExpense'

Or if we just want the totals like this: 

sp_report ProfitAndLossStandard show Amount_Title, Text, Label, Amount
parameters DateMacro = 'ThisMonthToDate', SummarizeColumnsBy = 'TotalOnly',
AccountFilterType = 'ExpenseAndOtherExpense'

And if we just want particular lines, we can even use Where to filter the returned result:

sp_report ProfitAndLossStandard show Amount_Title, Text, Label, Amount
parameters DateMacro = 'ThisMonthToDate', SummarizeColumnsBy = 'TotalOnly',
AccountFilterType = 'ExpenseAndOtherExpense' where Label = 'Insurance' or Label = 'Fuel'

I hope this helps.

 

  Top 
  bobbo 
  
 Group: Members 
 Posts: 5 
 Joined: 2006-09-01 
 Profile
 Posted : 2006-09-05 09:36:22

Wow! Thanks for the great information and help.

-Bob

 

  Top 
 New Topic 
 
 Post Reply 
[1]  

Jump to