Oracle regular expression replace in string ignoring first and last characters regular expression replace in string ignoring first and last characters if they matched

my try

SELECT REGEXP_REPLACE ('TLYU TK0T23T', '[^(\A.)]T[^(.\Z)]', 'Qq' ) contain FROM dual;    


result 

TLYUQqQq3T


expected result

TLYU QqK0Qq23T


Thanks in advance
This returns the answer you want:

SELECT REGEXP_REPLACE 
('TLYU TK0T23T', '([^(\A.)])T([^(.\Z)])', '\1Qq\2' ) contain 
FROM dual;


Bobby