Mazen Abdel-Rahman <saba(dot)mazen(at)gmail(dot)com> writes:
> //get the name of the returned cursor
> char * cursorReturned;
> cursorReturned = PQgetvalue(queryResult4, 0, 0);
> NSString * fetchNextQuery = [NSString stringWithFormat:@"FETCH ALL in %s",
> cursorReturned];
I'd try double quoting that, ie
stringWithFormat:@"FETCH ALL in \"%s\"",
As-is you're risking trouble with mixed-case names, which is what you
seem to be using.
regards, tom lane