1,105,229 Community Members

HWPFDocument MySQL Word document read

Member Avatar
softDeveloper
Junior Poster in Training
76 posts since Nov 2011
Reputation Points: 0 [?]
Q&As Helped to Solve: 0 [?]
Skill Endorsements: 0 [?]
 
0
 

Hi All!

I'm trying to read ms word documents stored in my dataBase in a BLOB column.

However, concerning the encodings there are issues with characters. My web application can read the ms word documents the to an iframe with POIFSFileSystem without problems.

File docFile = null;
   	WordExtractor docExtractor = null ;
   	WordExtractor exprExtractor = null ;
   	try {
   	docFile = new File("c:\File.doc");
   	
   	FileInputStream fis=new FileInputStream(docFile.getAbsolutePath());

   	HWPFDocument doc=new HWPFDocument(fis);

   	docExtractor = new WordExtractor(doc);

However, I have to read it from a file in my system. My goal is to do the same, but reading the document directly from MySQL database.

Is it possible to create a FileInputStream directly from MySQL?

Regards,

Thanks in advance

You
This article has been dead for over three months: Start a new discussion instead
Post:
Start New Discussion
View similar articles that have also been tagged: