Wait few minutes until your Sony Xperia Z5 Compact reboots. By the time it boots on, all the data on the phone would have gone and the phone now back to its factory default settings.

Good. You have just performed a Factory Reset on your Sony Xperia Z5 Compact.

NOTE:

Hard Reset is the process of reverting your phone's settings to its factory defaults using some key combinations without going through the phone settings before doing so. While Factory Reset is the process of resetting your phone to its factory default settings while the phone is on Android Mode.

The end result of both method is to clear or wipe off your phone contents, in this case, your Sony Xperia Z5 Compact.