Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Java > Other Java > Java Databases
|
Java Databases Discussion specific to working with Java Databases. For other Java topics, please see related Java forums. For database discussions not specific to Java, please see the Database category.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Java Databases section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old April 11th, 2006, 02:19 AM
Authorized User
 
Join Date: Jan 2006
Posts: 21
Thanks: 0
Thanked 0 Times in 0 Posts
Default i want insert a word file in mysql

I want to insert a resume in mysql database which is in MsWord format.
I am not able to understand how to start the code.i am using jdbc servlets and all. please give me suggestion asap.

__________________
regards ,Vivek
 
Old May 18th, 2006, 12:25 PM
Authorized User
 
Join Date: Apr 2005
Posts: 71
Thanks: 0
Thanked 0 Times in 0 Posts
Default

May be you should have BLOB field in database and then pick up the data from file in binary format and push it across to the database.
 
Old May 25th, 2006, 06:42 AM
Registered User
 
Join Date: May 2006
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

int filesize = form.nsw_imageup.getFileSize();

        // Make a byte Array big enough to fit the file.
        byte[] byteArr = new byte[filesize];

        //Create an input stream to read the uploaded file.
        ByteArrayInputStream bytein = new ByteArrayInputStream(form.nsw_imageup.getFileData( ));

        // Load the input stream into the byte Array.
        bytein.read(byteArr);

        // Close the input stream.
        bytein.close();


by using this code it just convert to binary ..
but how to pass the value ,i am getting null pointer exception..

Jero Alex.S.A





Similar Threads
Thread Thread Starter Forum Replies Last Post
open word document and insert data PorcupineRabbit Visual Basic 2005 Basics 1 August 9th, 2007 06:31 PM
Insert Word file paul20091968 Word VBA 1 September 13th, 2006 07:48 AM
INSERT with MySQL sethtrain BOOK: Beginning PHP4/PHP 5 ISBN: 978-0-7645-4364-7; v5 ISBN: 978-0-7645-5783-5 4 August 1st, 2006 06:38 AM
insert word files thru code geetabajpai VB How-To 0 October 7th, 2005 04:22 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.