CREATE DIRECTORY

Create a directory - an alias for a filesystem pathname - used to store LOBs.

Syntax:

   CREATE [OR REPLACE] DIRECTORY directory AS 'pathname';

Example

Create or replace DIRECTORY dir_test as 'c:\test';

declare
MyFile utl_file.file_type;

begin
MyFile := utl_file.fopen('DIR_TEST', 'some_filename.txt', 'w');
utl_file.put_line(MyFile, 'Here is some example text');
utl_file.put_line(MyFile, 'Another line of text');
utl_file.fclose(MyFile);
end;
/

"Free at last! Free at last! Thank God almighty, we are free at last!" ~ Rev Martin Luther King JR

Related Commands:

DIRECTORY - DROP DIRECTORY

Related Views:

DBA_DIRECTORIES      ALL_DIRECTORIES


© Copyright SS64.com 1999-2013
Some rights reserved