Hey,
I have created a Class (subclass of NSObject) which will hold all my SQLs/dbConnections etc..
in a seperate viewcontroller, i have instantiated the SQL's class and performed some actions, all went trough OK.
but. one of my methods in the SQL's class is a method defined as follows:
-(NSString *)queryTable:(NSUInteger *)fieldnum
//query from db, and assign the field value into "fieldName"
dbEntity = fieldName;
[fieldName release];
}
sqlite3_finalize(statement);
}
return dbEntity;
}
dbEntity is defined as NSString, and i have set it as a nonatoimc-retain property
@property (nonatomic,retain) NSString *dbEntity;
when ever i call this method out from my viewController and debug step by step, i see that the method is running, it is quering from the db as expected, but when it passes the value into dbEntity the values in dbEntity are suddenly "out of scope" that is... if i browse this specific action:
dbEntity = fieldName;
i can see values inside fieldName, but see "out of scope" in dbEntity.
Why is that?!?
what is wrong with dbEntity definitions?
Any help will be appriciated.