I would think that first you need to verify that you are getting the pdf's created 
properly - so save them as files first. Then make sure that you are saving the correct 
stream to the database. I would doubt that SQL Server would selectively take out the 
answers for you.

Chris

-----Original Message-----
From: Miller, Eric [mailto:[EMAIL PROTECTED]]
Sent: Friday, June 14, 2002 10:27 AM
To: [EMAIL PROTECTED]
Subject: [iText-questions] sql 2000 db weirdness


I created some PDF documents from a form that is filled out online.  I then
placed the pdf in a sql 2000 database, storing it using the
PreparedStatement.setBinaryStream() method.  When I pull it out of the
database, for lack of better knowledge, I create the file again with the
following code:

OutputStream restoredfile = new FileOutputStream("file path");
int i;
while(true)
{  
        i = istream.read();  
        if(i == -1)  
        {    break;  }  
        restoredfile.write(i);
}
}catch(Exception e)
{ out.print(e.toString()); }

istream is an inputstream that contains the result of a
ResultSet.getBinaryStream() method that pulled my binary stream out of the
database.  This file, once again, was filled out online, and it is just a
list of questions and answers.  The answers in the pdf file are values taken
from text areas online.  When I pull the binary stream out of the database
and restore it to the filesystem, the questions and headings are there, but
the answers to the questions are now gone!  Anyone else run into anything
like this?  Perhaps I am missing something simple.
Thanks in advance

_______________________________________________________________

Don't miss the 2002 Sprint PCS Application Developer's Conference
August 25-28 in Las Vegas - 
http://devcon.sprintpcs.com/adp/index.cfm?source=osdntextlink

_______________________________________________
iText-questions mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/itext-questions

_______________________________________________________________

Don't miss the 2002 Sprint PCS Application Developer's Conference
August 25-28 in Las Vegas - 
http://devcon.sprintpcs.com/adp/index.cfm?source=osdntextlink

_______________________________________________
iText-questions mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/itext-questions

Reply via email to