you wouldn't put -1 in the URL variable.
what this is doing is:
if the URL is:
category.php?Category=
the where clause becomes:
categories.CategoryLink = -1 OR -1 = -1
so: OR -1 = -1 evaluates to true
but if you pass a value for the category:
category.php?Category=Occasional-Chairs
then the comparison is:
categories.CategoryLink = Occasional-Chairs OR -1 = Occasional-Chairs
hopefully that clarifies.