发新话题
打印

[已解决] 请教一下为什么不加时分秒就可以,加了时分秒就不行。( 此文章被查看:309次,被回复:8篇!! )

本主题由 懂你 于 2008-4-17 13:35 关闭

请教一下为什么不加时分秒就可以,加了时分秒就不行。

为什么不加时分秒就可以,加了时分秒就不行。

cleartool find "Y:\code\test" -type f -version "created_since(20080216)"  -print
这样可以

cleartool find "Y:\code\test" -type f -version "created_since(20080216 053020)"  -print
这样保错:
cleartool: Error: Invalid query: "created_since(20080216 053020)"


问题已经解决 [打开主题]
本主题的最佳答案为 [ 9 楼].



© 本文为 onunixSCMLife 共同所有,未经同意,请勿转载 ©如该文侵犯了您的版权,请联系管理员

TOP

日期和时间之间不要留空格,改成下划线试试看



© 本文为 lovakar_scmlifeSCMLife 共同所有,未经同意,请勿转载 ©如该文侵犯了您的版权,请联系管理员

TOP

测试了一下,下面的修改方法都不行
cleartool find "Y:\code\test" -type f -version "created_since(20080216_053020)"  -print
cleartool find "Y:\code\test" -type f -version "created_since(20080216-053020)"  -print

转载请注明源自www.SCMLife.com,请保留版权. 本贴地址:http://bbs.scmlife.com/viewthread.php?tid=11904



© 本文为 onunixSCMLife 共同所有,未经同意,请勿转载 ©如该文侵犯了您的版权,请联系管理员

TOP

20080216-05:30:20

© 本文为 lingd 所有,未经同意,请勿转载
©如该文侵犯了您的版权,请联系管理员

TOP

这里有讲到查询命令中,关于时间写法格式

在安装了CC的机子上,一定可以找到以下这个文件,这里有详细的格式写法和例子
C:\Program Files\Rational\ClearCase\doc\help\cc_ref\query_language.htm

© 本文为 rossa2003 所有,未经同意,请勿转载
©如该文侵犯了您的版权,请联系管理员

TOP

还是不行。
查到该书:
C:\Program Files\Rational\ClearCase\doc\help\cc_ref\query_language.htm

书中的解释如下,按照该解释写的语句应该是:
cleartool find "Y:\code\test" -type f -version "created_since(02-16-2008.2:0:0)"  -print
created_since (date-time)

但是这样执行也不成功,错误提示相同。

附录:该书的说明
In all cases, TRUE if the object was created since date-time. The date-time argument can have any of the following formats:
date.time | date | time |now where:

date
:=
day-of-week | long-date

time
:=
h[h]:m[m][:s[s]] [UTC [ [ + | - ]h[h][:m[m] ] ] ]

day-of-week
:=
today |yesterday |Sunday | ... |Saturday |Sun | ... |Sat

long-date
:=
d[d]–month[–[yy]yy]

month
:=
January |... |December |Jan |... |Dec


Specify the time in 24-hour format, relative to the local time zone. If you omit the time, the default value is 00:00:00. If you omit the date, the default is today. If you omit the century, year, or a specific date, the most recent one is used. Specify UTC if you want to resolve the time to the same moment in time regardless of time zone. Use the plus (+) or minus (-) operator to specify a positive or negative offset to the UTC time. If you specify UTC without hour or minute offsets, Greenwich Mean Time (GMT) is used. (Dates before January 1, 1970 Universal Coordinated Time (UTC) are invalid.)

© 本文为 onunix 所有,未经同意,请勿转载
©如该文侵犯了您的版权,请联系管理员

TOP

铃(lingd)的建议:
20080216-05:30:20
也不行。

© 本文为 onunix 所有,未经同意,请勿转载
©如该文侵犯了您的版权,请联系管理员

TOP

使用 (2008-02-16T05:30:20+08)
我验证过,可以执行

© 本文为 lovakar_scmlife 所有,未经同意,请勿转载
©如该文侵犯了您的版权,请联系管理员

TOP

正解,    谢谢海风


最佳答案
该回答被楼主/管理员列为正解!

© 本文为 onunix 所有,未经同意,请勿转载
©如该文侵犯了您的版权,请联系管理员

TOP

发新话题