× 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.



Hi list!

This is "my complication" on this simple SQL:

=======================================================
FILE:ITEMBL
FIELDS:
ITNBR - ITEM NUMBER (KEY FIELD)
HOUSE - WAREHOUSE (KEY FIELD)
ITCLS - ITEM CLASS

FILE:ITMRVA
FIELDS:
ITNBR - ITEM NUMBER (KEY FIELD)
STID - SITE ID
ITCLS - ITEM CLASS

Goal: Update ITCLS in ITEMBL with ITCLS in ITMRVA only if:
a) STID = 'J2P'
b) HOUSE = 'JTG'
c) ITEMBL.ITCLS <> ITMRVA.ITCLS
=======================================================

This is the SQL I am doing:
UPDATE ITEMBL A SET A.ITCLS =
(SELECT ITCLS FROM ITMRVA B
WHERE A.ITNBR = B.ITNBR AND B.STID = 'J2P' AND A.ITCLS <> B.ITCLS)
WHERE A.ITNBR = B.ITNBR AND A.HOUSE = 'JTG'
?

The error I am having is: COLUMN QUALIFIER OR TABLE B UNDEFINED. If I
remove the "B" qualifier from the last B.ITNBR in the SQL, then I have
this error instead: NULL VALUES NOT ALLOWED IN COLUMN OR VARIABLE ITCLS.

I can't see what I am doing wrong ... HELP! Thanks in advance!


PETER VIDAL
PALL CORPORATION / SR SYSTEM ANALYST @ WH APPLICATION DEVELOPMENT GROUP
10540 RIDGE RD., SUITE 203, NEW PORT RICHEY, FL 34654-5111
' 727-815-3104 Ä 7 727-815-3120 Ä þ WWW.PALL.COM

?Imagination is more important than knowledge...?
Albert Einstein (1879 - 1955)
--------------------------------------------------------------------------------

Attention:

This communication may contain information that is confidential,
privileged and/or exempt from disclosure under applicable law.
If you are not the intended recipient, please notify the sender
immediately and delete the original, all attachments, and all
copies of this communication.


--------------------------------------------------------------------------------

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

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.