Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Sage Line 100 1

Status
Not open for further replies.

JohnBairner

Technical User
Oct 14, 2003
4
GB
Hi new to crystal can anyone advise me on te following
I have conected Sage Line100 db via ODBC and am tyringto create some information from the nominal ledger
there is a field that gives a total transaction amount within the datadict when displayed it shows credits and debits,I want to have 2 seperate colums one showingthe credits and the other debits but i am not to saw what formual soud be used,so far i have keyed
{sales_transaction_amount}>=0 this gives me a result false but i wat to see the actual amounts ie as a credit or debit

Hope someone can help
John.
 
John,
I think the easiest way to do this would be to create an additional details section. (Right click in the details area to the right of the report and choose insert section below) Make this section exactly like the original details section you have now. Then go to format section and use the x-2 section to conditionally suppress details a to show only the positive values (credits) and details b to show only the negative values(debits). In details b put the sales_transaction_amount to the left of the one above it in details a. This should look like 2 columns.

Formula like this:
details a(sales_transaction_amount > 0)
details b (sales_transaction_amount < 0)

Depends if you want to see 0 values at all. This formula will not show any 0's.

Sunny
 
Create a formula field for your debits (assuming they are positively signed numbers; if not use this formula for your credits) that looks like:

If {sales_transaction_amount}>=0 then
{sales_transaction_amount}
Else
0

For the your credits (the debits if negatively signed), create a separate formula field:
If {sales_transaction_amount}<0 then
{sales_transaction_amount}
Else
0

When you place the formula fields on the report, you'll probably not want to see the zeros that occur in the else statement, so format the field to suppress zeros (right-click on the field, Select Format Field and go to the Number tab; choose Customize and select the suppress if zero option).
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top