Apparentally, I am missing a close ")" in my code because I am receiving this SQL message:
Server: Msg 170, Level 15, State 1, Line 12
Line 12: Incorrect syntax near ')'.
But, now I am wondering if it is possible for a query to contain a subquery both of which select from the same View? I have try putting a close parentesis in various places and searched BOL for some help and I am stuck. Here is my code:
It seems fairly simple, but, can someone see where I am going wrong? Please let me know what additional info. to provide.
Thanks, lradon
Server: Msg 170, Level 15, State 1, Line 12
Line 12: Incorrect syntax near ')'.
But, now I am wondering if it is possible for a query to contain a subquery both of which select from the same View? I have try putting a close parentesis in various places and searched BOL for some help and I am stuck. Here is my code:
Code:
select APLNUM, * from underwriters
Where (SELECT APLNUM from underwriters WHERE (STATDATE >= '03/01/06' and STATDATE <='03/28/06' and STATUS = 'a' or status='d' or status='q' or status='c'))
It seems fairly simple, but, can someone see where I am going wrong? Please let me know what additional info. to provide.
Thanks, lradon