tag:blogger.com,1999:blog-2132893136140848212.post3321154053156417304..comments2023-09-09T03:03:30.219-06:00Comments on Martin Giffy D'Souza on Oracle APEX: How to Send/Upload a CLOB from the Browser to APEX via AJAXMartin D'Souzahttp://www.blogger.com/profile/06992954599899886499noreply@blogger.comBlogger5125tag:blogger.com,1999:blog-2132893136140848212.post-34505102622806609542015-08-12T05:35:42.248-06:002015-08-12T05:35:42.248-06:00Not that I know of. I think I should write an upda...Not that I know of. I think I should write an update post using the new apex JS APIs.Martin D'Souzahttps://www.blogger.com/profile/06992954599899886499noreply@blogger.comtag:blogger.com,1999:blog-2132893136140848212.post-62302131903857913652015-08-11T09:27:11.086-06:002015-08-11T09:27:11.086-06:00Hello Martin,
I have been able to get this work in...Hello Martin,<br />I have been able to get this work in chrome.But in Firefox it does not work .The clob_content collection never gets populated when using Firefox.Have you also faced this?<br /><br />Thanks<br />Ceejay<br />Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-2132893136140848212.post-49217125223520233822013-07-04T19:00:24.130-06:002013-07-04T19:00:24.130-06:00Hi Stefan,
In JavaScript (i.e. from the browser) ...Hi Stefan,<br /><br />In JavaScript (i.e. from the browser) you can use something like this:<br /><br />var clobObj = new apex.ajax.clob(<br /> //Callback funciton. only process CLOB once it's finished uploading to APEX<br /> function(p){<br /> if (p.readyState == 4){<br /> //Upload Done<br /> <br /> //Call some Application Process once the upload is done<br /> var get = new htmldb_Get(null,$v('pFlowId'),'APPLICATION_PROCESS=UPLOAD_CANVAS',$v('pFlowStepId'))<br /> <br /> //Optional: pass some additional values get.addParam('x01','some data');<br /> get.addParam('x01',mimeType);<br /> get.addParam('x02',fileExtension);<br /> gReturn = get.get();<br /> }<br /> }<br />);<br /><br />//img64 is the base64 of the file/image (you'll need to set this yourself)<br />clobObj._set(img64); //Sends the data to Oracle/APEX collection <br /><br /><br />In PL/SQL you can convert a CLOB (base64) to a BLOB from the Application Process using apex_web_service.clobbase642blob http://docs.oracle.com/cd/E37097_01/doc/doc.42/e35127/apex_web_service.htm#BABHIEJB<br />Martin D'Souzahttps://www.blogger.com/profile/06992954599899886499noreply@blogger.comtag:blogger.com,1999:blog-2132893136140848212.post-34020071941879544192013-06-22T00:56:52.551-06:002013-06-22T00:56:52.551-06:00Hi Martin
Is there a similar option for BLOBs (su...Hi Martin<br /><br />Is there a similar option for BLOBs (such as sending images from the browser to APEX) - using DA ?<br /><br />StefanUnknownhttps://www.blogger.com/profile/05202880078855273570noreply@blogger.comtag:blogger.com,1999:blog-2132893136140848212.post-39658292769060418702013-04-22T13:17:27.772-06:002013-04-22T13:17:27.772-06:00Thank You for this concise explanation. Using thi...Thank You for this concise explanation. Using this example, I was able to put together the CLOB upload that I needed in no time.Anonymousnoreply@blogger.com