Re:read  long raw  data in Oracle  and write to a file

So we need an mechanism to read data from LONG RAW and convert into actual file.
Regards

I've branched your post off from the thread you posted on ({thread:id=620757}) as it was an old thread.
When you have a question of your own, you should always start a new thread rather than tag onto old ones.
Please read: {message:id=9360002} and post some relevant information so that people can help you.

Similar Messages

  • How to read LONG RAW data from one  table and insert into another table

    Hello EVERYBODY
    I have a table called sound with the following attributes. in the music attribute i have stored some messages in the different language like hindi, english etc. i want to concatinate all hindi messages and store in the another table with only one attribute of type LONG RAW.and this attribute is attached with the sound item.
    when i click the play button of sound item the all the messages recorded in hindi will play one by one automatically. for that i'm doing the following.
    i have written the following when button pressed trigger which will concatinate all the messages of any selected language from the sound table, and store in another table called temp.
    and then sound will be played from the temp table.
    declare
         tmp sound.music%type;
         temp1 sound.music%type;
         item_id ITEM;
    cursor c1
    is select music
    from sound
    where lang=:LIST10;
    begin
         open c1;
         loop
              fetch c1 into tmp; //THIS LINE GENERATES THE ERROR
              temp1:=temp1||tmp;
              exit when c1%notfound;
         end loop;
    CLOSE C1;
    insert into temp values(temp1);
    item_id:=Find_Item('Music');
    go_item('music');
    play_sound(item_id);
    end;
    but when i'm clicking the button it generates the following error.
    WHEN-BUTTON-PRESSED TRIGGER RAISED UNHANDLED EXCEPTION ORA-06502.
    ORA-06502: PL/SQL: numeric or value error
    SQL> desc sound;
    Name Null? Type
    SL_NO NUMBER(2)
    MUSIC LONG RAW
    LANG CHAR(10)
    IF MY PROCESS TO SOLVE THE ABOVE PROBLEM IS OK THEN PLESE TELL ME THE SOLUTION FOR THE ERROR. OTHER WISE PLEASE SUGGEST ME,IF ANY OTHER WAY IS THERE TO SOLVE THE ABOVE PROBLEM.
    THANKS IN ADVANCE.
    D. Prasad

    You can achieve this in many different ways, one is
    1. Create another VO based on the EO which is based on the dest table.
    2. At save, copy the contents of the source VO into the dest VO (see copy routine in dev guide).
    3. commiting the transaction will push the data into the dest table on which the dest VO is based.
    I understand that if we attach VO object instance to region/page, we only can pull and put data in to only one table.
    if by table you mean a DB table, then no, you can have a VO based on multiple EOs which will do DMLs accordingly.Thanks
    Tapash

  • Sending Long Raw Data to Oracle database through Stored  Procedure

    Hi,
    I am trying to push data to Oracle 9i database through Stored Procedure via thin driver. It is going smoothly upto 29411 bytes. But it is not accepting for 53843 bytes and giving following error :
    java.sql.SQLException: Data size bigger than max size for this type: 53843
    Is it thin driver limitation? Can I solve it by using OCI driver? Or is there any other approach?
    I tried creating connection pool in weblogic 7.0 through OCI driver. But I am not able to configure it. Is there any special way of configuration.
    Quick response will be greatly appreciated.
    Thanks
    Sanjiv

    It happens to me. But I am using CMP of Weblogic 7. If you write your own jdbc code, the following link may be helpful.
    http://otn.oracle.com/sample_code/tech/java/codesnippet/xmldb/HowToLoadLargeXML.html

  • Import/Export of LONG RAW data to/from Oracle 7.3.3

    Is it possible to export the table with LONG RAW data from one instance and then import the dump file to another instance? Does Oracle 7.3.3 support these, if yes, how can I verify the LONG RAW data is successfully imported? If possible, please also provide me with some sample codes. Thanks a lot.

    NO you do not have to run catexp7, export files are UPWARD compatable. 10G import can read a 7 export (however 7 export could NOT understand a 10g export.)

  • Issue with Oracle LONG RAW data type

    Hi All,
    I am facing some issues with Oracle LONG RAW DATA Type.
    We are using Oracle 9IR2 Database.
    I got a table having LONG RAW column and I need to transfer the same into another table having LONG RAW column.
    When I tried using INSERT INTO SELECT * command (or) CREATE TABLE as select * , it is throwing ORA-00997: illegal use of LONG datatype.
    I have gone through some docs and found we should not use LONG RAW using these operations.
    So I did some basic PLSQL block given below and I was able to insert most of the records. But records where the LONG RAW file is like 7O kb, the inserting is faliling.
    I tried to convert LONG RAW to BLOB and again for the record where the LONG RAW is big in size I am getting (ORA-06502: PL/SQL: numeric or value error) error.
    Appreciate if anyone can help me out here.
    DECLARE
    Y LONG RAW;
    BEGIN
    FOR REC IN (SELECT * FROM TRU_INT.TERRITORY WHERE TERRITORYSEQ=488480 ORDER BY TERRITORYSEQ ) LOOP
    INSERT INTO TRU_CMP.TERRITORY
    BUSINESSUNITSEQ, COMPELEMENTLIFETIMEID, COMPONENTIMAGE, DESCRIPTION, ENDPERIOD, GENERATION, NAME, STARTPERIOD, TERRITORYSEQ
    VALUES
    REC.BUSINESSUNITSEQ, REC.COMPELEMENTLIFETIMEID, REC.COMPONENTIMAGE, REC.DESCRIPTION, REC.ENDPERIOD, REC.GENERATION, REC.NAME,
    REC.STARTPERIOD, REC.TERRITORYSEQ
    END LOOP;
    END;
    /

    Maddy wrote:
    Hi All,
    I am facing some issues with Oracle LONG RAW DATA Type.
    We are using Oracle 9IR2 Database.
    I got a table having LONG RAW column and I need to transfer the same into another table having LONG RAW column.
    When I tried using INSERT INTO SELECT * command (or) CREATE TABLE as select * , it is throwing ORA-00997: illegal use of LONG datatype.
    I have gone through some docs and found we should not use LONG RAW using these operations.
    So I did some basic PLSQL block given below and I was able to insert most of the records. But records where the LONG RAW file is like 7O kb, the inserting is faliling.
    I tried to convert LONG RAW to BLOB and again for the record where the LONG RAW is big in size I am getting (ORA-06502: PL/SQL: numeric or value error) error.
    Appreciate if anyone can help me out here.
    DECLARE
    Y LONG RAW;
    BEGIN
    FOR REC IN (SELECT * FROM TRU_INT.TERRITORY WHERE TERRITORYSEQ=488480 ORDER BY TERRITORYSEQ ) LOOP
    INSERT INTO TRU_CMP.TERRITORY
    BUSINESSUNITSEQ, COMPELEMENTLIFETIMEID, COMPONENTIMAGE, DESCRIPTION, ENDPERIOD, GENERATION, NAME, STARTPERIOD, TERRITORYSEQ
    VALUES
    REC.BUSINESSUNITSEQ, REC.COMPELEMENTLIFETIMEID, REC.COMPONENTIMAGE, REC.DESCRIPTION, REC.ENDPERIOD, REC.GENERATION, REC.NAME,
    REC.STARTPERIOD, REC.TERRITORYSEQ
    END LOOP;
    END;
    /below might work
    12:06:23 SQL> help copy
    COPY
    Copies data from a query to a table in the same or another
    database. COPY supports CHAR, DATE, LONG, NUMBER and VARCHAR2.
    COPY {FROM database | TO database | FROM database TO database}
                {APPEND|CREATE|INSERT|REPLACE} destination_table
                [(column, column, column, ...)] USING query
    where database has the following syntax:
         username[/password]@connect_identifier

  • [ORACLE 10G] Extract Long Raw data to disc

    Hi All,
    I want to extract a column which contain long raw data (pdf file) into files on my disque, but i don't know how to do it in SQL or PL/SQL, any help ???

    Or maybe just an alter table statement will do it for you...
    SQL> create table xx (x long raw);
    Table created.
    SQL> desc xx;
    Name                                                                   Null?    Type
    X                                                                               LONG RAW
    SQL> alter table xx modify (x blob);
    Table altered.
    SQL> desc xx;
    Name                                                                   Null?    Type
    X                                                                               BLOB
    SQL>I've not really used LONG RAW's before but apparently (according to sources on the net) the simlple alter table statement above will do the job.

  • Read data from Excel and write into oracle database

    Hi
    I want  to know how can i read data from excel and write into oracle database using java.Kindly help me out to find a solution.
    Thanks and Regards
    Neeta

    Hai,
    I am suggesting the solution.
    I will try out and let u know soon.
    Make a coma separated file from your excel file.
    Assuming that your requirement allows to make a csv file.
    This file may be passed as an file object to be read by java.Using JDBC you must be able to populate the data base.You can also use String Tokenizer if needed.
    You do not want to  go via sql Loader?
    For reading the excel file itself do you want java?

  • Read all raw data out of the CAN bus

    Hello,
    our company has purchased a complete CAN bus HW; chasis 9174 and module 9862. I am using NI-DAQmx 9.5.5, NI-XNET 1.5.
    I have connected the module (CAN High, CAN Low, Vsupp 12V - Car battery, GND - Car battery) to the ABS CAN bus segment.
    Using Osciloscope on CAN High and CAN Low wires I can see communication rolling when I start the car ignition.
    I had no success using the Bus Monitor utility.
    I made a very simple read VI hoping to monitor some traffic.
    All VIs run without error, but the Read VI is returning same data (Ignition off or on), I do not know what am I supposed to recieve, what kind of data is the output.
    I think it is wrong, since I get the same data out of it no matter what the CAN bus traffic is.
    The array of frames is filled with two frames with message identifiers that should be transmitted. I added two frames into emopty database and no signals.
    1) From my understanding, the Bus Monitor utility monitors only those messages that I specify in the database, so that no messages/frames = no traffic monitored, is this correct ?
    2) Is there any way, how to read all raw data from the bus ? What VI palettes to use... ?

    Problem solved, the company that was preparing the car made wrong labels (swapped CAN H with CAN L)

  • PS CS3, Camera Raw 4.6 Update and Nikon D810 NEF File Reading Issue

      Currently Have Photoshop CS3 & Adobe Bridge CS3 2.1.1.9.
    According to Adobe, Camera Raw 4.6 supports Nikon D810 NEF files.  I have downloaded Camera Raw 4.6 Update. When
    I try to open Nikon D810 NEF files, I get Photoshop CS3  error that says
    "cannot complete request your because it is not the right kind of
    document. These NEF files wont open in Adobe Bridge at all.  What am I doing wrong?

    Hey,
    Before I purchased, let me get your thoughts on another option that just occurred to me which involves:
    1)Editing my D810 NEF files in LR 5.6, which I have, then exporting/saving the edited files as JPEGs.
    2) Doing any additional editing, as necessary (i.e. that might require layering or selections..etc) , with the JPEGs  with Bridge or PS CS3. 
    This method wont involve any additional software purchase now.. right?    Am I missing anything.   here?    Since my final output to my customers are JPEGs any way, wont this work?   Will I be at any disadvantage.   Am I missing anything.   here? 
    From: ssprengel <[email protected]>
    To: charles cash <[email protected]>
    Sent: Monday, October 6, 2014 9:49 AM
    Subject:  PS CS3, Camera Raw 4.6 Update and Nikon D810 NEF File Reading Issue
    PS CS3, Camera Raw 4.6 Update and Nikon D810 NEF File Reading Issue  created by ssprengel in Adobe Camera Raw - View the full discussion  
    You can buy it from here:
    http://creative.adobe.com/plans
    Please note that the Adobe Forums do not accept email attachments. If you want to embed a screen image in your message please visit the thread in the forum to embed the image at https://forums.adobe.com/message/6795004#6795004
    Replies to this message go to everyone subscribed to this thread, not directly to the person who posted the message. To post a reply, either reply to this email or visit the message page: 
    To unsubscribe from this thread, please visit the message page at . In the Actions box on the right, click the Stop Email Notifications link. 
    Start a new discussion in Adobe Camera Raw by email or at Adobe Community
    For more information about maintaining your forum email notifications please go to http://forums.adobe.com/thread/416458?tstart=0.

  • Read image raw data without creating image

    Is there any way to read image raw data into an array from a file but not creating an image ? I looked through ImageIO. It seems that every time an image reader is called , a bufferediamge is created or reused ?
    Tanks fro any advice.

    Is there any way to read image raw data into an array from a file but not creating an image ? I looked through ImageIO. It seems that every time an image reader is called , a bufferediamge is created or reused ?
    Tanks fro any advice.

  • Select Long Raw data type is so slow?

    Hi
    I have a table having Long Raw data type field.It's store
    more than 2mb per record.But,I need to select others fields in this table without selecting Long Raw field.
    anyway,it's so slow for me. Any advise to me?
    thx a lot. :)

    I do not understand what you mean because if you have this table ( Example ):
    c1 number
    c2 number
    c3 long
    you can do this: select c1, c2 from <table_name>;
    Joel Pérez

  • How can I read the raw data by other program?

    How can I use other program (such as C, MATLAB) to read the raw data acquired by biobench (*.bb)? Since the export function of biobench 1.0 is not convinient, I hope that I can read the data directly by decompressing the *.bb file. In other words, can one tells me the format of *.bb file?

    Take a look at Top BioBench Support Solutions>>BioBench Support Files>>bbfileio.zip,here is the link: http://digital.ni.com/public.nsf/websearch/3ABE21AD33DA83B0862569B400810BAE?OpenDocument

  • Read and write a .CSV file contains cirillic characters issue

    Hi guys,
    I am a developer of a web application project which uses Oracle Fusion Middleware technologies. We use JDeveloper 11.1.1.4.0 as development IDE.
    I have a requirement to get a .csv file from WLS to application running machine. I used a downloadActinLinsener in front end .jspx in order to do that.
    I use OpenCSV library to read and write .csv files.
    Here is my code for read and write the .csv file,
    public void dwdFile(FacesContext facesContext, OutputStream out) {
    System.out.println("started");
    String [] nextLine;
    try {
    FileInputStream fstream1 = new FileInputStream("Downloads/filetoberead.CSV");
    DataInputStream in = new DataInputStream(fstream1);
    BufferedReader br = new BufferedReader(new InputStreamReader(in,"UTF-8"));
    CSVReader reader = new CSVReader(br,'\n');
    //CSVReader reader = new CSVReader(new FileReader("Downloads/ACTIVITY_LOG_22-JAN-13.csv"),'\n');
    List<String> list=new ArrayList();
    while ((nextLine = reader.readNext()) != null) {
    if(nextLine !=null){
    for(String s:nextLine){
    list.add(s);
    System.out.println("list size ; "+list.size());
    OutputStreamWriter w = new OutputStreamWriter(out, "UTF-8");
    CSVWriter writer = new CSVWriter(w, ',','\u0000');
    for(int i=0;i<list.size();i++){
    System.out.println("list items"+list.get(i));
    String[] entries = list.get(i).split(",");
    writer.writeNext(entries);
    //System.out.println("list items : "+list.get(i));
    writer.close();
    } catch (IOException e) {
    e.printStackTrace();
    say the filetoberead.CSV contains following data,
    0,22012013,E,E,ASG,,O-0000,O,0000,100
    1,111211,LI,0,TABO,B,M002500003593,,,К /БЭ60072715/,КАРТЕНБАЙ
    2,07,Balance Free,3
    1,383708,LI,0,BDSC,B,НЭ63041374,,,Т /НЭ63041374/,ОТГОНБААТАР
    2,07,Balance Free,161
    It reads and writes the numbers and english characters correct. All cirillic characters it prints "?" as follows,
    0,22012013,E,E,ASG,,O-0000,O,0000,100
    1,111211,LI,0,TABO,B,M002500003593,,,? /??60072715/,?????????
    2,07,Balance Free,3
    1,383708,LI,0,BDSC,B,??63041374,,,? /??63041374/,???????????
    2,07,Balance Free,161
    can somone please help me to resolve this problem?
    Regards !
    Sameera

    Are you sure that the input file (e.g. "Downloads/filetoberead.CSV") is in UTF-8 character set? You can also check it using some text editor having a view in hex mode. If each Cyrillic character in your input file occupies a single byte (instead of two), then the file is not in UTF-8. Most probably it is in Cyrillic for Windows (CP1251).
    If this is the case, you should modify the line
    BufferedReader br = new BufferedReader(new InputStreamReader(in,"UTF-8"));toBufferedReader br = new BufferedReader(new InputStreamReader(in,"windows-1251"));Dimitar

  • How to read from one file and write into another file?

    Hi,
    I am trying to read a File and write into another file.This is the code that i am using.But what happens is last line is only getting written..How to resolve this.the code is as follows,
    public String get() {
         FileReader fr;
         try {
              fr = new FileReader(f);
              String str;
              BufferedReader br = new BufferedReader(fr);
              try {
                   while((str= br.readLine())!=null){
                   generate=str;     
              } catch (IOException e1) {
                   e1.printStackTrace();
              } }catch (FileNotFoundException e) {
                   e.printStackTrace();
         return generate;
    where generate is a string declared globally.
    how to go about it?
    Thanks for your reply in advance

    If you want to copy files as fast as possible, without processing them (as the DOS "copy" or the Unix "cp" command), you can try the java.nio.channels package.
    import java.nio.*;
    import java.nio.channels.*;
    import java.io.*;
    import java.util.*;
    import java.text.*;
    class Kopy {
         * @param args [0] = source filename
         *        args [1] = destination filename
        public static void main(String[] args) throws Exception {
            if (args.length != 2) {
                System.err.println ("Syntax: java -cp . Kopy source destination");
                System.exit(1);
            File in = new File(args[0]);
            long fileLength = in.length();
            long t = System.currentTimeMillis();
            FileInputStream fis = new FileInputStream (in);
            FileOutputStream fos = new FileOutputStream (args[1]);
            FileChannel fci = fis.getChannel();
            FileChannel fco = fos.getChannel();
            fco.transferFrom(fci, 0, fileLength);
            fis.close();
            fos.close();
            t = System.currentTimeMillis() - t;
            NumberFormat nf = new DecimalFormat("#,##0.00");
            System.out.print (nf.format(fileLength/1024.0) + "kB copied");
            if (t > 0) {
                System.out.println (" in " + t + "ms: " + nf.format(fileLength / 1.024 / t) + " kB/s");
    }

  • How to read the and Write the PDF file give me the solution

    Hi all,
    How to read the and Write the PDF file give me the solution
    My coding is
    import java.io.File;
    import com.asprise.util.pdf.PDFImageWriter;
    import com.asprise.util.pdf.PDFReader;
    import java.io.*;
    import java.io.FileOutputStream;
    public class example {
    // public example() {
         public static void main(String a[])
              try
              PDFReader reader = new PDFReader(new File("C:\\AsprisePDF-DevGuide.pdf"));
                   reader.open(); // open the file.
                   int pages = reader.getNumberOfPages();
                   for(int i=0; i < pages; i++) {
                   String text = reader.extractTextFromPage(i);
                   System.out.println("Page " + i + ": " + text);
    // perform other operations on pages.
    PDFImageWriter writer = new PDFImageWriter(new FileOutputStream("c:\\new11.pdf"));
                   writer.open();
                   writer.addImage("C:\\sam.doc");
                   writer.close();
                   System.out.println("DONE.");
    reader.close();
              catch(Exception e){System.out.println("error:"+e);
              e.printStackTrace();
    I get the pdf content then it returns the string value but ther is no option to write the string to PDF, and we only add a image file to PDF,but i want to know how to wrote the string value to PDF file,
    Please give response immtly
    i am waiting for your reply.
    thanks,
    Suresh.G

    I have some question flow
    How library to use this code.
    I try runing but have not libary.
    Please send me it'library
    Thank you very much!

Maybe you are looking for

  • Checkbox in Tabular Form

    Hi, I am fairly new to APEX and need some help please. I am nrunning Apex 4.1 on 11g database. I have a tabular formrunning off the rowid which needs to show a checkbox for several columns which contain Y or N. When I set the field type to simple che

  • Iphone 3g won't connect to itunes/computer

    Recently I bought my friends Iphone which had 2.2 FW on it. When I took it home I couldn't get it to charge via my ipod cord or acknowledge that it was connected to the computer in anyway. The odd catch is that it will charge via the same cord plugge

  • GUI_DOWNLOAD in foreign language(Korean Language)

    Hi All, This is in regards with FM 'GUI_DOWNLOAD'. We are on 4.7 with logon language as English.We have created a ALV report which has ALV output and has column value in Korean language like customer name, address etc.The ALV shows correct Korean lan

  • GarageBand 3 loops missing

    I may have deleted some of GarageBand. I have version 3.0.4 (104.7) I can play all the instruments on the keyboard, so something is still there. My "loops" area shows up, but it's dull gray and I'm prompted that they're missing. Is there a download I

  • Sales Analysis query issue

    Experts, I have compiled a Sales Analysis Query for a client who need more information than the Sales Analysis in SBO can give them. I have found that if I only run the Months of July and August (choose these randomly) I get the correct amounts in th