[Mysql-cocoa-users] MCPQuery
Brought to you by:
sergecohen
|
From: Camille GOUREAU-S. <ca...@lu...> - 2004-08-13 21:37:42
|
Hi, I've created (part of) a classe I called MCPQuery. It provides me query (NSString*) when feeded with information. Has one of you already worked on such a thing ? Is it a non sense ? Is there a better way to avoid re-writing the sames lines of code ? Here are the functions I implemented : + (NSString*) selectQueryWithSelect: (NSDictionary*) fields andWhere: (NSString*) where ; // returns a "select from xhere" string with the fields extracted from fields and the from also + (NSString*) fromStringWithFields: (NSDictionary*) fields ; + (NSString*) queryEmptyInsertInTable: (NSString*) table ; + (NSString*) queryShowColumnsFromTable: (NSString*) table ; + (NSString*) queryUpdateFields: (NSDictionary*) fields inTable: (NSString*) table where: (NSString*) where ; + (NSString*) queryInsertFields: (NSDictionary*) fields inTable: (NSString*) table ; |