SIM card is not working on Sony Xperia Z (Android 4.1.2)
Can you take a look at the SIM and phone SIM socket if they are oxidized/dirty/greasy?
If that is the case, you can clean it with a cotton cloth dipped in ethylene alcohol.
If the SIM socket pins are somehow are pushed down, that could be also an issue.