oracle - 文件路径无效
问题描述
我正在 TOAD 中测试以下代码。
create directory test_dir AS 'c:\';
DECLARE
fileHandler UTL_FILE.FILE_TYPE;
BEGIN
fileHandler := UTL_FILE.FOPEN('test_dir', 'test_file.txt', 'W');
UTL_FILE.PUTF(fileHandler, 'Test writing to a file.\n');
UTL_FILE.FCLOSE(fileHandler);
EXCEPTION
WHEN utl_file.invalid_path THEN
raise_application_error(-20000, 'ERROR: Invalid PATH FOR file.');
END;
它返回以下错误:
Error at line 1
ORA-20000: ERROR: Invalid PATH FOR file.
ORA-06512: at line 9
谁能告诉我如何解决这个错误?非常感谢!
解决方案
推荐阅读
- node.js - 升级超级账本结构网络后通道创建失败
- python - 标签数组维度正确但检查目标时仍然出错
- java - 在 Java 中,为什么公共接口必须是文件中声明的唯一公共接口,为什么文件必须与该接口同名?
- angularjs - AngularJS:主页加载后加载更多数据
- c - c中的程序打印带有*模式的x和y的矩形
- python - 如何解决 pip 本身的版本冲突?
- node.js - Docker:尝试使用 docker 访问 mongoDB 时未处理的 Promise 拒绝
- node.js - 如何从 mongodb 中获取比特定文档更新的文档?节点/猫鼬
- ios - iOS Xamarin 将 tabBar 推送到导航控制器上
- function - 查询访问中的 IIF 函数