Save Large Value code example

I am trying to import the above example into my APEX online workspace, the file is upload ok and the install application portion of the import completes.
The import supporting objects however hangs....
Is anyone else encountering this problem?
When i log back into the APEX workspace the application is visible but i can't seem to find the apex_save_large.js file in the shared components???
when i click on the save value or retrieve values in the sample form nothing happens....

Hello,
I'll look into the install issues, I've never seen it but I'll look again.
the $a() functions are included in the apex_save_large.js and will be included in the standard js files in a future version.
$x() is the new format of html_GetElement() so if your in a 2.0 instance just add
function $x(pNd){return html_GetElement(pNd);}
ver 2.2 should be fine.
Is this by design? If so, what are the reasons that it appears there instead of in the static files area.Developer Error and when I get my hands on that lazy guy he's gonna hear about it :)
When I have a second I'll fix it and get a new version uploaded to the code examples page.
I added a link to the js file here http://apex.oracle.com/pls/otn/f?p=27916:5
(hint for digging files out of workspace images adding this real quick to a page <a href="#WORKSPACE_IMAGES#filename.js">filename.js</a>)
Carl

Similar Messages

  • Save Large Value example & FCKeditor

    Hi,
    I have been trying to use code from example application 'Save Large Value' with FCKeditor. It doesn't work for me.
    So how make that code to work with FCKeditor text area?
    Your suggestions are really appreciated.
    Thanks,
    Vladimir

    Carl, thanks!
    I have been trying to use fckEditor API. At first I modified doSubmit because in my page this function should be called at the end of clob_SubmitReturn.
    I added three lines. But in spite of the fix the next page that is retrieved after submit returns an error 'Value param too long'
    function doSubmit(r){
    var oEditor = FCKeditorAPI.GetInstance('P1001_SOURCE') ;
    oEditor.SetHTML('');
    oEditor.UpdateLinkedField();
    $x('P1001_SOURCE').value = '';
    flowSelectAll();
    document.wwv_flow.p_request.value = r;
    document.wwv_flow.submit();
    Any ideas, suggestions?
    Thanks,
    Vladimir

  • Packaged Application - Save Large Value with multiple items

    I made an little application with 3 fields fckeditor. I tried to do the workaround "Save Large Value" with these 3 fields in the same page.
    Do you know how I can do that without the new apex.ajax.clob ? I'm on APEX 3.0.
    My application :
    workspace : listecd
    username : guest
    password : gu4est
    http://apex.oracle.com/pls/otn/f?p=47587:1
    Thanks.
    Sylvain
    Homepage : http://www.insum.ca
    InSum Solutions' blog : http://insum-apex.blogspot.com

    Hi Carl,
    In my application, I have two field FCKeditor. If I check the response of my http request in Firebug I see :
    Expecting p_company or wwv_flow_company cookie to contain security group id of application owner.
    <table summary=""><tr><td></td> <td>Error</td>
    <td>ERR-7621 Could not determine workspace for application (:) on application accept.
    </td></tr> <tr><td>OK</td> <td>
    </td></tr></table>
    Firebug show me this error but when I execute my page I have the right value. Why ?
    I have 3 problems with the integration of the FCKeditor :
    1 - Sometime when I load the data in the 2 fields, it doesn't save the value if it's more than 32k.
    2 - Sometime when I save the data I received this message :
    Bad Request
    Your browser sent a request that this server could not understand.
    mod_plsql:/pls/otn/wwv_flow.accept HTTP-400 Value param too long. Lenght is 73045. Upper limit is 32512.
    3 - When I catch the result of my AJAX with this string :
    $x('P2_COL1').value = p.responseText; This doesn't work well.
    I would like to use these strings :
    var oEditor = FCKeditorAPI.GetInstance('P2_COL1') ;
    oEditor.SetHTML(p.responseText);
    But I can't use them in my clob_GetReturn function because the FCKeditor is not implemented at this time. Where I can make this change ?
    Thanks.
    Sylvain
    Homepage : http://www.insum.ca
    InSum Solutions' blog : http://insum-apex.blogspot.com

  • Save large objects

    hallo,
    i use code from "Code Example (Save Large Value) 0.9" in my application. show of clob-field of a table works fine, but save into table dont work. what is the mistake?
    get_large:
    declare
    l_code clob := empty_clob;
    begin
    if(APEX_COLLECTION.COLLECTION_EXISTS(p_collection_name => 'CLOB_CONTENT'))then
    dbms_lob.createtemporary( l_code, false, dbms_lob.SESSION );
    SELECT blackboard into l_code FROM tab_function where function_id = :P148_FUNCTION_ID;
    declare
    l_clob_source2 clob;
    offset int:=1;
    begin
    loop
    l_clob_source2 := dbms_lob.substr(l_code,4000,offset);
    htp.prn(l_clob_source2);
    exit when offset + 4000 >= nvl(dbms_lob.getlength (l_code),0);
    offset := offset + 4000;
    end loop;
    end;
    end if;
    htmldb_application.g_unrecoverable_error := TRUE;
    end;
    save_large:
    declare
    l_code clob := empty_clob;
    begin
    dbms_lob.createtemporary( l_code, false, dbms_lob.SESSION );
    for i in 1..wwv_flow.g_f01.count loop
    dbms_lob.writeappend(l_code,length(wwv_flow.g_f01(i)),wwv_flow.g_f01(i));
    end loop;
         apex_collection.create_or_truncate_collection(p_collection_name => 'CLOB_CONTENT');
         apex_collection.add_member(p_collection_name => 'CLOB_CONTENT',p_clob001 => l_code);
         htmldb_application.g_unrecoverable_error := TRUE;
    end;
    who can help me?

    You need to create a directory object to import this file:
    Try this:
    eg:
    CREATE TABLE MY_IMAGE_TABLE (
    ID NUMBER,
    NAME VARCHAR2(20),
    IMAGE BLOB);
    CREATE OR REPLACE DIRECTORY IMAGES AS '/tmp';
    GRANT READ, WRITE ON DIRECTORY IMAGES TO PUBLIC;
    CREATE OR REPLACE PROCEDURE load_file_to_my_table (p_file_name IN MY_IMAGE_TABLE.NAME%TYPE) AS
    v_bfile BFILE;
    v_blob BLOB;
    BEGIN
    INSERT INTO MY_IMAGE_TABLE (id, name, image)
    VALUES (1, p_file_name, empty_blob())
    RETURN doc INTO v_blob;
    v_bfile := BFILENAME('IMAGES', p_file_name);
    Dbms_Lob.Fileopen(v_bfile, Dbms_Lob.File_Readonly);
    Dbms_Lob.Loadfromfile(v_blob, v_bfile, Dbms_Lob.Getlength(v_bfile));
    Dbms_Lob.Fileclose(v_bfile);
    COMMIT;
    END;
    execute load_file_to_my_table('myfhoto.jpg');
    cheers

  • Save variable value and locking the code

    Hi,
    I want to save some values of indicator on front panel in place of typing them each time. e.g,
    maximum velocity 1 mm/sec
    maximum accel .....
    Each time, while opening I want the values used in last experiment as default.
    I do not want to set a fixed default value, it should be from last experiment.
    Also, I have to lock the code so as no bady else can change it. But I do not know how.
    Any help is appreciated,
    Dushyant

    There is a VI method that will set all the values as default. However a VI can not call on itself, while it is running. So take a look at the attached code.
    The Main Project VI represents your code, and I added a password 123
    You would need to put that code at the very end of your code. Notice that I call the other VI and then finish. The other VI loads your VI, with password, and then sets the values to default once it stops running.
    Let me know if you have any questions.
    Attachments:
    Set Defaults.zip ‏20 KB

  • How to save a value in a byte array, retrieve it and display it?

    Hi,
    I am doing a project for my data structures class that involves saving a value (given in String format) in a byte array (our 'memory'). Initially I just tried casting character by character into the byte array and casting back to char[] for retrieval (using .toString() to return what's supposed to be the original string), but this did not work. I tried the .getBytes() method, applying it to the string and then trying to recover it by placing the contents of the 'memory' in a byte array and applying toString(), but that didn't work either. I looked a bit and found this class, CharsetEncoder and CharsetDecoder. I tried to use these but when I try the compiler tells me I cannot instantiate CharsetDecoder because it is an abstract class. At this point I'm at a loss as to what I can do. Is there any way to place a string in a byte array and then recover the string in it's original format? For example, I might save a value in my particular class of "456". But when I try to recover the value from my 'memory' i.e. the byte array, it comes out like [gnue@hnju.... or something similar. I need it to output the original string ("456").
    Below is my code as it is right now, for the methods setValue and getValue.
    Thanks!
    public void setValue(String value) throws InvalidValueException {
         //… stores the given value in the memory area assigned to the variable
              if(this.type.isValidValue(value)){
                   bytes = value.getBytes();
                   int i,j,k;
                   int l=0;//might be wrong?
                   int ad=address-(address%4);
                   mem.readWord(ad);
                   reg=mem.getDataRegister();
                   if((address%4)+bytes.length-1<4){
                        for(i=address%4;i<address%4+bytes.length;i++)
                             reg.setByte(i, bytes[i]);
                        mem.setDataRegister(reg);
                        mem.writeWord(ad);
                   else if((address%4)+bytes.length-1>=4){
                        if(address%4!=0){
                             for(i=address%4;i<4;i++){
                                  reg.setByte(i, bytes);
                                  l++;
                             mem.setDataRegister(reg);
                             mem.writeWord(ad);
                             ad+=mem.WORDSIZE;
                        while(ad<address+bytes.length-(address+bytes.length)%4){
                             for(j=0;j<4;j++){
                                  reg.setByte(j, bytes[j+l]);
                                  l++;
                             mem.setDataRegister(reg);
                             mem.writeWord(ad);
                             ad+=mem.WORDSIZE;
                        if((address+bytes.length)%4!=0){
                             mem.readWord(ad);
                             reg=mem.getDataRegister();
                             for(k=0;k<(address+bytes.length)%4;k++){
                                  reg.setByte(k, bytes[k+l]);
                                  l++;
                             mem.setDataRegister(reg);
                             mem.writeWord(ad);
                   else
                        throw new InvalidValueException("The value passed is not valid.");
         /** Gets the current value of the variable.
         @return current value converted to String
         public String getValue() {
              //… returns the current value stored in the corresponding memory area
              //… value is converted to String
              bytes=new byte[this.getType().getSize()];
              int i,j,k;
              int l=0;//might be wrong?
              int ad=address-(address%4);
              mem.readWord(ad);
              reg=mem.getDataRegister();
              if((address%4)+bytes.length-1<4){
                   for(i=address%4;i<address%4+bytes.length;i++)
                        bytes[i] = reg.readByte(i);
              else if((address%4)+bytes.length-1>=4){
                   if(address%4!=0){
                        for(i=address%4;i<4;i++){
                             bytes[i] = reg.readByte(i);
                             l++;
                        ad+=mem.WORDSIZE;
                   mem.readWord(ad);
                   reg=mem.getDataRegister();
                   while(ad<address+bytes.length-(address+bytes.length)%4){
                        for(j=0;j<4;j++){
                             bytes[j+l] = reg.readByte(j);
                             l++;
                        ad+=mem.WORDSIZE;
                   if((address+bytes.length)%4!=0){
                        mem.readWord(ad);
                        reg=mem.getDataRegister();
                        for(k=0;k<(address+bytes.length)%4;k++){
                             bytes[k+l] = reg.readByte(k);
                             l++;
              return bytes.toString();

    You can certainly put it into a byte array and then construct a new String from that byte array. Just calling toString doesn't mean you'll automatically get a meaningful string out of it. Arrays do not override the toString method, so the use the one inherited from object.
    Look at String's constructors.

  • How to save a value in a .txt n retrive back the exact value from the file?

    Well I have a number. Let's say 600. I need to save this value in a .txt file so that I can retrive this value. I tried using the below source code. It can be executed but I'll get num 49 everytime I execute it even though the value in my .txt is 600.
    try {
                   File inputFile = new File("Lt.txt");
                   File outputFile = new File("outagain.txt");
    FileReader in = new FileReader("Lt.txt");
    FileWriter out = new FileWriter(outputFile);
    int c;
              c = in.read();
              in.close();
    System.out.print("\nggggggggg"+c);
    in.close();
                   } catch (IOException ex) {
                   System.out.println("IOException:"+ex.toString());

    Thank you. I execute the program below. I can now retrive the data from the Lt.txt. But the value is limited to 3 digits. For example, the content of my file is 777888.
    When I run the program, I only get 777. How can I retrive the whole exact number?               
    import java.io.*;
                   class Test {     
                   public static void main(String args[]) {          
                   try {               
                   File inputFile = new File("Lt.txt");               
                   File outputFile = new File("outagain.txt");                    
                   FileReader in = new FileReader("Lt.txt");               
                   FileWriter out = new FileWriter(outputFile);               
                   char[] tmp = new char[3];               
                   int cnt = in.read(tmp);                              
                   System.out.print("\nRead: ");               
                   for (int i = 0; i < cnt; i++) {                    
                   System.out.print(tmp);               }               
                   System.out.println(" ");               
                   in.close();          }
                   catch (IOException ex) {               
                   System.out.println("IOException:"+ex.toString());          }     }}

  • How to save a value in form jsp?

    hi all,
    i have a dropdown list in my struts web app,
    i am having a form in which a bean is instatiated(bean has 2 properties "name" and "code").
    i am using like this in the jsp:
    <td><html:select property="item.code">
                             <logic:iterate id="itemType"
                                  name="<%=WebConstants.getItemTypeListName()%>">
                                  <option value='<bean:write name="ItemType" property="code"/>'><bean:write
                                       name="ItemType" property="name" /></option>                              
                             </logic:iterate>                         
                        </html:select></td>
    each "itemType" has "code" and "name".
    when the user clicks on the item name on the dropdown item beans "code" is populating.now i need to populate "name" aswell at the sametime using hidden property.
    i want to save tha value of name in the jsp to use it later to populate "name" in my form using hidden property?
    do anyone have idea how to save the value in jsp?
    regards and thanks in advance

    Thank you. I execute the program below. I can now retrive the data from the Lt.txt. But the value is limited to 3 digits. For example, the content of my file is 777888.
    When I run the program, I only get 777. How can I retrive the whole exact number?               
    import java.io.*;
                   class Test {     
                   public static void main(String args[]) {          
                   try {               
                   File inputFile = new File("Lt.txt");               
                   File outputFile = new File("outagain.txt");                    
                   FileReader in = new FileReader("Lt.txt");               
                   FileWriter out = new FileWriter(outputFile);               
                   char[] tmp = new char[3];               
                   int cnt = in.read(tmp);                              
                   System.out.print("\nRead: ");               
                   for (int i = 0; i < cnt; i++) {                    
                   System.out.print(tmp);               }               
                   System.out.println(" ");               
                   in.close();          }
                   catch (IOException ex) {               
                   System.out.println("IOException:"+ex.toString());          }     }}

  • Error in saving  large value with the data input query

    Hi,
       I  am  trying to save a large value in 0Quantity using the data input query into a realtime infocube
    e-g
    123456789.1234
    Error says too many digits.
    When i try to save 8 digits before the decimal point ,no error, if it is 9digits before decimal it's thro' error.
    Is there any limitation before the decimal.
    i know that 0Quantity can take 17 digits including the sign.
    Any suggestions.?
    regards,
    ram

    try budgetting in thousands in stead of units? (setting on query itself)
    D

  • I am trying to save a custom code snippet in Flash CC and it does not save, any ideas why?

    I am trying to save a custom code snippet in Flash CC and it does not save, any ideas why?  I am using Windows 8.1 with Flash CC.
    I even when into the "Edit Code Snippet XML" and added a Custom folder and a custom template.  Then I went back to add the code snippet again and it still did not work.
    About line 32, I added:
       <category title="Custom"
          isBranch="true" expanded="false"
          description="Code for common interactions">
          <snippet isBranch="false">
          <title>Custom Snippet</title>
          <description>This is an example of a custom code snippet.</description>
          <requiresSymbol>true</requiresSymbol>
          <code><![CDATA[
    // Code goes here
    trace("A custom code snippet");
          ]]></code>
        </snippet>
        </category>     
    Any assistance would be greatly appreciated.

    UserAgent for the OP is - Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.2.3) Gecko/20100405 Namoroka/3.6.3 - he might be running a 64-bit 3rd party build.

  • How do I save preferences/values using javascript in dashboard widget?

    How do I save preferences/values using javascript in dashboard widget? I apologize if this is a stupid question but I simply cant seem to find a way. For example, if on teh back side of the widget teh user chooses the color of the widget, where or how do I save that value so it is retained the next time the user goes to the dashboard. Also, once saved, how do I read the value?
    Thanks a mil....

    Please look into
    /Developer/Examples/Dashboard/Goodbye World/3-Saving Preferences directory for a comple example.
    Otherwise, wait until the following book is published :-))
    http://www.apress.com/book/bookDisplay.html?bID=10173
    Mihalis.

  • Beginner Question | The use of modulus in this simple code example.

    Hello everyone,
    I am just beginning to learn Java and have started reading "Java Programming for the absolute beginner". It is quite a old book but seems to be doing the trick, mainly.
    There is a code example which I follow mostly but the use of the modulus operator in the switch condition doesn't make sense to me, why is it used? Could someone shed some light on this for me?
    import java.util.Random;
    public class FortuneTeller {
      public static void main(String args[]) {
        Random randini = new Random();
        int fortuneIndex;
        String day;
        String[] fortunes = { "The world is going to end :-(.",
          "You will have a HORRIBLE day!",
          "You will stub your toe.",
          "You will find a shiny new nickel.",
          "You will talk to someone who has bad breath.",
          "You will get a hug from someone you love.",
          "You will remember that day for the rest of your life!",
          "You will get an unexpected phone call.",
          "Nothing significant will happen.",
          "You will bump into someone you haven't seen in a while.",
          "You will be publicly humiliated.",
          "You will find forty dollars.",
          "The stars will appear in the sky.",
          "The proper authorities will discover your secret.",
          "You will be mistaken for a god by a small country.",
          "You will win the lottery!",
          "You will change your name to \"Bob\" and move to Alaska.",
          "You will discover first hand that Bigfoot is real.",
          "You will succeed at everything you do.",
          "You will learn something new.",
          "Your friends will treat you to lunch.",
          "You will meet someone famous.",
          "You will be very bored.",
          "You will hear your new favorite song.",
          "Tomorrow... is too difficult to predict" };
        System.out.println("\nYou have awakened the Great Randini...");
        fortuneIndex = randini.nextInt(fortunes.length);
        switch (randini.nextInt(7) % 7) {   
          case 0:
            day = "Sunday";
            break;
          case 1:
            day = "Monday";
            break;
          case 2:
            day = "Tuesday";
            break;
          case 3:
            day = "Wednesday";
            break;
          case 4:
            day = "Thursday";
            break;
          case 5:
            day = "Friday";
            break;
          case 6:
            day = "Saturday";
            break;
          default:
            day = "Tomorrow";
        System.out.println("I, the Great Randini, know all!");
        System.out.println("I see that on " + day);
        System.out.println("\n" + fortunes[fortuneIndex]);
        System.out.println("\nNow, I must sleep...");
    }

    randini.nextInt(7) % 7randini.nextInt(7) returns a value in the range 0 <= x < 7, right? (Check the API!) And:
    0 % 7 == 0
    1 % 7 == 1
    2 % 7 == 2
    3 % 7 == 3
    4 % 7 == 4
    5 % 7 == 5
    6 % 7 == 6Looks like superfluous code to me. Maybe originally they wrote:
    randini.nextInt() % 7Note this code has problems, because, for example -1 % 7 == -1

  • How to select the larger value of column?

    I would like a cell value (here E8) to be for example: (max $E$1:E7) + B8. Where all previous E column values were find the same calculation except for E1 that is a simple number and not a calculation? It does not work. It give the result for E1 + B8. The larger value should be E7. So the correct result should be E7 + B8 but if there is no value in E7 I want it to choose the larger number of the E column so far. Does some one can help me?

    Hi Frederic,
    If I understand "Where all previous E column values were find the same calculation except for E1", you want each cell, starting at E2 to contain this formula.
    E2: =MAX($E$1:E1)+B2          E8: =MAX($E$1:E7)+B8
    If that's the case, then "there is no value in E7" would never occur, and, unless the value of Bn were negative, the maximum value in column E would always be the one immediately above the formula.
    In that case, this simpler formula would produce the same result:
    E2: =E1 + B2                        E8: =E7 + B8
    Regards,
    Barry

  • Need code example for dynamicly changing UI Propertey

    Hello,
    Can someone show me a simple code example that does the following:
    A view which contains a button and a label.
    Each press on the button changes the color (or other visible property) of the label.
    But note: Don't bind the property to the Context for that, I want to do it through the doModifyView method.

    hi Roy Cohen,
    I think u r not looking for the visibility property they have mentioned.
    I think u r looking for a procedure to change the way the element looks..is it..
    The problem is if u want any change to be visible when the button is pressed u can only change the length or the width.There is no option to change the semantic color or whatever.
    To change the size u can try this code
    IWDInputField in = (IWDInputField)view.getElement("<element name>");
    in.setWidth(some value which is set when the button is pressed);
    Is this wat u r looking for?
    Jus mention it if there is something  else.
    Regards
    Bharathwaj

  • Code example using interface controller ?

    Hi, guys:
    I have a question.
    In CRM UI, I need to integrate one component with another component, and I want to pass the value from 1st component to 2nd component using interface controller. Does any one who have done this before and have a code example?
    Really appreciate!
    Eric

    Hi Eric,
    Refer:
    [http://forums.sdn.sap.com/thread.jspa?threadID=2014259|http://forums.sdn.sap.com/thread.jspa?threadID=2014259]
    [http://forums.sdn.sap.com/thread.jspa?threadID=1909625|http://forums.sdn.sap.com/thread.jspa?threadID=1909625]
    Regards,
    Leon

Maybe you are looking for

  • IP Profile and lots of Errors

    Hi folks, a few weeks ago i phoned up about my speed and was told that my IP Profile was stuck, after the usual 10 days it was still stuck so i called again and they tried to reset again and i have waited again and it is still at 2MB, This was over t

  • How to change the CODEPAGE from 1100 to 4110 in icwebclient

    Hi , I have one issue with export to excel in ic webclient (CRM 5.0). 1. In ic webclient , there is a export to excel button.During export to excel, some special characters are not showing properly in the excel sheet. But in SAP GUI and IC WEB screen

  • Different Delivery dates for single material in sale order

    Dear All               I had a problem while creating a sale order, our customer orders a material for 100 SETS, but he needs 30 SETS On 30th July 2010 and remaining on 31st Aug 2010, how to mention the delivery dates in sale order, like for 30 SETS

  • Web Analysis through Iphone or Blackberry?

    Hi everyboby. I'd like to know how to access dashboards (Web Analysis or Financial Reporting) in Iphone or Blackberry. Do I need to download some app or plug-in or something like that? I was looking for documentation, but I did'n find. Thanksssss

  • I am having trouble installing new adobe flash player

    It will not load to install