Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

NEWBIE - Update SQL based on Sub-query

Status
Not open for further replies.

enbw

Technical User
Mar 13, 2003
296
I have an sql select query.

select distinct pub.partopr.partnum, pub.partmtl.revisionnum, pub.partmtl.mtlpartnum, pub.partmtl.qtyper, pub.partopr.prodstandard
from pub.partmtl, pub.partopr
where
pub.partmtl.mtlpartnum like '%MELT%' and
pub.partmtl.partnum = pub.partopr.partnum
and pub.partmtl.revisionnum = pub.partopr.revisionnum
and pub.partmtl.relatedoperation = pub.partopr.oprseq
and pub.partmtl.qtyper <> pub.partopr.prodstandard * 100

I want to know if I can use this in a UPDATE query. I want to update prodstandard by qtyper / 100. I have tried it but I can't seem to query it.

Thanks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top