These functions is similar to the functions HrSum( ), JrSum( ), and SrSum( ) except:
1. | If the number of races meeting 'fCondition' is smaller than nRaces, the function will return .NULL. |
2. | Although these functions accept 5 arguments, the 4 th argument will always be ignored. |
Syntax
HrXSum('nValueExpr',nRaces,'fCondition',nDefaultValue,cIncluding)
JrXSum('nValueExpr',nRaces,'fCondition',nDefaultValue,cIncluding)
SrXSum('nValueExpr',nRaces,'fCondition',nDefaultValue,cIncluding)
Argument |
Description |
Example |
||||||||
'nValueExpr' |
|
'HrDvdWin( )' |
||||||||
nRaces |
|
6 |
||||||||
'fCondition' |
|
'For HrFP( )=1 While HrDate( )>Date(1999,9,1)' |
||||||||
nDefaultValue |
Default value returned when no race satisfying the specified condition can be found. The data type of this value must be identical to that of normal return value. |
|||||||||
cIncluding |
When applying the function to past records, by default, races in the underlying meeting are not included. You may use this argument to change the scope. See the following page for details: The cIncluding Argument. |
'R' |
Returns
Numeric
Examples
HrXSum('HrWinTicket( )',3)
The above example returns the sum of win investment of the last 3 races of the horse.
HrXSum('HrWinTicket( )',4,'For HrDistance( )=1400')
The above example returns the sum of win investment of the last 4 1400m races of the horse.
HrXSum('HrWinTicket( )',,'For HrDistance( )=1400 and HrAveRating( )>100',95)
The above example returns the sum of win investment of all races meeting the following conditions:
1. 1400m race
2. Average rating of the race is greater than 100
Page url: http://www.racematenet.com/english/help/index.html?hrxsum.htm