- 数值计算
- 字符串计算
- 数组计算
- 日期计算
- 选择语句
- 变量
log : 求以10为底的对数
ln : 求自然对数
sin : 求正弦
cos : 求余弦
tan : 求正切
ctan : 求余切
exp : 求以e为底的指数
sqrt : 求平方根
round : 四舍五入
int/integer : 求整数部分 int (12.34)=12 int -12.34)=-12
frac : 求小数部分 frac (12.34)=0.34 frac (-12.34)=-0.34
byte : 求位值 byte (4321.789,0)=1 byte (4321.789,-2) =8 byte ("4321.789",2)=3
toNumber :转换为数字
ln : 求自然对数
sin : 求正弦
cos : 求余弦
tan : 求正切
ctan : 求余切
exp : 求以e为底的指数
sqrt : 求平方根
round : 四舍五入
int/integer : 求整数部分 int (12.34)=12 int -12.34)=-12
frac : 求小数部分 frac (12.34)=0.34 frac (-12.34)=-0.34
byte : 求位值 byte (4321.789,0)=1 byte (4321.789,-2) =8 byte ("4321.789",2)=3
toNumber :转换为数字
upcase : 字符串大写
lowcase : 字符串小写
substr : 求字符串子串 substr ("123456",2,3)="345"
lpad : 左侧补充字符串
rpad : 右侧补充字符串
find : 求子串位置 find ("123456","34")=2 find ("123456","35")=-1
frequence : 求子串个数 find ("12345236","23")=2
capital : capital (123.45)="壹佰贰拾叁点肆伍" capital (123.45, true)="一二三.四五"
concat/strcat : 连接字符串 concat ("12","34","56")="123456"
match : 匹配*?为通配符 match ("abcd","a??d")=1, match ("abcd","a*d")=1
regexMatch : 正则表达式 regexMatch
regexMatchValue : 正则表达式匹配部分
toString : 转换为String
lowcase : 字符串小写
substr : 求字符串子串 substr ("123456",2,3)="345"
lpad : 左侧补充字符串
rpad : 右侧补充字符串
find : 求子串位置 find ("123456","34")=2 find ("123456","35")=-1
frequence : 求子串个数 find ("12345236","23")=2
capital : capital (123.45)="壹佰贰拾叁点肆伍" capital (123.45, true)="一二三.四五"
concat/strcat : 连接字符串 concat ("12","34","56")="123456"
match : 匹配*?为通配符 match ("abcd","a??d")=1, match ("abcd","a*d")=1
regexMatch : 正则表达式 regexMatch
regexMatchValue : 正则表达式匹配部分
toString : 转换为String
isEmpty : 判断参数是否为空 isempty("")=1
isNotEmpty : 判断参数是否为空 notempty("")=0
max : 求最大值 max (1,2,3,5,4) = 5
min : 求最小值 min (1,2,3,5,4) = 1
ave : 求均值 ave (1,2,3)=2
count : 计数 count(1,"2",3,"5",1,1,4) = 7
countNotNull : 计数 非空参数 countnotnull(1,,"2",,,,1,1,4) = 5
countNull : 计数空参数 countnull(1,,"2",,,,1,1,4) = 4
sum : 求和 sum (1,2,3,4,5) = 15
stddev : 求标准偏差
getAt : 求数组中的一个值 getat (0,"2","3")= "2" getat (0,2,3)= 2
singleton : 返回新的去掉重复元素的集合(set)
isNotEmpty : 判断参数是否为空 notempty("")=0
max : 求最大值 max (1,2,3,5,4) = 5
min : 求最小值 min (1,2,3,5,4) = 1
ave : 求均值 ave (1,2,3)=2
count : 计数 count(1,"2",3,"5",1,1,4) = 7
countNotNull : 计数 非空参数 countnotnull(1,,"2",,,,1,1,4) = 5
countNull : 计数空参数 countnull(1,,"2",,,,1,1,4) = 4
sum : 求和 sum (1,2,3,4,5) = 15
stddev : 求标准偏差
getAt : 求数组中的一个值 getat (0,"2","3")= "2" getat (0,2,3)= 2
singleton : 返回新的去掉重复元素的集合(set)
today/currentDatetime : 当前日期 包括时间
currentDate :当前日期 时间为0点
currentTimestamp : 当前时间戳
day :取日期在月中的序号,从1开始
month : 取日期的月份
year : 取日期的年份
week : 取日期在当年中 第几周
weekday :取日期的星期几,周日为0,周一~六为1~6
formatdate : 格式化日期
dayspan : 求两日期之间的天数,返回整数,计算这个周期中的天数, 包括 beginTime,endTime
datespan :求两日期之间的天数,返回浮点数,计算这个周期中的天数, 不足一天用小数表示
adddays : 加天数
addmonths : 加月数
addyears : 加年数
truncdate : 截断日期 第二个参数 Y ,M , D 分别返回一年、月的第一天 ,或者一日的零点
firstofmonth : 求这个月的第一天
toDate :转换为日期
currentDate :当前日期 时间为0点
currentTimestamp : 当前时间戳
day :取日期在月中的序号,从1开始
month : 取日期的月份
year : 取日期的年份
week : 取日期在当年中 第几周
weekday :取日期的星期几,周日为0,周一~六为1~6
formatdate : 格式化日期
dayspan : 求两日期之间的天数,返回整数,计算这个周期中的天数, 包括 beginTime,endTime
datespan :求两日期之间的天数,返回浮点数,计算这个周期中的天数, 不足一天用小数表示
adddays : 加天数
addmonths : 加月数
addyears : 加年数
truncdate : 截断日期 第二个参数 Y ,M , D 分别返回一年、月的第一天 ,或者一日的零点
firstofmonth : 求这个月的第一天
toDate :转换为日期
if : if (1,2,3)= 2 if (0,"2","3")= "3"
case : 第一个参数是条件,后面匹配值成对出现,不成对的为默认值 case(1,2,3)= null,case(1, 2,3, 1,"5")= "5",case(0, 1, "2","3")= "3"
case : 第一个参数是条件,后面匹配值成对出现,不成对的为默认值 case(1,2,3)= null,case(1, 2,3, 1,"5")= "5",case(0, 1, "2","3")= "3"