I read all data from Cursor, but in PageFragment goes only last value
Because inside while loop you are assigning new value to GlobalVars.ditty
in each iteration so either append new value to GlobalVars.ditty
with separator or use any data structure to store values like ArrayList,HashMap,... :
while (cursor.moveToNext()){
GlobalVars.ditty +=
cursor.getString(cursor.getColumnIndex(DB.COLUMN_DIT));
}