Using IN

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Using IN

Carol Jones
new to the listserv....

I have a select statement example

If (race = '01' or race = '02' or race = '03' .....) pie = 1.

My list is long.  How can I just list the values using an "in"
statement? Can I?

ex. If race in ('01' , '02', '03'..... ) pie = 1.

Thanks
Reply | Threaded
Open this post in threaded view
|

Re: Using IN

Edward Boadi
Try this :

If any(race,'01','02','03',............. ) pie = 1.

Edward.
-----Original Message-----
From: SPSSX(r) Discussion [mailto:[hidden email]]On Behalf Of
Carol Jones
Sent: Friday, October 13, 2006 12:31 PM
To: [hidden email]
Subject: Using IN


new to the listserv....

I have a select statement example

If (race = '01' or race = '02' or race = '03' .....) pie = 1.

My list is long.  How can I just list the values using an "in"
statement? Can I?

ex. If race in ('01' , '02', '03'..... ) pie = 1.

Thanks