Created
February 24, 2021 13:06
-
-
Save krisrice/8e27c027bffbf37739f22d2dd6cc15d8 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
script | |
// issue the sql | |
var binds = {} | |
var ret = util.executeReturnList('select help_text,page_name from APEX_APPLICATION_PAGES where rownum=1 and help_text is not null',binds); | |
// loop the results | |
for (i = 0; i < ret.length; i++) { | |
// debug is nice | |
ctx.write( ret[i].PATH+ "\n"); | |
// get the CLOB stream | |
// get the path/file handle to write to | |
var path = java.nio.file.FileSystems.getDefault().getPath(ret[i].PAGE_NAME + "_help.txt"); | |
// dump the file stream to the file | |
java.nio.file.Files.copy( ret[i].HELP_TEXT.getAsciiStream(),path); | |
blobStream.close(); | |
} | |
/ | |
!ls *help.txt |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment