[ JHeadstart ] Download DB2 BLOB with OrdDocDomain

Hello,
I have managed to import a pdf into a DB2 BLOB. In the entity (and view) i have java.sql.blob attribute to the DB2 BLOB column. Furthermore I have a OrdDocDomain attribute reading the blob in the entity for the JHeadstart integration (using the filedownload option).
Application works fine, but i want to control the filename displayed when downloading the file. Also I want to inform the browser with the MIME type. I have used several properties on the OrdDocDomain but they don't seem to be of any effect on the download dialog.
How can i control the MimeType en Filename when downloading the blob using the JHeadstart application definition/ADF?
JHeadstart version: 10.1.3.0.97
Kind Regards,
Endy

Endy,
This is documented in the Developers Guide, chapter 3, section "Showing Properties Of Uploaded Files"
Steven Davelaar,
JHeadstart Team.

Similar Messages

  • Downloading into blobs with name of source files

    Hi
    I have a little question. Is there any chance to conserve a name of the file, which was uploaded into blob column via portal form and then create link for this file with the same name?

    Vlasta,
    This question should go to the Portal Applications Forum (I assume you're using a custom form, and not uploading files to content areas).
    Thanks,
    Jerry
    null

  • Issue with file download from BLOB type data

    i have been using this for a while, with no problems, including on hosted machines.
    the upload to the database works fine.. not the issue, and the download script also works fine, on the local WAMP machine.
    but once moved to the server it fails.. the query does not work.
    i have a feeling that it is something to do with the managed hosting i am using, but they say no, i have tried it on 2 seperate hosted machines (different providers), with no joy.
    if i run the select query on the hoisting server via phpmyadmin, the query runs ok.
    any suggestions as to what may be causing the problem on the server compared to the local WAMP machine?
    i really don't know where to start looking, or where to point the hosting company.
    This is the php code to download the blob data, works fine on local WAMP setup, browser asks if you want to save the file/open etc. as expected.
    <?php require_once('Connections/connTracker.php'); ?>
    <?php
    // if id is set then get the file with the id from database
    if(isset($_GET['docindex']))
               {$id    = $_GET['docindex'];
            $query = "SELECT document_name, document_type, document_size, document_content " .
               "FROM tracker_documents WHERE document_index = ".$id;
    *** seems to be failing here when running the query ***
    $result = mysql_query($query) or die('Error, query failed');
               list($name, $type, $size, $content) = mysql_fetch_array($result);
         header("Cache-Control: maxage=1"); //In seconds
       header("Pragma: public");
         header("Content-length: $size");
               header("Content-type: $type");
               header("Content-Disposition: attachment; filename=$name");
               echo html_entity_decode ($content);}
    exit;
    ?>

    Hi Gun,
    You are the only one responded to my issue. I have allocated some points.
    Yes. I have checked the assignment in CRM organizational model.
    I did download the org. structure from ECC 5.0
    All objects including sales offices are activated for determination and I have verified with green light
    As per your suggestion if the sales area data is not matched between the two systems, then how come the error will not reappear during the bdoc reprocess?
    What is missing during the first time bdoc process? Looks something is missing for validation module?
    Any inputs?
    Thanks,
    Raj

  • How to upload and download in BLOB?

    I tried webutil but is not working properly according to my needs is there any other way to upload and download files in BLOB?
    If any body knows solution please tell me.
    Regards,

    Dear Colleague,
    In my Forms application, I use the WEBUTIL to load files into a BLOB column. However, prior to getting WEBUTIL to work, I loaded files into the BLOB column using the following PL/SQL code.
    Note, that the example assumes that the row already exists in the table and you are updating it by loading the file into the BLOB. You will also be required to first create a Database Directory object (in my case, it was called "RKMS_DOC_DIR")
    I do not have an example for downloading, as I use the WEBUTIL functionality for this.
    Good luck!
    Randy
    PL/SQL (DBMS_LOB Package): Loading an Internal Persistent BLOB
    with BFILE Data
    The following example illustrates:
    How to use LOADBLOBFROMFILE to load the entire file without getting its length first.
    How to use the return value of the offsets to calculate the actual amount loaded.
    DECLARE
    src_loc BFILE := bfilename('RKMS_DOC_DIR','ROPE_Offerte_v2.pdf') ;
    v_author VARCHAR2(10) := 'RKMS_MGR' ;
    dst_loc BLOB;
    src_offset NUMBER := 1;
    dst_offset NUMBER := 1;
    src_osin NUMBER;
    dst_osin NUMBER;
    bytes_rd NUMBER;
    bytes_wt NUMBER;
    BEGIN
    -- SELECT ad_composite INTO dst_loc FROM Print_media
    -- WHERE product_id=3106 and ad_id=13001 FOR UPDATE;
    SELECT doc INTO dst_loc FROM docs
    WHERE USER_AUTHOR_ID = v_author FOR UPDATE;
    /* Opening the source BFILE is mandatory */
    dbms_lob.fileopen(src_loc, dbms_lob.file_readonly);
    /* Opening the LOB is optional */
    dbms_lob.OPEN(dst_loc, dbms_lob.lob_readwrite);
    /* Save the input source/destination offsets */
    src_osin := src_offset;
    dst_osin := dst_offset;
    /* Use LOBMAXSIZE to indicate loading the entire BFILE */
    dbms_lob.LOADBLOBFROMFILE(dst_loc, src_loc, dbms_lob.lobmaxsize, src_offset, dst_offset) ;
    /* Closing the LOB is mandatory if you have opened it */
    dbms_lob.close(dst_loc);
    dbms_lob.filecloseall();
    COMMIT;
    /* Use the src_offset returned to calculate the actual amount read from the BFILE */
    bytes_rd := src_offset - src_osin;
    dbms_output.put_line(' Number of bytes read from the BFILE ' || bytes_rd ) ;
    /* Use the dst_offset returned to calculate the actual amount written to the BLOB */
    bytes_wt := dst_offset - dst_osin;
    dbms_output.put_line(' Number of bytes written to the BLOB ' || bytes_wt ) ;
    /* If there is no exception the number of bytes read should equal to the number of bytes written */
    END ;
    /

  • Master Detail stops working when i try to download a blob filed

    Hi All,
    I am working on Jdeveloper 11g.
    I have a master table with detail , the detail table has a blob field.
    when the user tries to download the blob field every thing works fine, but the master detail relation stops working , when the user clicks a row in the master table the detail is not refreshed.
    I have to refresh the whole page to start working again .
    This is the code I am using for download , along with fileDownLoadActionListener():
    public void researchDownloadAction(FacesContext ctx, OutputStream out) {
    ExternalContext ectx = ctx.getExternalContext();
    Row currentRow = ADFUtils.getIterator("Documents2Iterator").getCurrentRow();
    String fileName = (String)currentRow.getAttribute("FileName");
    BlobDomain content = (BlobDomain)currentRow.getAttribute("Content");
    Long length = content.getLength();
    HttpServletResponse response = (HttpServletResponse)ectx.getResponse();
    response.setHeader("Content-Disposition", "attachment;filename=\"" + fileName + "\"");
    response.setContentLength(length.intValue());
    try {
    InputStream in = content.getBinaryStream();
    byte[] buf = new byte[1024];
    int count;
    while ((count = in.read(buf)) >= 0) {
    out.write(buf, 0, count);
    in.close();
    out.flush();
    out.close();
    ctx.responseComplete();
    catch (IOException ex) {
    System.out.println(ex.getMessage());
    ex.printStackTrace();
    Thanks.

    Let's try the following user tip with that one:
    iTunes for Windows 10.7.0.21: "iTunes has stopped working" error messages when playing videos, video podcasts, movies and TV shows

  • How can i transform a file stream into a stream of a block blob to download block blobs?

    I want to change this code to work with block blobs, but I can't seem to figure it out on my own
    // initialize the http content-disposition header to
    // indicate a file attachment with the default filename
    System.String disHeader = "Attachment; Filename=\"" + "sample.txt" +
    Response.AppendHeader("Content-Disposition", disHeader);
    // Download the blob to a file stream.
    using (FileStream fs = new FileStream(this.Server.MapPath(@"Data\data.txt"), FileMode.Open))
    int chunkSize = 4096;
    byte[] buffer = new byte[chunkSize];
    int read = 0;
    Response.AddHeader("Content-Length", fs.Length.ToString());
    do
    read = fs.Read(buffer, 0, chunkSize);
    Response.OutputStream.Write(buffer, 0, read);
    } while (read > 0);
    fs.Close();
    fs.Dispose();
    Response.End();

    Hi,
    What detailed scenario do you want to achieve? If you want to download files from block blob stream, please have a look at below article.
    #http://azure.microsoft.com/en-us/documentation/articles/storage-dotnet-how-to-use-blobs/
    If I misunderstand, please feel free to let me know.
    Best Regards,
    Jambor
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • I received an ipod touch 5th gen for Christmas.  The first songs i've downloaded and synced with my touch have created ghost songs.  They are only on my computer in itunes once but appear on my ipod twice, one copy that won't play.  I can't delete them

    The first songs i've downloaded and synced with my new touch have created ghost songs.  They are only on my computer in itunes once but appear on my ipod twice, one copy that won't play.  I can't delete them.  I've tried unticking all the music that was on the ipod via itunes and re-syncing, which in theory should delete all music from my ipod.  It does except for the 5 ghost songs.   So at present I have no music on ipod except the 5 ghost songs.   Has anyone got any ideas how I can get rid of these?  
    I had no problems with my ipod touch 4th, which I had for years.   Any help would be great.  

    iOS: Device not recognized in iTunes for Mac OS X
    Or
    See
    iOS: Device not recognized in iTunes for Windows
    - I would start with
    Removing and Reinstalling iTunes, QuickTime, and other software components for Windows XP
    or                     
    Removing and reinstalling iTunes and other software components for Windows Vista, Windows 7, or Windows 8
    However, after your remove the Apple software components also remove the iCloud Control Panel via Windows Programs and Features app in the Window Control Panel. Then reinstall all the Apple software components
    - Then do the other actions of:
    iOS: Device not recognized in iTunes for Windows
    paying special attention to item #5
    - New cable and different USB port
    - Run this and see if the results help with determine the cause
    iTunes for Windows: Device Sync Tests
    Also see:
    iPod not recognised by windows iTunes
    Troubleshooting issues with iTunes for Windows updates
    - Try on another computer to help determine if computer or iPod problem

  • When i open itunes it gives me the option to download the new version 10.3. my computer will not support 10.3. i can't by pass the download to continue with my current version of itunes. i've trashed and reinstalled 8.2.1 twice. any solutions?

    When i open itunes it gives me the option to download the new version 10.3. my computer will not support 10.3. i can't by pass the download to continue with my current version of itunes. i've trashed and reinstalled 8.2.1 twice. any solutions?

    I am in the same boat. I tried repeatedly to contact iTunes support, but was told each time that I had contacted the wrong deaprtment and they could not help me. There must be a way to still be able to use the iTunes store without paying for a system update. If not, I hope they will reimburse me the money I have in my acount.

  • TS2446 If i create a new apple id account on my ipod, will i still have all my music, apps, books and other stuff on my ipod that i downloaded and bought with my old account or will i loose everything; will i be able to still do the updates to those apps?

    If I create a new apple id account on my ipod, will I still have all my music, apps, books and other stuff on my ipod that I downloaded and bought with my old account or will I loose everything; will I be able to still do the updates to those apps?
    I really need help!

    I don't think you understood what I wrote. You don't HAVE to pay for everything if you are happy with using the other account for updates, etc. But if you don't want to do that then you will have to buy new copies of everything for the new account. There's only one purchase item per account, but you can redownload an item in the account many times.
    The idea is this:
    One computer, multiple devices, one Apple ID.
    One user, multiple devices, one Apple ID.
    The basic idea is that each user has an Apple ID under which he/she can manage multiple devices on a single computer.
    Once you step outside of that model you create such problems as not being able to use or update apps purchase under one Apple ID when using a different Apple ID. Or not being able to easily sync one device on more than one computer.

  • I downloaded apps purchased with another Apple ID. But my data is missing. What can I do to get them back? I have a different iCloud id.

    I downloaded apps purchased with another Apple ID. But my data is missing. What can I do to get them back? I have a different iCloud id.

    All apps are tied forever to the Apple ID used to obtain them, that is also true with In-App purchases.
    Content bought using one Apple ID cannot be merged or transferred to another Apple ID.

  • My Apple id was disabled and had to make a new one for iTunes but it's not letting me erase then re download the app with the new Apple ID

    My Apple id was disabled and had to make a new one for iTunes but it's not letting me erase then re download the app with the new Apple ID   Just got an iPad air 2 so my iCloud and family sharing is with the one that's disabled. Which I don't know how to switch to my new one, so I trying to erase my apps that won't load and just re download them with my new ID that is being used with the iTunes n app store but I can't even find most in purchased plus it's saying that I can't get it cuz that ID is not with family sharing but I donT know why it would not be. Please someone help.

    OOk so I have my new Apple id in my iTunes account but my old Apple ID is the one that is in the iCloud account which is the Apple ID have been using for years and the reason I cannot get it on this abled is because somebody was using my credit card or debit card that was on file for family sharing and it was a stolen iPhone from my account so they had to disable my Apple ID and I could not use my debit card anymore on any Apple ID ever again they said because of it so I can't get it not to be disabled and I can't sign into iTunes with it I already have signed out and signed in with my new Apple ID for iTunes it's just iCloud is not letting me load anything so pretty much what I've been doing is I have to erase every app and then re-dumb going to iTunes and re-download the apps again but the only issue is that I still have a disabled Apple ID as my iCloud settings and my iCloud family sharing in all of that so I'm wondering how or is it possible to change my Apple ID for iCloud specifically because when I go into Icloud and settings and go into my name where my Apple ID is the one that's disabled it doesn't say anything about log out or sign out or anything like that it just says to put the password for it so is there a way to change the Apple ID for my iCloud so that my iTunes in my iCloud is the same Apple ID?

  • I recently download a song with my IPOD Touch 4G.  The song appears in my iTunes music library but not on my IPOD.  I've tried syncing several times, but I cannot get it to transfer to the IPOD.  Any suggestions??

    I recently download a song with my IPOD Touch 4G.  The song appears in my iTunes music library but not on my IPOD.  I've tried syncing several times, but I cannot get it to transfer to the IPOD.  Any suggestions??  (This has never happened before to me)

    Use 3rd party software like:
    http://www.digidna.net/products/diskaid
    http://www.wideanglesoftware.com/touchcopy/index.php
    For items purchased (including apps) from iTunes:
    http://support.apple.com/kb/HT1848

  • I can't download the apps with big size like need for spees, but in apps with normal size(less than 100KB)there is no problem,is there any body who can help me?

    I can't download the apps with big size like need for spees

    Have a little patience. 4 minutes is only a short time for someone to find your post and reply to it. Also clicking on "This Solved My Problem" marks your problem as solved so many folks that may otherwise help will pass the question by since it is "solved."
    I suggest you start a new question that gives a good title to a specific problem. Then in the body of the thread describe the problem in detail, tell us what steps you have tried so far to correct the problem, what happened, and what error messages you received.

  • Macpro dual core xeon.  Why can I not download Lion even with snow leopard 10.6.8 already as sysyem?

    macpro dual core xeon January 2008  Why can I not download Lion even with snow leopard 10.6.8 already as sysyem?

    If you need to purchase Lion call 1-800-692-7753 or 1-800-676-2775. Ask for a Sales Representative. They will check your Apple ID, and email you a code and instructions.  The cost is $29.99 (as it was before) plus tax.  It's a download.

  • I have found that my Mac Book Pro 15 inch late 2011 is slower than my PC Windows 7 for certain downloads, and working with iPhoto.  Would adding RAM be helpful in speeding up this process.  Currently I have the stock 4GB RAM, and storage 500GB HD drive.

    I have found that my Mac Book Pro late 2011 15 inch is slower than I expected with certain downloads, or working with iPhoto than expected compared to my previous Windows 7 PC.  Would adding RAM be of any value in speeding up the process?

    how to tell if your mac needs more ram

Maybe you are looking for

  • Media Encoder CC hangs when working with 96/24 audio

    Title says it all! Has anyone else had this problem with Media Encoder CC? I just upgraded from CS5.5 to CC, and there were no issues with encoding 96/24 audio with CS5.5. I can reduce the audio files to 48/16 and theres no issue, but all the asset f

  • Security roles and profiles

    Hello, Could you please provide information on "security roles and profiles " I would appreciate. Regards, Alex

  • Creating a load bar....

    When creating the load bar or load screen...Should I create it after I set up my webpage or can I set it up first....and if i can set it up first how will I see the load in load bar in action????

  • Sysaux tablespace offline ?

    Hi, Can we able to make a sysaux tablespace offline? What happen if it was offline.?

  • Menu bar disabled for a PowerPivot workbook after publishing on SharePoint 2013

    Hi, I've implemented a simple PowerPivot workbook on a SharePoint 2013 site but when I select it inside Internet Explorer 11 the menu bar seems disabled (f.e., I cannot select the data refresh for the Data tab). I can use the slicers and the filters