Selection of the SD card internal or external to format.
know the path of memory before you format
**** Be caution while erasing the data*******
It will erase the data only on SD card
The photos and videos are also stored on dcim folder on sd card. Check the folder and erase
There will be no backup of the data ,everything will be erased permanently.