Question : Count rows - distinct

In this query I find distinct rows
SELECT DISTINCT StartTime,EndTime From Table1
WHERE TimeNum=@TimeNum
I would like to return the total number of rows from this query.  How do I to that?
(i.e. Count(Distinct StartTime,EndTime)..

Answer : Count rows - distinct

asuming that you're using NSURLRequest and NSURLConnection and friends, and you should simply stick to the delegation-paradigm and implement the appropreate delegate-methods, there's no need to bother with threading or (a)synchronous-issues.
connections are attached to the runloop, and will notify the delegate whenever something interesting happens. they are running on the main thread, but won't block.

About using POST instead of GET - there's not much to it.
Below a super simple setup, where is asumed that myDelegate, self.url, indata have already been assigned the appropreate values..
(not tested, cut/pasted as is..)
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:

NSMutableURLRequest * request = [NSMutableURLRequest
				requestWithURL:self.url
				cachePolicy:NSURLCacheStorageNotAllowed
				timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
[request setHTTPBody:indata];


NSURLConnection * connection = [NSURLConnection connectionWithRequest:request
							     delegate:mdelegate];
Random Solutions  
 
programming4us programming4us