<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">2016-03-01 23:36 GMT+06:00 Adam Chlipala <span dir="ltr"><<a href="mailto:adamc@csail.mit.edu" target="_blank">adamc@csail.mit.edu</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">The only issue here is that Ur/Web forces local table names to be capitalized.</blockquote><div><br></div><div>Thank you very much!</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class=""><br>
<br>
On 03/01/2016 11:34 AM, Artyom Shalkhakov wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Dear all,<br>
<br>
How to write a query that involves renaming of table vars?<br>
<br>
For instance, I'd like to write something along the lines of:<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
SELECT<br>
category.CategoryID,<br>
category.Title,<br>
category.Slug,<br>
category.ImageID,<br>
category.ParentCategoryID,<br>
0 AS ProductCount<br>
FROM category<br>
INNER JOIN product_of_category AS pc ON<br>
category.CategoryID = pc.CategoryID<br>
WHERE pc.ProductID = {[product_id]}<br>
</blockquote>
And I get:<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
syntax error: deleting SYMBOL AS<br>
</blockquote></blockquote>
<br>
<br></span>
_______________________________________________<br>
Ur mailing list<br>
<a href="mailto:Ur@impredicative.com" target="_blank">Ur@impredicative.com</a><br>
<a href="http://www.impredicative.com/cgi-bin/mailman/listinfo/ur" rel="noreferrer" target="_blank">http://www.impredicative.com/cgi-bin/mailman/listinfo/ur</a><br>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature">Cheers,<br>Artyom Shalkhakov<br></div>
</div></div>