Hello everyone,
I have posted the same problem earlier and Wendy gave me a reply.But I think he didn't understand my problem well.Now I will explain it in detail.I have a file say abc.doc.I want to save the whole file to the database.and must view the file back, upon user's request.The CVI code I used is attached as a file:
********************************************************************************************
Now let us look how this CVI code works for two different SQL statements.From the code it is clear that my database table is test.
If I create the table as: 1) create table test (FILENAME VARCHAR2(25),WORDFILE LONGRAW); the above CVI code will work except that the file will be retrieved from database in binary format.Now comes the main problem with respect to this LONGRAW datatype.When I try to open the file to which I have saved the retrieved data,a dialogbox comes asking a system to choose for decoding eg: Arabic,Turkish,Western etc.But I want to view the retrieved data.i.e., the binary data that I have retrieved have to be converted to the word format.How could this be accomplished?.If I use a text file instead of a word file I can view the retrieved file but in binary format.Suppose that there is no database involved.i.e.,simply opening a file in binary mode,reading and writing to a file opened ion binarymode I can view the whole file.So this means that problem relies with the connection of CVI and Oarcle in relation with this datatype or word format.
2)create table test(FILENAME VARCHAR2(25),WORDFILE BLOB)-the above CVI code doesn't work.Error is that an Unspecified Error occured.When I checked the value of hstmt it is -10.It will be more useful for me if I use this BLOB datatype.How can I get rid of this problem?
Note:I used DBActivateSQl,DBPutColbinary and DBGetColBinaryBuffer functions as an alternative to the above used ones.Inthis case also I received the same errors.
Expecting help from all
Mala