#1   Report Post  
Posted to microsoft.public.excel.misc
elephant
 
Posts: n/a
Default COMPLEX PROBLEM

I have four variables: ID (col HZ), Pick (col IA), Type of Visit (col
IB), and Current_Day (IC). ID is unique code and is repeated for every
visit; Pick takes only the last visit and codes it as 1, else 0; Type
of Visit picks its values from another variable that ranks the visit as
1, 2, 3...i and outputs either "N" or "R"; Curr_Day checks the value of
the date of visit to between 21st of previous month and 20th of current
month (e.g. March 21 to April 20, inclusive) and ouputs 0 or 1. Thus if
I want to pick all visits during the reporting period I simply
autofilter and select Curr_Day=1. I can further select single clients
from "Pick". However, a client can make more than one visit a month. In
my formula, only the first visit will be picked as new, the rest are
revisits.

HZ IA IB IC
3 1 N 0
8 1 N 1
17 0 N 0
17 0 R 0
17 1 R 1
18 0 N 1
18 1 R 1

formulae used
IA "=IF($HZ2-$HZ3=0,0,1)"
IB "=IF($EG2=1,"N",IF($EG2<1,"R",""))" where EG9 rank of visit (not
among the 4 fields)
IC "=IF(AND($DJ8$IR$2,$DJ8<$IR$3),1,0)" where DJ is date of visit and
IR2 start date, IR3 is end date

How can I create a formula that codes all visits as new so long as the
first visit falls within the month of interest? Will this solve my
problem, since at the end of day, I just want to analyse new visits and
revisits and pick clients only once, regardless of the number of visits
within the month. I would really appreciate any assistance on this. I
have reached my limit of creativity.
Cheers.

  #2   Report Post  
Posted to microsoft.public.excel.misc
robert111
 
Posts: n/a
Default COMPLEX PROBLEM


Could you set up a pivot table and using the top left box, select
whether current period or not, and then put client code number as row
headers, and in the middle use sum of client code number.

I think this will tell you how many times each client has visited in
the current month.


--
robert111
------------------------------------------------------------------------
robert111's Profile: http://www.excelforum.com/member.php...o&userid=31996
View this thread: http://www.excelforum.com/showthread...hreadid=529174

  #3   Report Post  
Posted to microsoft.public.excel.misc
elephant
 
Posts: n/a
Default COMPLEX PROBLEM

Thanks. The problem is not to recall the number of times a client has
visited. How can I code each visit as new so long as the first visit is
within the month?

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Importing XML containing Complex Elements troy Excel Discussion (Misc queries) 0 September 29th 05 06:27 PM
Urgent Help Required on Excel Macro Problem Sachin Shah Excel Discussion (Misc queries) 1 August 17th 05 06:26 AM
Problem With Reference Update Egon Excel Worksheet Functions 17 July 16th 05 05:45 AM
Copy an Drag cell Formula Problem Nat Excel Discussion (Misc queries) 1 June 20th 05 03:24 PM
problem office assistant R.VENKATARAMAN Excel Discussion (Misc queries) 0 June 15th 05 06:22 AM


All times are GMT +1. The time now is 12:02 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"