900字范文,内容丰富有趣,生活中的好帮手!
900字范文 > oracle %date 0 10% “date:~0 10%“是什么意思?

oracle %date 0 10% “date:~0 10%“是什么意思?

时间:2019-05-13 03:56:02

相关推荐

oracle %date 0 10% “date:~0 10%“是什么意思?

基础知识,基础知识太差了。查了半天,先补补课吧。

“date:~0,10%是DOS里取日期的命令。

echo :~1,5% //指针向右→偏移1位,然后从指针处开始向右→提取5个字符.

echo :~0,-3% //指针不偏移,→提取所有字符,并除去最后3个字符.

echo :~5% //单个数字,不指定长度值.表示指针→偏移5个字符,然后,→提取所有字符.

echo :~-5% //单个负值,特例,表示指针反方向偏移,从最右端起,←偏移5位,然后从指针处开始→提取所有字符.也可以简单理解为提取字符串末尾5个字符。

C:\Documents and Settings\user>echo %date%

-08-08 星期三

C:\Documents and Settings\user>echo %date:~5,10%

08-08 星期三

C:\Documents and Settings\user>echo %date:~5,4%

08-0

C:\Documents and Settings\user>echo %date:~5,5%

08-08

C:\Documents and Settings\user>

阅读(12482) | 评论(1) | 转发(1) |

本内容不代表本网观点和政治立场,如有侵犯你的权益请联系我们处理。
网友评论
网友评论仅供其表达个人看法,并不表明网站立场。