Help in writing a file in server DIR

create or replace  procedure write_file
as
   v_file   UTL_FILE.file_type;
   vFileName   varchar2(100);  
   v_Details    varchar2(100);
begin
    --  a
    vFileName := 'INSERT.txt';
    v_Details := '12^AB';
    v_file := UTL_FILE.FOPEN ('SALDIR', vFileName, 'W');
     UTL_FILE.put_line (v_file, v_Details);
end ;here SALDIR is server directory ..
but i m getting error
  ORA-29283: invalid file operation
ORA-06512: at "SYS.UTL_FILE", line 488
ORA-29283: invalid file operation
ORA-06512: at "SALUSER.WRITE_FILE", line 13
ORA-06512: at line 1

[http://ora-29283.ora-code.com/]
Check your permissions, also that you have actually created the directory.
You can find working examples @ [Morgans Library|http://www.morganslibrary.org/reference/utl_file.html]

Similar Messages

  • Help with writing .bashrc file

    I would like help with writing a .bashrc file.
    The only thing I want right now is colored output and slashes for directories like what "ls -GF" does -- for each new terminal window.
    Can you guys give me a hand?
    Running Mac OS 10.4.6. Bash is default shell.
    Thanks.

    Hi Paul,
       You can get Apple's "ls" command to always output color with the following in your .bashrc:
    export CLICOLOR=""
    You can have an effect on the colors used with settings like the following:
    export LSCOLORS="gxfxcxdxbxegedabafacad"
       I have a color prompt in my bash startup scripts, bashrc.tgz. If you unpack the tarball in the root of your home directory, the files will be put in a ~/Library/init/bash directory. The file named "prompt" sets the color prompt string.
    Gary
    ~~~~
       I know you think you thought you knew what you
       thought I said, but I'm not sure you understood what
       you thought I meant.

  • Download and upload of file to server dir (AL11)

    Hello,
    I have a custom program that is downloading files from application server directory (they are like templates) to user local pc. User is then modifying such files and finally upload them in another AS directory.
    The program is currently making use of FM's C13Z_FILE_DOWNLOAD_BINARY and  C13Z_FILE_UPLOAD_BINARY.
    There was no problem until hot packages have been implemented: now such FM's are returning an error saying:
    Internal program error; (YDOWNLOAD SAPLC13Z 0 C13Z_RAWDATA_WRITE)
    When in debug, it appears that the FM C13Z_RAWDATA_WRITE (called by the above mentioned FM's) is checking the calling program (sy-cprog) and if this latter is not within a list of standard programs (hardcoded), then the error is thrown.
    My question is: Is there another way to download and upload files without such error? Could you please share the code?
    Thanks a lot for help and suggestions!
    Best regards,
    JFlanders

    Hello,
    Please see note   1809258 - Internal program error; ( <program name> SAPLC13Z 0 C13Z_RAWDATA_READ )
    A possibile solution is to use cl_gui_frontend_services class methods like gui_download and gui_upload, for instance:
    TYPES: t_line(1) type x.
    DATA: i_tab TYPE STANDARD TABLE OF t_line,
        i_wa(1) type x.
    OPEN DATASET lv_file_appl FOR INPUT IN BINARY MODE.
    DO.
      CLEAR i_wa.
      READ DATASET lv_file_appl INTO i_wa.
      IF SY-SUBRC <> 0.
        EXIT.
      ELSE.
        APPEND i_wa TO i_tab.
      ENDIF.
    ENDDO.
    CLOSE DATASET lv_file_appl.
    DATA: lv_fn TYPE string.
    lv_fn = lv_file_name.
    CALL METHOD cl_gui_frontend_services=>gui_download
      EXPORTING
        filename                = lv_fn
        filetype                = 'BIN'
        append                  = ' '
      CHANGING
        data_tab                = i_tab
      EXCEPTIONS
        file_write_error        = 1
        no_batch                = 2
        gui_refuse_filetransfer = 3
        invalid_type            = 4
        no_authority            = 5
        unknown_error           = 6
        header_not_allowed      = 7
        separator_not_allowed   = 8
        filesize_not_allowed    = 9
        header_too_long         = 10
        dp_error_create         = 11
        dp_error_send           = 12
        dp_error_write          = 13
        unknown_dp_error        = 14
        access_denied           = 15
        dp_out_of_memory        = 16
        disk_full               = 17
        dp_timeout              = 18
        file_not_found          = 19
        dataprovider_exception  = 20
        control_flush_error     = 21
        OTHERS                  = 24.
    * old functioanlity
    *    CALL FUNCTION 'C13Z_FILE_DOWNLOAD_BINARY'
    *      EXPORTING
    *        i_file_front_end       = lv_file_name
    *        i_file_appl            = lv_file_appl
    *        i_file_overwrite       = 'X'
    ** IMPORTING
    **    E_FLG_OPEN_ERROR          =  false
    **    E_OS_MESSAGE              =  lv_message
    *    EXCEPTIONS
    *      fe_file_open_error       = 1
    *      fe_file_exists           = 2
    *      fe_file_write_error      = 3
    *      ap_no_authority          = 4
    *      ap_file_open_error       = 5
    *      ap_file_empty            = 6
    *      OTHERS                   = 7
    This is for the download, similarly should be done for the upload.
    Hope this could help. Let me know if further details are needed.
    Thank you and bye,
    Flavio

  • Writing to file on server from applet

    ok i know this issue has been dealt with on numerous occasions but i would like someone to explain me in details what would be the best way of doing it.
    I know that one way of doing it is having a servlet which would perform I/O and would communicate with the applet via a socket. What I don't understand is when and how does the servlet start running.
    It has to be running to be able to first accept a connection from the applet and then listen on the specified port.
    So how does the servlet start running so as to be able to communicate with the applet?
    Could you please make your answers as precise as possible.
    Thanks

    Servlets are run by servlet containesr. You must start container first (Tomcat, Jetty, Weblogic, Websphere, ...) and then it will handle running servlet. Usually it is a first http-request that instantiates servlet on-demand, but you may configure it to be instantiated at container startup. So, only you have to worry about is to put servlet on container server and it will take care of the rest.
    Simple writing to a server-side file is easier to do with PHP if you have linux/unix-based web server. Just installing a servlet container for it might be a bit overkill.

  • File upload: problem with writing uploaded file to server-harddisk

    Hello,
    according to the example in the File upload tutorial, I tried to save an uploaded file to disk, but it didn't work (and also no messages / exceptions were thrown).
    The Javadoc for the function uploadedFile.write(filename) says that if the file should be written in an other directory than the servers' tmp-directory, the server.policy has to be adjusted.
    The following line is already included in my server.policy:
    permission java.io.FilePermission "<<ALL FILES>>", "read,write";
    So I have two questions:
    1) Where can I find the servers' tmp-directory?
    2) How should the sever.policy permission code look like?

    The File Upload tutorial at http://developers.sun.com/prodtech/javatools/jscreator/learning/tutorials/2/file_upload.html has you save the uploaded file to disk. It also gives this information:
    The server holds the uploaded file in memory unless it exceeds 4096 bytes, in which case the server holds the file contents in a temporary file. You can change this threshold by modifying the sizeThreshold parameter for the UploadFilter filter entry in the web application's web.xml file. For more information on modifying the web.xml file, see the last section in this tutorial, Doing More: Modifying the Maximum File Upload Size.
    In cases where you want to retain the uploaded file, you have three choices:
    * Write the file to a location of your choosing, as shown in this tutorial.
    * Create an UploadedFile property in a managed bean and set it to the component's value before you exit the page (as in the button's action method).
    * Save the file to a database.
    By default, the File Upload component can handle files up to one megabyte in size. You can change the maximum file size by modifying the maxSize parameter for the UploadFilter filter entry in the application's web.xml file, as described in the last section in this tutorial, Doing More: Modifying the Maximum File Upload Size.

  • Help with writing to file

    Hi,
    How would I write to the same file between different classes? Is it possible to just make a static writer class and then any class can call its function to write? Any help would be appreciated.

    This is exactly it. Thanks so much.You're welcome.

  • PLEASE HELP! Writing a file on the OAS

    Hi,
    I have a question please, I'm been able to create a file on the OAS which is my local machine on directory "c:\temp" with no problem :). but if I run the form from another workstation, it gives me an error "WUT-118 Application Server doesnt or is of zero file".
    what I see is, it looks to locate this directory on the worksation not "OAS".
    Any ideas?
    I have setup the webutil:
    transfer.appsrv.enabled=TRUE
    transfer.appsrv.workAreaRoot=c:\temp
    transfer.appsrv.accessControl=TRUE
    transfer.appsrv.write.1=c:\temp
    transfer.appsrv.read.1=c:\temp
    Am I missing anything here? Do I need to add anything to formsweb.cfg?

    Hi,
    I have a question please, I'm been able to create a file on the OAS which is my local machine on directory "c:\temp" with no problem :). but if I run the form from another workstation, it gives me an error "WUT-118 Application Server doesnt or is of zero file".
    what I see is, it looks to locate this directory on the worksation not "OAS".
    Any ideas?
    I have setup the webutil:
    transfer.appsrv.enabled=TRUE
    transfer.appsrv.workAreaRoot=c:\temp
    transfer.appsrv.accessControl=TRUE
    transfer.appsrv.write.1=c:\temp
    transfer.appsrv.read.1=c:\temp
    Am I missing anything here? Do I need to add anything to formsweb.cfg?

  • Need help in writing XML file!!!

    dear friends:
    I'm a learner in J2ME, and I understood how to parse a simple XML document with SAX parser, but it don't supply methods to write a XML file or store my data to a XML file.
    Somebody can tell me how to do?
    Thanks in advance.

    hello
    you can also read this:
    http://www.cafeconleche.org/books/xmljava/
    nice stuff !
    peace

  • Help with writing a batch file

    Hi :
    does anyone know anyplace online that I can get help in writing batch files?? I have never worked much with batch files before....
    any help is greatly appreciated
    thnx

    I suppose, since you're in a Java forum, you need batch files to load java applications.
    If you use windows :
    go to ms console (start/run/"cmd")
    type edit mybatch.bat
    write your command to load a java application, something like
    java myclass.class
    save and exit.
    Be sure the bat file and the class are in the same folder.
    And make certain you've set the classpath, and path variables correctly.
    If this was what you needed and you need more help just ask.
    (In this case it could be better to make executable jars)
    If you wanted to know about linux batches, it works pretty the same way.

  • Applet: writing to file

    hi there.
    i need serious help on using an applet and writing the user response into a text file.
    issit possible in the first place? cos i read at a lot of sources saying applet cant write to file?
    any help is much appreciated
    thx!

    Where do you plane on writing the file to server where the applet is or on the client machine? Applets can only write to files that are on the same filesystem or on the same machine that it was loaded into the browser from. So if you want user to run this applet and have it write out a file you will have to get them to download the .class file and then run it from their computer.
    here is somthing might help a bit more.
    http://java.sun.com/sfaq/#read
    Please give more detail about what you want to.

  • Please can anyone help me..I can not get itunes to install,i get a error message writing to file c and says i need to verify access to directory please help me

    I need help in trying to install I Tunes,,,after multiple attempts I have now pulled all my hair out,and I am without I Tunes,,,I have tried everything ,and all the ideas that I have found in trying to seach the reason for my problem.it will download quick time,,,it gets about half way through I Tunes and I get a error message that says...........Error writing to File C /program files x86  itunes .tunes exc.verify you have access to that directory......I need the wisdom of any and all that are smarter than I about this issue.........I would appreciate any and all help ..thank you....

    iOS: Unable to send or receive email
    http://support.apple.com/kb/TS3899
    Can’t Send Emails on iPad – Troubleshooting Steps
    http://ipadhelp.com/ipad-help/ipad-cant-send-emails-troubleshooting-steps/
    Setting up and troubleshooting Mail
    http://www.apple.com/support/ipad/assistant/mail/
    Server does not allow relaying email error, fix
    http://appletoolbox.com/2012/01/server-does-not-allow-relaying-email-error-fix/
    Why Does My iPad Say "Cannot Connect to Server"?
    http://www.ehow.co.uk/info_8693415_ipad-say-cannot-connect-server.html
    iOS: 'Mailbox Locked', account is in use on another device, or prompt to re-enter POP3 password
    http://support.apple.com/kb/ts2621
    iPad Mail
    http://www.apple.com/support/ipad/mail/
    Configuration problems with IMAP e-mail on iOS with a non-standard SSL port.
    http://colinrobbins.me/2013/02/09/configuration-problems-with-imap-e-mail-on-ios -with-a-non-standard-ssl-port/
    Try this first - Reset the iPad by holding down on the Sleep and Home buttons at the same time for about 10-15 seconds until the Apple Logo appears - ignore the red slider - let go of the buttons. (This is equivalent to rebooting your computer.)
    Or this - Delete the account in Mail and then set it up again. Settings->Mail, Contacts, Calendars -> Accounts   Tap on the Account, then on the red button that says Remove Account.
     Cheers, Tom

  • Writing data to a file in Server

    Hi all,
    In my application i would be writing data to a file which is located in the Server.
    when i tried writing data to a file in my local machine using a Java Application it worked fine .
    Now through the webdynpro application and providing the files path (in server ) ,i am getting file not found exception .
    I am using basic File and i/o operations .
    File abc = new File ("
    servernamer
    folder1
    subfolder1
    filename.dat");
    when i try accessing this path from the command prompt its opening fine.
    Could you please through some light on this .
    thanks,
    swetha .

    >
    KalluriVijay wrote:
    > Hi Swetha,
    > Do one think.
    > InputStream text = null;
    >                int temp = 0;
    >                //File file = new File(wdContext.currentContextElement().getResource().getResourceName().toString());
    >                //wdComponentAPI.getMessageManager().reportSuccess("filePath Vijay:::"+file);     
    > //wdComponentAPI.getMessageManager().reportSuccess("filePath Vijay:::");
    >                     try
    >                     {
    >                     String fileName = wdContext.currentContextElement().getResource().getResourceName().toString();               
    >                     if(fileName.equalsIgnoreCase("ASNCRT.dat"))
    >                     {     
    >                     File file = new File(fileName);                         
    >                     FileOutputStream op = new FileOutputStream(file);          
    >                     if (wdContext.currentContextElement().getResource()!= null)
    >                     {
    >                     text = wdContext.currentContextElement().getResource().read(false);
    >                     while((temp=text.read())!= -1)
    >                     {
    >                     op.write(temp);
    >                     }
    >                     }
    >                     op.flush();
    >                     op.close();
    >                     path = file.getAbsolutePath();
    >                     //wdComponentAPI.getMessageManager().reportSuccess(path);
    >                     }
    >                     else
    >                     {
    >                     wdComponentAPI.getMessageManager().raiseException("Please Check the Filename:Filename should be ASNCRT.dat ",true);     
    >                     }
    >                     }
    >                     catch(Exception ex)               
    >                     {
    >                     ex.printStackTrace();
    >                     }
    > By using this code u can put u r file in to Server Path, then u will get the that .dat file from server path and run the command prompt its opening fine
    > How to get the file from the Server Path:
    > Workbook wb = Workbook.getWorkbook(new File(path));     // For get the file from the Server path
    >
    >   Hope this is help full for u
    > Regards
    > Vijay Kalluri
    This won't work. First, like i said, File class is not for accessing remote files, it is only for local files.
    Second, Workbook class is a class from Java Excel API. He is not working with xls. Anyway that wouldn't work either.

  • When downloading iTunes, I got a message about error writing to file and it told the file. Then it said to verify that you have access to that directory. I have no idea how to fix it. I could really use some help, please.

    I was trying to download iTunes on my computer, and while doing so, I got this message: Error writing to file: C:/Program Files (x86)/Common Files/Apple/Apple Application Support/Apple Versions.dll. Verify that you have access to that directory. I have downloaded iTunes numerous times and I have never had this problem. If anyone knows what's going on, I would really appreciate the help.

    Well, there's definitely a mac and a Windows version. And you're at the right page. I think the problem is that someone forgot (or decided not to) to update the text at teh bottom of the page to have Mac and Windows.
    Just push the button, you'll get the Mac update no problem.
    Regards,
    Bentley Wolfe
    Senior Support Engineer, Flash/Flash Player/Digital Editions
    Adobe

  • Can you please help to understand how the firefox decides on the Expires date for a cached javascript file ( my server did not set any Expire header, but firebox set it down).

    # Question
    Can you please help to understand how the firefox decides on the Expires date for a cached javascript file ( my server did not set any Expire header, but firebox set it down). I tried to understand but different javascript file gets different Expires date value when it is being cached. Please help me as I tried lot and could not get proper answer for this. Thanks in Advance.

    Try posting at the Web Development / Standards Evangelism forum at MozillaZine. The helpers over there are more knowledgeable about web page development issues with Firefox. <br />
    http://forums.mozillazine.org/viewforum.php?f=25 <br />
    You'll need to register and login to be able to post in that forum.

  • Problem in French translation while writing a file on application server

    I am writing some text symbols to a file on application server using Transfer statement. But for some french characters the data is not transleted correctly. I have maintained the french translation for these text symbols.

    Hi,
    Make sure you use the correct encoding while writing your file.
    Regards.

Maybe you are looking for

  • How to configure standby database in a single machine

    I am in Windows XP professional and oracle 9i . I want to configure a standby database for a database called proddb in the same machine. For doing this, I created a standby controlfile. But this work for the same name standby database?. How this happ

  • How to skip columns in flatfile while uploading

    Hi everybody, I have a query related to transfer structure and flat file uploading... I have 15 columns in the flat file where in I want only first three columns and middlt 4 columns and last 1 column required for uploading into ODS. then how should

  • JCO Connect Exception for connecting to ABAP system

    Hey Guys, When running the program [code]import com.sap.mw.jco.*; public class TutorialConnect1 extends Object {    JCO.Client mConnection;    public Connect1() {      try {        // Change the logon information to your own system/user        mConne

  • Cannot install oracle 10g R1 client on redhat as 4

    I've got an oracle 10g r2 XE rdbms installed on a redhat as 4 system. I am trying to install the pro*c precompiler on this system because it is not included in the 10g r2 installation. It's not included in the 10g r2 client either. Is oracle planning

  • Delete database that's stuck in restoring mode

    Hi, one of the databases got stuck in restoring mode. I want to delete that without stopping sql service. I tried detaching and then deleting the physical files but didn't work. It just came back. I also tried deleting the database and then deleting