从 AS400 中的根目录移动文件
我有一个脚本,可以将文件从 AS400 目录移动并重命名到单独服务器上的 Windows 目录。成功的过程从 AS400 上的库中创建的文件夹中移动数据。由于技术原因,AS400 开发人员将源数据移至 AS400 的根目录。
现在我已经修改了脚本以指向不同的源,我收到错误“无效的过程调用或参数”。我的问题是我们可以从 AS400 根移动数据还是必须将其驻留在库中?我仍然可以从库中移动文件,但不能从根目录移动文件。有什么建议吗?谢谢!
I have a script which moves and renames files from an AS400 directory to a Windows directory on a separate server. The successful process moves data from a folder created in a library on the AS400. For technical reasons the AS400 developer moved the source data to the root on the AS400.
Now that I have modified the script to point to the different source I get an error "Invalid procedure call or argument". My question is can we move data from the AS400 root or does it have to reside within a library? I can still move files from within the library but not from the root. Any advice? Thanks!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
如果我正确阅读您的评论(以及您的上一个问题),您需要能够移动文件覆盖。一种方法是复制和删除。
CopyFile
默认情况下会覆盖文件。请参阅以下 MSDN 页面,了解
CopyFile< /code>
和
DeleteFile
了解更多详细信息。If I'm reading your comment (and your previous question) correctly, you need to be able to move a file with the ability to overwrite. One way to do that is by copying and deleting.
CopyFile
will overwrite a file by default.See the following MSDN pages for
CopyFile
andDeleteFile
for additional details.如果根目录是“/”,那么这不是一个库,您将拥有一个类似于 Windows 机器上的平面文件。您很可能无法使用现有的工具包来实现此目的,但也许可以使用 CPYSTRF 或类似的工具包?你能直接从 Windows 盒子里 ftp 进去吗?
If the root is "/" then this is not a library and you are having a flat file similar to what it will be on the Windows box. You will most likely not be able to use your existing toolkits for this, but perhaps CPYSTRF or similar? Can you just ftp it in from the Windows box?