got the issue resolved. it was the backtickes in the sql statement giving the problems.
but now one more issue. keeping the above code as it is, i get an error in several places. It is:
Warning: mysql_error(): 10 is not a valid MySQL-Link resource in C:\xampp\htdocs\blog\wp-includes\wp-db.php on line 615
but if i remove the mysql_close($cxnGG);
part from the above code, everything works out real smoothly.
so my final question is, would this cause any vulnerability issues in the code? i don’t want any hacker getting inside my server nor my databses.
Thanks a lot people.