Dear all,

How to write a query that involves renaming of table vars?

For instance, I'd like to write something along the lines of:

> SELECT
>     category.CategoryID,
>     category.Title,
>     category.Slug,
>     category.ImageID,
>     category.ParentCategoryID,
>     0 AS ProductCount
> FROM category
> INNER JOIN product_of_category AS pc ON
> category.CategoryID = pc.CategoryID
> WHERE pc.ProductID = {[product_id]}

And I get:

> syntax error: deleting  SYMBOL AS

-- 
Cheers,
Artyom Shalkhakov

_______________________________________________
Ur mailing list
[email protected]
http://www.impredicative.com/cgi-bin/mailman/listinfo/ur

Reply via email to