Out of memory error in vision client

Hellow all,
I face a memory out of limit error while fetching a huge amount of data from database. Though I changed the memory size in launcher tab available in project properties of designer,I get this error. Can anyone give a solution for this?

Message read as follows," Out of memory error,Java heap space "

Use a LIMIT 5000 or some other number on your query to limit your results. You may need an additional part of your WHERE clause to keep track of what ID you are on if records are constantly being added as you go through, or you can try using LIMIT X, N where N is the offset - think this is suitable if the script you are running on is not having new records added to it as you are running your script. Though I’ve only ever used the WHERE ID>x methodology full disclosure.