Produces a value from a sequence of operands and operators.
is one of the following:
is described in Operators and the Order of Evaluation.
select style, scan(street,1) format=$15. from houses;
create view myemp as select * from dept12.employees where upcase(manager)=user;
3>null -3>null 0>null
See BETWEEN Condition.
|
||
see CONTAINS Condition.
|
||
See EXISTS Condition.
|
||
See IN Condition.
|
||
See IS Condition.
|
||
See LIKE Condition.
|
||
sounds like (use with
character operands only). See Retrieving Values with the SOUNDS-LIKE Operator.
|
||
equal to truncated strings
(use with character operands only). See Truncated String Comparison Operators.
|
||
'TWOSTORY'
eqt 'TWO'
is true because the string 'TWOSTORY' is reduced
to 'TWO' before the comparison is performed. Note that the truncation
is performed internally; neither operand is permanently changed.
proc sql; title 'Information for Earl Bowden'; select * from proclib.payroll where idnumber= (select idnum from proclib.staff where upcase(lname)='BOWDEN');
proc sql outobs=5; title 'International Flights from'; title2 'PROCLIB.MARCH'; select Flight, Date, Dest, Boarded from proclib.march where flight in (select flight from proclib.delay where destype='International');
ME3
:
proc sql outobs=5; title 'International Flights'; select * from proclib.march where 'International' in (select destype from proclib.delay where march.Flight=delay.Flight);
219
,
the subquery resolves as follows:
proc sql; select * from proclib.payroll where salary> all(select salary from proclib.payroll where jobcode='ME3'); proc sql; select * from proclib.payroll where salary> (select max(salary) from proclib.payroll where jobcode='ME3');
proc sql; select * from proclib.payroll p where exists (select * from staff s where p.idnum=s.idnum and state='CT'); proc sql; select * from proclib.payroll where idnum in (select idnum from staff where state='CT');