Start the DatabaseFileRecovery SharePoint Server Repair Tool as an administrator on your system.
Click Open to view the dialog to browse the MDF file path from your system.
Now, select the Recovery option as per your requirement.
Now, click the Browse (...) icon to add the SharePoint Server MDF file from the system for recovery.
Select the Recovery mode as per the level of corruption, either Standard or Advanced.
Enable the Shows deleted and Advanced deleted records option to view all the records in the file.
The software also provides you with the Collation option: Auto-detect or Manual. You can pick one as per your needs.
Select the Log file path and click Ok to start scanning the added MDF file for recovery.
A tree structure gets loaded on the software wizard containing MDF file data. Click OK and Select the folders that you want to save.
Here, you can also preview the details of the specific folder by double-clicking it in the preview panel.
Now, click on the Save button, and either choose SQL Server Database or SQL Server Compatible SQL Script.
The software offers you two different options: Windows Authentication and Server Authentication.
First, we go for Windows Authentication. Here, you have to enter the Server Name and Database Name. Or, you can also save it in the existing database.
Please enable some other advanced features if required:
Click Test Database Connections to check if it is working or not. You will find a pop-up showing Database Connection established successfully. Click OK.
Secondly, we go for Server Authentication. Here, you have to enter the following details: User Name, Password, Server Name, and Database name. Or, you can also save it in the existing database.
Click on the Test Database Connection to establish the proper connection with the server. Click Ok to start the restoring process.
Finally, the saving process is completed and your SharePoint files are stored in the SQL Database. Click OK.
Opt for the SQL Server Compatible SQL Script option and select the saving location for the output folder. Click OK to start the process.
Finally, the SQL script has been completed for the selected database and you have saved files successfully. Click OK.