On October 23, 2014 11:50:36 PM EDT, Sytze de Boer <[email protected]> wrote:
>  Tracy, thank you, but it gives me a Function argument, type, or count
>  is
>  invalid
>  I began with
>  dFiscalstart=ctod("01/02/2000")
>  
>  Did I do wrong ?
>  
>  
>  On Fri, Oct 24, 2014 at 4:40 PM, Tracy Pearson
>  <[email protected]>
>  wrote:
>  
>  > On October 23, 2014 11:18:57 PM EDT, Sytze de Boer
>  <[email protected]>
>  > wrote:
>  > >  Friends, I wonder if you can help
>  > >
>  > >  I have a dozen or so reports which are based on the following
>  routine
>  > >
>  > >  SELECT client,stockcode,IIF(trantype='I',ttlamount,ttlamount*-1)
>  as
>  > >  amount,
>  > >  YEAR(invdate) as year,invdate,sperson, stktype;
>  > >  FROM (lcSource) where trantype $ "CI" INTO table temp
>  > >
>  > >  When I then base a pivot report on the date Year factor, the
>  columns
>  > >  are
>  > >  per Calendar year.
>  > >
>  > >  This is ok, except I now have a number of clients whose
>  financial
>  > >  year is 1
>  > >  April to 31 March or other and are asking me to change this.
>  > >
>  > >  Does anyone have a quick work around for me.?
>  >
>  > Store the fiscal year beginning date. Then use it in your
>  selection.
>  >
>  >
>  > SELECT client,stockcode,IIF(trantype='I',ttlamount,ttlamount*-1) as
>  > amount,
>  >
>  
> Iif(invdate>=date(year(invdate),month(dFiscalStart),day(dFiscalStart)),1,0)+YEAR(invdate)
>  > as year,invdate,sperson, stktype;
>  > FROM (lcSource) where trantype $ "CI" INTO table temp
>  >
>  >
>  > Usually the fiscal year is the year it ends in.
>  >
>  > HTH,
>  > Tracy
>  >
>  > --
>  > Tracy
>  >
[excessive quoting removed by server]

_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/profox
OT-free version of this list: http://mail.leafe.com/mailman/listinfo/profoxtech
Searchable Archive: http://leafe.com/archives/search/profox
This message: 
http://leafe.com/archives/byMID/profox/[email protected]
** All postings, unless explicitly stated otherwise, are the opinions of the 
author, and do not constitute legal or medical advice. This statement is added 
to the messages for those lawyers who are too stupid to see the obvious.

Reply via email to