Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ASP operands

Status
Not open for further replies.

davmold

IS-IT--Management
Jul 16, 2007
29
US
I am still learing ASP

I know you can do a <, >, =, etc.

but how could you do a between for example I would like to take the numbers between 1 and 7 can this be done with asp?

thank you
 
Like this:

Code:
a > 1 and a < 7

There is no direct 'between' operand.

[monkey][snake] <.
 
Although, if you wanted it to match the T-SQL BETWEEN operand, you'd use a >= 1 AND a <= 7.

BETWEEN includes the outer bounds.

I wish ASP had a BETWEEN operand.
 
Depends on how you think. Some people like the a on the left, some on the right, some on the inside and some on the outside. Just a matter of style.
Code:
a > 1 and a < 7  ' on the left
a > 1 and 7 > a  ' on the outside
1 < a and a < 7  ' on the inside
1 < a and 7 > a  ' on the right
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top