如何添加 p4sql 查询作为 Perforce 自定义工具参数?
我正在尝试添加 此 p4sql 查询< 作为 P4V (Windows) 中的自定义工具
-s "select * from changes where lcase(description) like '$%$D$%' and p4options='longdesc';"
/a> 通过添加 p4sql.exe 作为应用程序和参数
。 当我执行命令并输入“123”作为输入时,会返回以下错误:
p4sql error:
Usage: p4sql -h for usage.
Option: 12 is undefined.
我缺少什么转义机制?
I'm trying to add this p4sql query as a Custom Tool in P4V (Windows) by adding p4sql.exe as the application and
-s "select * from changes where lcase(description) like '$%$D$%' and p4options='longdesc';"
as Arguments.
When I execute the command and enter '123' as input, the following error comes back:
p4sql error:
Usage: p4sql -h for usage.
Option: 12 is undefined.
What escape mechanism am I missing?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我最近更新了问题正如我所说,P4V 中存在一个错误,并且 P4SQL 似乎也很不稳定。 如果在“$%”和“$D”之间放置空格,有时可以让它工作。 将其更改
为
:进行此更改后,它有时会起作用,但某些搜索仍然会失败,因为这些空格成为搜索字符串的一部分。 我还注意到一些搜索失败的原因我无法解释。 我去年 10 月向 Perforce 报告了这个问题,他们确认这是一个错误,但尚未修复。
您最好使用另一个问题中提到的解决方案之一。 使用 P4Win 或将更改列表转储到文件中,然后搜索该文件。
I recently updated the question you referenced and, as I stated, there is a bug in P4V, and P4SQL seems pretty flaky as well. You can get it to work some of the time if you put spaces between the "$%" and the "$D". Change this:
to this:
It will work some of the time after making this change, but some searches will still fail as those spaces become part of the search string. I've also noticed some searches fail for reasons I can't explain. I reported this to Perforce last October, and they confirmed it was a bug, but have yet to fix it.
You're better off using one of the solutions mentioned in the other question. Use P4Win or dump the change lists to a file and then search the file.