Dec 16, 2001 #1 alqsp Programmer Dec 12, 2001 9 AU Hi, I need help in updating the 39 character of a 40 char field: update Tabaddr set Addr(39th char only) = 0 where Addr_num = 4 Does anyone know how to make an update to just the one character in the Addr field? Something like Addr(39:1?
Hi, I need help in updating the 39 character of a 40 char field: update Tabaddr set Addr(39th char only) = 0 where Addr_num = 4 Does anyone know how to make an update to just the one character in the Addr field? Something like Addr(39:1?
Dec 16, 2001 #2 tomschafer Technical User Aug 9, 2001 474 US Check to see if your DB engine has the mid function.... update Tabaddr set mid(addr,39,1)= 0 where Addr_num = 4 Upvote 0 Downvote
Check to see if your DB engine has the mid function.... update Tabaddr set mid(addr,39,1)= 0 where Addr_num = 4
Dec 17, 2001 #3 rac2 Programmer Apr 26, 2001 1,871 US In SQL Server - Code: UPDATE Tabaddr SET Addr = STUFF(Addr, 39, 1, '0') where Addr_num = 4 In Access - Code: UPDATE tabaddr SET Addr = Left(Addr, 38) & '0' & Right(Addr, 1) where Addr_num = 4 Upvote 0 Downvote
In SQL Server - Code: UPDATE Tabaddr SET Addr = STUFF(Addr, 39, 1, '0') where Addr_num = 4 In Access - Code: UPDATE tabaddr SET Addr = Left(Addr, 38) & '0' & Right(Addr, 1) where Addr_num = 4