withSolutions   Script Sample Showcase
 
Skip Navigation Links.   This is a script to rotate the positions of First and Last names.

 

****************************************************************

'NAME FLIP

'Smith, Jeff

****************************************************************

 

UPDATE tbl_OfficeDir

SET             

namepart1 = (select substring(Name, CHARINDEX(',', Name) + 2, len(name) )FROMĀ      tbl_OfficeDir a where tbl_OfficeDir.id = a.id)

 

UPDATE    tbl_OfficeDir

SET 

namepart2 = (select right(Name, CHARINDEX(',', Name) + 1) FROM  tbl_OfficeDir a where tbl_OfficeDir.id = a.id)