hi
i tried to upload the file bt i cant
i want to upload file which size is greater than 200 Mb and also it should be csv file.
please guide me:((
Printable View
hi
i tried to upload the file bt i cant
i want to upload file which size is greater than 200 Mb and also it should be csv file.
please guide me:((
Why? Did you get exceptions? If so what are they? If not, we have no clue about your project and as a result can't provide much help withoutQuote:
i tried to upload the file bt i cant
it gives me exception like outofmemory:Java heap space
How are you uploading? Post code...without knowing the workings of the process....well, its called guessing.
If you're loading the whole file into the program you have to increase the heap past the default size. Try running your program in Terminal as so; java -Xmx500M nameOfClass.java
If it's a jar: java -Xmx500M -jar nameOfJar.jar
I agree...but presuming its a servlet (in the servlets section) that is throwing the exception,its a bit more complex than increasing the memory (again, the original poster needs to provide more information for us to know for sure). :) If your saving the file somewhere, try doing so through a stream rather than reading it into memory the saving the contents.Quote:
If you're loading the whole file into the program you have to increase the heap past the default size.