I have this query:
SELECT `post`.`id` AS `posts_id,
`categories`.`id` AS `category_id`,
`title`,
`contents`,
`date_posted`,
`categories`.`name
FROM `post`
INNER JOIN `categories` ON `categories`.`id` = `post`.`cat_id`
And it yields this error:
1064 - 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:
'categories
.idAScategory_id,title,contents,date_posted,cat' at line 1