|
database
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
UPdating a table column with substring of another columnHi,
I want to update a column based on substring of another column (of the same row and same table). How can I do that? Thanx. Try,
update dbo.t1 set c1 = substring(c1, 5, 10) where ... go AMB Show quote "mavrick_101" wrote: > Hi, > > I want to update a column based on substring of another column (of the same > row and same table). How can I do that? > > Thanx. It would help us better assist you if you could include table DDL, query
strategy used so far, sample data in the form of INSERT statements, and an illustration of the desired results. ( For help with that refer to: http://www.aspfaq.com/5006 ) Look up SUBSTRING in Books on Line. -- Show quoteArnie Rowland Most good judgment comes from experience. Most experience comes from bad judgment. - Anonymous "mavrick_101" <mavrick***@discussions.microsoft.com> wrote in message news:3C223AD9-A123-43F4-BF52-A1001FF2CD63@microsoft.com... > Hi, > > I want to update a column based on substring of another column (of the > same > row and same table). How can I do that? > > Thanx. |
|||||||||||||||||||||||