FROM : Ryan Britton
DATE : Thu Jun 22 01:39:53 2006
On Jun 21, 2006, at 4:26 PM, Benjamin Einstein wrote:
>
> Does anyone outthere have experience with MCPKit (formerly known as
> SMySQL)? I'm running into quite a strange problem. Connecting to
> the database and running queries seems to work very well unless you
> want to use a string created at runtime. Here's where we get stuck:
>
> theResult = [theConnection queryString:(@"SELECT password FROM
> users WHERE username = '%@'", username)];
I'm not sure if the -queryString: method can take a format list, but
this is definitely not the to do it if it can. Try:
theResult = [theConnection queryString:[NSString
stringWithFormat:@"SELECT password FROM users WHERE username = '%@'",
username]];
DATE : Thu Jun 22 01:39:53 2006
On Jun 21, 2006, at 4:26 PM, Benjamin Einstein wrote:
>
> Does anyone outthere have experience with MCPKit (formerly known as
> SMySQL)? I'm running into quite a strange problem. Connecting to
> the database and running queries seems to work very well unless you
> want to use a string created at runtime. Here's where we get stuck:
>
> theResult = [theConnection queryString:(@"SELECT password FROM
> users WHERE username = '%@'", username)];
I'm not sure if the -queryString: method can take a format list, but
this is definitely not the to do it if it can. Try:
theResult = [theConnection queryString:[NSString
stringWithFormat:@"SELECT password FROM users WHERE username = '%@'",
username]];
| Related mails | Author | Date |
|---|---|---|
| beinstein | Jun 20, 00:41 | |
| Yorh | Jun 20, 01:24 | |
| colela | Jun 20, 01:38 | |
| James Bucanek | Jun 20, 02:24 | |
| Paul Lynch | Jun 20, 18:39 | |
| Keary Suska | Jun 20, 18:44 | |
| Benjamin Einstein | Jun 22, 01:26 | |
| Ryan Britton | Jun 22, 01:39 | |
| Benjamin Einstein | Jun 22, 01:45 | |
| Shaun Wexler | Jun 22, 02:15 | |
| Benjamin Einstein | Jul 2, 18:17 | |
| Bill Bumgarner | Jul 2, 19:03 | |
| Paul Collins | Jul 2, 20:25 | |
| Benjamin Einstein | Jul 2, 20:33 |






Cocoa mail archive

