app/src/main/java/com/client/models/ChatMsgDao.java
public static void createTable(SQLiteDatabase db, boolean ifNotExists) {
        String constraint = ifNotExists? "IF NOT EXISTS ": "";
        db.execSQL("CREATE TABLE " + constraint + "\"CHAT_MSG\" (" + //
                "\"FROMUSER\" TEXT NOT NULL ," + // 0: Fromuser
                "\"TOUSER\" TEXT NOT NULL ," + // 1: Touser
                "\"MSGDATE\" INTEGER NOT NULL ," + // 2: Msgdate
                "\"MSGTYPE\" INTEGER NOT NULL ," + // 3: Msgtype
                "\"MSGBODY\" BLOB NOT NULL );"); // 4: Msgbody
    }
/** Creates the underlying database table. */
Creates the underlying database table.
Creates the underlying database table .
public static void createTable(SQLiteDatabase db, boolean ifNotExists) {
        String constraint = ifNotExists? "IF NOT EXISTS ": "";
        db.execSQL("CREATE TABLE " + constraint + "\"CHAT_MSG\" (" + 
                "\"FROMUSER\" TEXT NOT NULL ," +  0: Fromuser
                "\"TOUSER\" TEXT NOT NULL ," +  1: Touser
                "\"MSGDATE\" INTEGER NOT NULL ," +  2: Msgdate
                "\"MSGTYPE\" INTEGER NOT NULL ," +  3: Msgtype
                "\"MSGBODY\" BLOB NOT NULL );");  4: Msgbody
    }
public static void createTable ( SQLiteDatabase db , boolean ifNotExists ) { String constraint = ifNotExists ? "IF NOT EXISTS " : "" ; db . execSQL ( "CREATE TABLE " + constraint + "\"CHAT_MSG\" (" + "\"FROMUSER\" TEXT NOT NULL ," + "\"TOUSER\" TEXT NOT NULL ," + "\"MSGDATE\" INTEGER NOT NULL ," + "\"MSGTYPE\" INTEGER NOT NULL ," + "\"MSGBODY\" BLOB NOT NULL );" ) ; }
Creates the underlying database table.
Creates the underlying database table .
// // 0: Fromuser // 1: Touser // 2: Msgdate // 3: Msgtype // 4: Msgbody