get base urls with different "endings" after the last slash
SELECT DISTINCT t1.*
FROM testtable t1, testtable t2
WHERE t1.field2 = t2.field2
  AND t1.urlTest != t2.urlTest
  AND SUBSTRING(REVERSE(t1.urlTest) FROM LOCATE('/', REVERSE(t1.urlTest)))
     =SUBSTRING(REVERSE(t2.urlTest) FROM LOCATE('/', REVERSE(t2.urlTest)))


fiddle