?
Solved

Count rows with different values in crystal report

Posted on 2009-04-14
5
Medium Priority
?
516 Views
Last Modified: 2012-05-06
Dear experts,
I want to make a report that will display an item sale details. This report will show the item and which warehouse its being held and how many stocks are there in each warehouses. There's also a sale status for each of the item (Sold or Not Sold). I grouped the report according to warehouse and sell status. However, i want to know for each warehouse, how many of this item has been sold and how many are still NOT SOLD. How am i suppose to get around to do it? any formula that might help? Thanks experts..
0
Comment
Question by:Slythie
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
5 Comments
 
LVL 6

Expert Comment

by:BALMUKUND KESHAV
ID: 24144744
First of all let us know your database structure and how data is being stored, is there any field which has calculated stock lying. If not  you will have to calculate the stock item wise, it includes opening stock, purchased during the period, sold during the period, and also credit note raised, all you will have to calculate/consider.

Regards,

Bm Keshav


0
 

Author Comment

by:Slythie
ID: 24144874
this table is made specifically for 1 item. The item is called "Starter Kit". In this table, it will store:
- sk_id = got this data from invoice number from where the starter kit is being purchased
- sk_supplier = this data is taken from the supplier who supplies the starter kit
- sk_warehouse = this data is to store the warehouse ID where the starter kit is being stored
- sk_member_code = this data is a member code generated for each starter kit
- sk_status = this data is to show whether this particular starter kit has been sold or not.

Example:
warehouse 1 bought 3 starter kits from supplier 02. When the supplier sent that 3 starter kits, they will also provide unique member codes for each of the 3 starter kits. The table will look like this:

sk_id                sk_supplier        sk_warehouse          sk_member_code         sk_status
sup02-w01       sup02                  w01                          mem001                         NOT SOLD
sup02-w01       sup02                  w01                          mem002                         NOT SOLD
sup02-w01       sup02                  w01                          mem003                         SOLD

whenever that warehouse sell the starter kit to that particular member in member_code, the status will change to SOLD. Now how am i suppose to count the number of NOT SOLD and SOLD in crystal report? thanks experts
0
 
LVL 2

Accepted Solution

by:
XFishX earned 375 total points
ID: 24144977
Use the "Running Total" feature in Crystal Reports.

Perform a running count where 'sk_status' = SOLD
0
 

Author Comment

by:Slythie
ID: 24145139
do i need a formula to do that? coz, when i use the running total, it will count all the rows in the field and am not able to distinguish the difference between SOLD and NOT SOLD
0
 

Author Comment

by:Slythie
ID: 24145153
oh nvm... i got it.. thx u for ur help expert
0

Featured Post

Enroll in August's Course of the Month

August's CompTIA IT Fundamentals course includes 19 hours of basic computer principle modules and prepares you for the certification exam. It's free for Premium Members, Team Accounts, and Qualified Experts!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I hate sub reports and always consider them the last resort in any reporting solution.  The negative effect on performance and maintainability is just not worth the easy ride they give the report writer.  Nine times out of ten reporting requirements…
There have always been a lot of questions related to when Crystal Reports evaluates report components (such as formulas, summaries, cross-tabs, charts, to name a few examples). Crystal Reports uses a two-pass reporting process to provide greater …
In this brief tutorial Pawel from AdRem Software explains how you can quickly find out which services are running on your network, or what are the IP addresses of servers responsible for each service. Software used is freeware NetCrunch Tools (https…
This tutorial will teach you the special effect of super speed similar to the fictional character Wally West aka "The Flash" After Shake : http://www.videocopilot.net/presets/after_shake/ All lightning effects with instructions : http://www.mediaf…
Suggested Courses
Course of the Month9 days, 1 hour left to enroll

764 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question