I had a lot of problems getting the targeting to work right when I tried setting it according to whether my weapon is sheathed or unsheathed. I eventually found that disabling that and instead using the L1+triangle, L1+circle, etc to target different groups works much better. (Personally, I use L1+square for targeting enemies, L1+circle for players, and L1+triangle for everything, but you can configure that however you want.)

That isn't to say that SE shouldn't fix the sheathed/unsheathed targeting, because I think they really should, but in the meantime, try the alternative that's less buggy.