如何在 MSBuild 中执行 Oracle 实用程序
我想在 MSBuild 中执行 oracle 的导入实用程序作为任务。 请给予详细解答。 我是初学者。
I want to execute the oracle's import utility in MSBuild as a task. Please give a detailed answer. I am a beginner.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
更多
发布评论
评论(2)
您可能需要查看 MSBuild Exec 任务。 我不熟悉您指定的 Oracle 实用程序,但我知道 Exec 任务将运行大多数可以从命令行运行的任何内容。 您需要的相关 MSBuild 配置可能如下所示:
You may want to look into the MSBuild Exec task. I am not familiar with the Oracle utility you specified, but I do know that the Exec task will run most anything that can be run from a command line. The relevant MSBuild configuration you would need might looks something like this:
一个稍微冗长但更好的解决方案是开发一个自定义任务来扩展 ToolTask 基类。 这将允许更好的日志记录,并且您可以使用特定的 XML 属性来定义参数。
我为 SqlPlus 开发了一个,它运行得非常好。
A somewhat more long-winded but better solution is to develop a custom Task that extends the ToolTask base class. This will allow better logging and you can define the arguments by using specific XML attributes.
I've developed one for SqlPlus and it works really well.