I put my sql file to Resource folder.
And I checked there is few data through the terminal.
But sqlite3_step never give SQLITE_ROW.
Now I don't know what I have to do.
help me, plz.
here is my code
And I checked there is few data through the terminal.
But sqlite3_step never give SQLITE_ROW.
Now I don't know what I have to do.
help me, plz.
here is my code
Code:
if(sqlite3_open([databasePath UTF8String], &database) == SQLITE_OK) {
#pragma mark [[money part]]
const char *moneySqlStatement = "SELECT * FROM money";
sqlite3_stmt *compiledStatement;
if(sqlite3_prepare_v2(database, moneySqlStatement, -1, &compiledStatement, NULL) == SQLITE_OK) {
while( sqlite3_step(compiledStatement) == SQLITE_ROW) {
NSString *mTitle = [NSString stringWithUTF8String:(char *)sqlite3_column_text(compiledStatement, 1)];
~~~~~