My Database is hosting on mysql server & I'm using Java to analyze data.
My issue: after execute 'Select' query will return a 2.5 GB result set. I don't want to load all the data to memory. So is there any ways that I could continuously retrieve data & process it?
'limit by rows' will not be an option, b/c this 2.5 GB data is joined & retrieved from 4 tables. So 'limit by rows' will increase my total run-time a lot.
I've tried statement.setFetchSize(50), but it seemed not working as I expected.
Any suggestions will be really appreciated! Thanks!