× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



UPDATE PVIDAL/INSPEC A SET A.INMJMN = '6'
WHERE A.INATRB LIKE '%ANODIZE%' AND
A.INSPEC.INMJMN <> 6 AND
EXISTS
(SELECT 1
FROM RGTOPR B
WHERE A.INITEM = B.RTID AND
B.WKCTR='CA00')

Elvis

Celebrating 10-Years of SQL Performance Excellence

-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx
[mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of Peter Vidal
Sent: Tuesday, April 17, 2007 2:50 PM
To: Midrange Systems Technical Discussion
Subject: Re: SQL UPDATE with SELECT not working

"UPDATE PVIDAL/INSPEC SET INMJMN = '6' WHERE EXISTS..."

I do not want to update all records. I am doing things wrong,
definitively.

I want to update just the ones that follow this selection criteria
described below.

Files: INSPEC, RTGOPR
Key fields: INSPEC.INITEM, RTGOPR.RTID

I want to UPDATE NISPEC.INMJMN = '6' only where:

a) INSPEC.INITEM = RTGOPR.RTID
b) INSPEC.INATRB Like '%ANODIZE%'
c) INSPEC.INMJMN<>6
d) RTGOPR.WKCTR='CA00'


Peter Vidal
PALL Corporation / SR Programmer Analyst, IT Development Group
10540 Ridge Rd., Ste 203, New Port Richey, FL 34654-5111
http://www.pall.com

"The first step to getting the things you want out of life is this: Decide
what you want."
Ben Stein



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.