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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

UPDATE QUERY -SQL SERVER 2005

Status
Not open for further replies.

Mahey

Programmer
Dec 24, 2008
52
SA
Hi,

I want to update the table like the following manner.

Field "Item_Description" is having the data's

ASMITEMS for department
BSDBILL -systems
RVF..........
ASM..........
TYP........
BSD..............
ASM..................

THANKS

But I want to update like the "itm_code" by following
[only 1st 3 letters+Counts)

ASM1
BSD1
RVF1
ASM2
TYP1
BSD2
ASM3

like wise ...means when the value is found again, need to increase the counter

update itm_code set itm_code=substring(Itm_description,1,3)+.............from item_master....????
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top