this

MySQL returned error




Error Description :
Error No : 1064
Description : You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ' is_available DESC,(total_rating/no_of_ratings) DESC,title ASC,publisher ASC,act' at line 1

SQL Query
SELECT COUNT(`book`.id) AS CNT FROM `book` WHERE id!=0 AND book.id<>0 and book.active='yes' and city_id!='' and book.id in(0,6866,6542,2520,5371,2261,6869,1769,6840,6869,6628,6754,857,1516,1245,1616,2696,6804,4426,7092,7082,7095,7121,7097,4490,958,7085,7093,6813,1165,6118,4437,6122,5421,4218,5770,5371,5576,1462,2342,1343,4570,3863,2455,1461,5576,2269,7307,6981,2869,6809,1351,4535,6809,834,501,5657,3850,6709,2269,1764,7359,4446,934,7546,1038,6599,698,4566,452,3492,6845,6721,156,1271,6723,446,5419,7604,924,5647,1973,4178,2932,1200,4362,5148,766,2932,4860,2006,7160,7631,1993,3830,1439,4901,713,5995,1453,4796,6367,6103,5837,754,2029,5269,7840,6168,5376,6981,7592,6740,7554,7833,6155,7754,1345,7751,7756,6131,5484,3169,435,3134,1718,734,228,1207,3645,6986,1600,1593,744,2331,645,6731,1000,223,1318,4855,4199,2571,5735,1460,6643,2671,7029,7047,4164,6902,4165,341,6998,1577,2469,2685,6827,3584,4219,5770,1250,4774,7265,545,548,549,550,540,547,528,538,7290,529,7840,4639,947,7938,223,4801,6396,1084,1086,1085,1604,5495,714,5495,2729,1609,987,7132,5185,6533,990,4346,7636,6589,7636,6750,2018,7580,4563,7972,7973,6201,3380,6098,8098,8093,7273,8302,7639,2006,6843,6445,3521,7105,8199,8047,7895,8413,8514,9055,9132,3647,9206,8475,3169,9195,4796,8224,9900,9935,9879,9630,9945,2736,10547,10026,1993,10765,7976,10881,8053,7152,9134,9204,11798,11609,10466,11410,3479,5996,6940,5657,7812,7943,8109,8223,6971,7160,7548,6726,8296,8230,8049,8526,8526,8064,2992,8357,8357,2473,7110,8512,8033,6773,7669,8503,8503,7074,7304,8903,7714,8051,7714,7272,9030,8960,9040,7903,8420,8020,9309,7897,7897,9525,8961,8961,8961,3698,1738,3197,1210,7265,7111,734,7250,7249,7250,2261,7086,6785,7114,7077,7286,7239,3131,1461,6644,4405,7285,2360,7665,7658,7069,7641,4527,7115,6842,455,7283,7278,464,217,7878,7068,7655,7899,7665,7671,8044,7939,7659,396,7102,7675,8087,4405,8393,4696,8046,4406,7684,7287,5763,7661,8033,2398,5131,2530,8063,8282,7879,7717,8389,842,8430,7089,8767,7085,8064,8282,2192,6646,1131,8394,1029,8770,7662,7917,8475,8397,8722,7112,1163,7660,8282,8398,5362,1057,7661,7662,217,5907,8391,7760,6808,1718,4653,2187,8537,3134,8055,7943,7657,9225,9441,405,1245,6381,6743,323,6388,5386,388,6656,3515,858,6503,7107,5909,863,7654,7654,7713,7072,7155,7105,7644,7650,6796,380,726,1250,1165,979,8085,4490,4316,5298,5003,958,3059,5175,7021,7016,5379,6809,7374,1645,6774,5279,7307,2342,4574,6006,7837,7834,7835,6845,2261,6104,7836,2644,1307,4979,6880,5236,5373,6713,6368,2944,2387,7238,6821,4624,7951,4901,6658,5131,4406,8222,8085,1250,7281,501,7072,8047,4224,7282,6388,8057,8166,4234,8430,8050,7082,8208,7083,1746,8055,8368,8463,8409,8202,3885,3890,7270,3889,7122,4861,7287,7261,4769,4769,7097,3913,7250,8268,7080,8211,8080,3850,182,4936,1371,1351,840,7546,1145,1250,6810,947,4558,964,6778,783,1089,6561,7496,6235,7409,7389,7451,6810,4558,964,8436,6561,7516,7496,3066,8111,7127,6810,1766,1768,2932,1351,5996,3860,6366,6725,7840,6189,7570,7762,3913,6726,8109,2889,7635,8142,5551,4986,8390,7635,8297,7840,8109,3029,7879,1770,1765,8815,8730,8183,9030,1730,1766,6835,7124,5995,6740,7238,7283,7641,7238,834,1371,933,3302,2530,2183,2594,6842,8142,7635,567,1070,2632,8306,8306,223,2876,2033,4861,5070,2932,2706,4860,766,5179,5148,5799,7635,4109,567,4986,8617,8845,2889,5551,446,7634,8358,3216,1350,645,3370,975,1181,4160,2192,4423,396,3797,1738,455,734,1131,6192,744,5877,5362,766,4972,2674,5179,5764,4696,4861,2632,5247,1038,5764,2381,4730,1152,2882,4766,1057,1890,1439,1532,5543,2192,2331,2360,4240,3761,1042,4830,1835,1176,2657,5321,1177,7156,1826,1190,3062,3775,1461,6848,6780,1600,5321,2876,467,1176,7761,5487,470,3059,1092,3590,3303,1098,4964,3844,5765,7019,1600,1416,4947,2261,1460,2760,3136,4164,5218,3493,4984,3830,4348,6981,6104,5995,7834,1522,1869,2639,7837,7995,7836,8150,8146,8135,8000,7354,8087,665,7919,1416,1038,3303,5764,3590,3989,5623,8183,2033,215,5179,3844,6824,219,243,261,360,3067,3303,3341,3415,341,3418,3482,3778,8150,3788,4217,4722,5306,5509,6827,7835,6632,8089,4652,3941,5362,1257,1253,1318,1432,1325,8306,6154,3368,446,3830,4337,6713,1349,5576,1521,6595,1532,4652,3761,4460,1461,1038,1690,6684,5545,5719,7708,1369,7920,4395,4131,7812,7138,7239,3542,7839,3941,4082,7783,4209,6117,4566,6793,7919,4258,4796,8305,4983,7836,8222,308,5997,7821,7760,1347,5657,7803,8025,6849,8020,7835,6780,6156,7212,7147,6813,8923,8869,8890,4131,8925,8901,8900,8846,7839,4209,9054,8055,8080,7110,8044,665,7582,1253,6154,6315,6639,585,606,736,6674,8911,6942,6694,7712,1690,2025,2135,7602,8089,8306,6782,7138,3904,6863,4355,4220,8019,8615,8222,1461,9195,2590,7106,7096,223,5020,2933,6010,4023,7857,734,6785,6673,8025,7138,7005,7859,5286,228,3933,6792,4801,5148,5373,5349,5339,6901,8543,7837,7835,7834,7836,8441,9376,9073,9528,7503,1210,1116,964,5777,4652,4209,8195,7445,1089,1089,8205,3162,7981,7981,7981,8442,8442,435,5143,6687,529,7833,6809,6845,6104,4209,4209,4209,2954,5995,546,6544,9543,8204,7293,7292,1050,7599,2507,6905,7580,9120,8682,8320,8330,3875,7094,8336,8896,8681,8698,8899,8244,9041,8698,9184,9041,8656,8696,8945,7636,8694,1368,8692,8946,8693,8695,9037,7753,6354,8817,3073,7752,8943,4701,8946,8727,1769,8323,6371,1770,6223,1765,9037,1767,8248,979,1769,6599,1768,7631,6359,3115,3071,8704,1770,3719,8340,8705,9114,507,9149,8174,6354,9137,3559,7808,9278,9383,5297,8943,7753,8944,7752,8943,7881,1770,1767,1765,4716,1769,1767,8276,1768,1245,510,8275,8591,7751,9515,9407,7972,7973,8946,7592,6688,4944,7546,7748,7753,9665,321,9626,9037,1303,1770,222,1765,3073,8943,3071,7963,7881,8944,9601,9084,9624,7772,8618,9867,7770,8585,7185,7771,7187,512,9806,9907,7637,9906,9911,7753,9958,7752,10053,9720,6688,8727,9722,8946,9721,3071,9723,272,6600,10232,9215,1765,1770,8815,10255,9624,3719,344,10254,9720,5484,3647,7834,7882,1371,215,2117,2117,2160,7781,7783,186,7238,2467,8097,5763,6364,8093,6785,1183,8358,8358,8281,452,4079,4079,6588,8850,4535,2328,2328,8889,2911,2615,7900,9080,4983,6139,4985,9286,7037,8554,8778,9213,7951,9403,10194,1770,8910,10254,6538,10217,9406,10215,9601,379,6354,3070,6536,3073,6533,4305,3071,4282,6689,10158,510,10333,1768,1769,10332,10323,1771,7610,10188,7311,7753,5691,6354,7697,7752,4300,8088,1398,6678,7270,7251,7251,1126,6595,6447,2849,7856,6595,7296,7856,3595,6795,7296,7904,7714,7879,7271,7101,8053,8058,8034,8076,8040,7119,7931,8046,7878,7548,6155,7946,8284,8209,6235,7273,8373,8418,7840,7878,7879,7115,8481,8573,5320,8220,7280,4878,5320,8720,7971,7275,7297,7971,8761,7298,8419,7670,182,8683,7761,7547,182,3895,2522,8682,8618,6936,6938,7675,8698,8739,8933,9030,7124,3080,8412,8908,8580,7103,7083,4258,2605,8847,9134,8358,6354,9336,9134,8042,9244,9329,3070,9322,3073,1349,4460,9071,7087,9449,7239,8064,8458,6514,6514,8405,6986,9312,8832,6700,9367,9093,9777,1381,3760,8436,4299,3541,4160,8681,9958,9874,4178,2253,6619,9143,7368,1770,1765,9932,10109,10087,9603,8724,7113,9603,7649,9200,10008,1767,1771,7692,7690,7686,3172,5837,8896,1609,4805,3071,3875,8220,3590,1766,6740,1688,9963,3282,9769,10008,6828,1787,6642,7752,2261,8220,7973,7751,9146,2915,10379,2349,4847,4847,4728,675,1785,169,9951,9486,7368,5245,9951,9082,9026,8255,6658,9932,2474,8956,9009,3908,2337,9384,814,4330,7203,4234,7059,6624,9879,1357,7203,814,8856,8855,8761,1698,1308,1776,6030,3250,1766,9873,9833,3893,8793,1461,9344,6715,7235,2784,7246,9893,6427,9052,9115,9052,4566,1165,7903,3380,1215,446,8942,7823,9824,10742,4535,10475,4535,10475,8742,10228,10965,6728,6700,8080,10737,3860,9676,8669,576,9496,10929,4947,7598,9547,6416,10422,10381,6764,10264,6751,544,6151,6763,8160,6493,7705,573,8158,9859,1664,7605,2605,10416,2270,10742,8394,5484,10356,7751,10789,11289,6776,5487,9368,9367,8323,4730,93,11268,10836,10056,9300,8082,10768,10767,11719,11781,8910,8514,10722,10722,11670,7895,10543,9406,5647,8306,10339,10526,5995,4801,2467,11101,6740,7238,8220,446,223,2117,10836,8388,8302,1371,2913,5567,8520,11497,11497) ORDER BY , is_available DESC,(total_rating/no_of_ratings) DESC,title ASC,publisher ASC,active DESC,author ASC