NullPointer while using Cursor

view full story

http://stackoverflow.com – I couldn't find a suitable title for my question. Here is the problem... After syso'ing the statement in getData(), it should print the values in the cursor, cMainTable, using the statement in displayDataForMainTable(). But, it doesn't. There are no exceptions, and errors. I have also kept the output that i get in the LogCat. Can someone help me with, why there is no output after the first print. try { pm = new PortfolioManager(this); cMainTable = pm.getData("mainTable"); if(cMainTable.equals(null)) { System.out.println("Null is returned"); (HowTos)