Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > In List

Reply
Thread Tools

In List

 
 
Mat
Guest
Posts: n/a
 
      12-08-2006
In SQL you can use the operator "IN" in a where clause.

Is it possible to use the same in an vbscript IF statement?


 
Reply With Quote
 
 
 
 
Rad [Visual C# MVP]
Guest
Posts: n/a
 
      12-08-2006
On Fri, 8 Dec 2006 13:34:22 -0500, Mat wrote:

> In SQL you can use the operator "IN" in a where clause.
>
> Is it possible to use the same in an vbscript IF statement?


Yep.

Like so:

Select fullname, age from people where age in (50,60,70)
--
Bits.Bytes
http://bytes.thinkersroom.com
 
Reply With Quote
 
 
 
 
Rad [Visual C# MVP]
Guest
Posts: n/a
 
      12-08-2006
On Fri, 8 Dec 2006 13:34:22 -0500, Mat wrote:

> In SQL you can use the operator "IN" in a where clause.
>
> Is it possible to use the same in an vbscript IF statement?


Sorry, less haste, less waste!

Not sure VBScript can do that...

Closes thing would be to put what you want in an array or some such
collection then process it in a foreach loop I'd think...
--
Bits.Bytes
http://bytes.thinkersroom.com
 
Reply With Quote
 
Mat
Guest
Posts: n/a
 
      12-09-2006
select case can do it but this is not beautiful

"Rad [Visual C# MVP]" <> wrote in message
news:1x669alf46wuv$....
> On Fri, 8 Dec 2006 13:34:22 -0500, Mat wrote:
>
>> In SQL you can use the operator "IN" in a where clause.
>>
>> Is it possible to use the same in an vbscript IF statement?

>
> Sorry, less haste, less waste!
>
> Not sure VBScript can do that...
>
> Closes thing would be to put what you want in an array or some such
> collection then process it in a foreach loop I'd think...
> --
> Bits.Bytes
> http://bytes.thinkersroom.com



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Java Collections List : Converting from List '<Column <String1,String2>>' to 'List <String1>' asil klin Java 28 03-05-2011 01:59 AM
Memory issues when storing as List of Strings vs List of List OW Ghim Siong Python 2 11-30-2010 12:22 PM
Appending a list's elements to another list using a list comprehension Debajit Adhikary Python 17 10-18-2007 06:45 PM
Why does list.__getitem__ return a list instance for subclasses ofthe list type? dackz Python 0 02-06-2007 04:44 PM
Difference Between List x; and List x(); , if 'List' is a Class? roopa C++ 6 08-27-2004 06:18 PM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57