Results 1 to 3 of 3
  1. #1
    Join Date
    May 2012
    Posts
    132

    Unanswered: how to make this report?

    There are three employees working in a company. Their daily sales are recorded on a table with these fields.
    Employeename costumer sales date
    We need a daily report like this:

    Code:
    	cstmr	  sales	
    Jack:
    	MST	  17000	  
    	CIS	  13000	  
    	MIC	  16000	  
    	TBT	  14000	  
    sum	4	 60000	  
    Steve:
    	MST	  10000	  
    	CIS	  12000	 
    sum: 	2	 22000	  
    John:
    	MST	  10000	  
    	CIS	  10000	  
    	MIC	  10000	  
    sum	3	 30000	  
    Cyrus:
    	MST	  12000	  
    sum	1	 12000
    thank you
    ,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
    I asked god to please give me everything to enjoy the life, God said: i gave you the life to enjoy everything.

  2. #2
    Join Date
    Nov 2004
    Location
    out on a limb
    Posts
    13,692
    Provided Answers: 59
    so design your report
    specify the sorting and grouping to be by employee
    in the group footer put in two control boxes
    set the data source to be
    =count(cstmr) for one
    = sum(sales) for the other

    set a report footer and two controls, set the data source to be the same

    then consioder how you limit the data
    you could set the reports query to limit the data to say
    WHERE salesdate = date() -1
    but that would only work when you run the report the day following the sales date
    you would be better of if you parameterised the report and supplied that as part of the form that calls the report as part of the openreport argument.

    by setting the the date limit as part of the openreport you have a single report which could be used to report a single day, or a specific time period (say a week, month or quarter).


    you could also specify the date limit in the query design

    eg
    where orderDate between [Lower Date Limit] and [Upper Date Limit]

    however I dislike that method as its not possible to make certain the user puts in correct data. I far prefer to use a form that calls reports with specified values, another form that sets those values, and handles the validation logic
    I'd rather be riding on the Tiger 800 or the Norton

  3. #3
    Join Date
    May 2012
    Posts
    132
    thank you very much, it was so helpful
    ,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
    I asked god to please give me everything to enjoy the life, God said: i gave you the life to enjoy everything.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •