I want to uplaod a file(csv or excel) to Oracle 10g database, using Jsp or Servlets....
This is my code...Its not uploading the file, it is giving me Error--> Index 1, size 1. Please help me ..how to do this. I am trying to upload a csv file to oracle db from jsp page, csv file has two fields PartNo and SerialNo. The Oracle table InventoryDB_main has 23 columns including PartNo, SerialNo. Please can anyone help me how to upload a file to oracle database.
You don't know what line of code threw that exception, do you? In your catch block you should print the whole stack trace, like this:
Only since the code is in a JSP, the line numbers in the stack trace which you get won't match the line numbers in the JSP, because the JSP is compiled into something else where the line numbers are different. So as Bear said... put the code into a servlet.
Do not use the code of that link. It irresponsibly puts code in a JSP just like we have been advising not to. The roseindia site should be avoided as its examples rarely exhibit proper practices and good coding.
subject: How to Upload a file to oracle database using JSP or Servlets