This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Servlets and the fly likes servlet not displaying all the pages in PDF Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "servlet not displaying all the pages in PDF" Watch "servlet not displaying all the pages in PDF" New topic
Author

servlet not displaying all the pages in PDF

prav ba
Greenhorn

Joined: Jun 17, 2007
Posts: 12
hi all,
have a very interesting problem. i have a servlet which is meant to download a PDF doco stored in an oracle database as a BLOB and display it in the users browser. The PDF is 900 pages long but in the browser it only displays 200 pages. Have tried it IE v 7 and FireFox v 3.6.8 what could be causing this ??

servlet code sniplet :




thanks in advance.
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18541
    
    8

Have you confirmed that "cacheImpl.getPDF(ID)" actually returns the entire PDF document? 900 pages of PDF sounds like a lot of bytes to me, if I were writing the code I wouldn't load the entire document into memory. I would stream it from... wherever it's coming from... to the servlet's output stream. You may be running out of memory.
 
 
subject: servlet not displaying all the pages in PDF
 
Similar Threads
streaming PDF document to the browser
storing BLOB type in oracle db
reading BLOB type
ORA-01460: unimplemented or unreasonable conversion requested
renaming pdf file via servlet