On Mon, Mar 26, 2012 at 7:56 PM, Александр Решетников <saniek1@yandex.ru> wrote:
> Thanks for the quick reply.
>
> I also found a feature (a bug I do not know it or not).
> if before Redis commands use IF condition and operation Set, all subsequent commands Redis are not met, give this error: " * 3 no redis2 query specified or the query is empty. "
> Here's an example:
> set $ t 1;
> if ($ t = 1) {set $ t 2;}
>
> redis2_query set hello world;
> redis2_pass 127.0.0.1:6379;
Well, this is not a bug. You misused the location-level if statement
here. Please read the following blog post in which I explained how
"location if" works:
http://agentzh.blogspot.jp/2011/03/how-nginx-location-if-works.html
Best,
-agentzh