Can I query Microsoft GP database and save the result as MDF file? I have a request as below for auditing purpose on Microsoft Dynamic GP database.


Database files are required as .mdf and .ldf files for certain companies
Only need the certain period time of data, not entire database from day 1 till now


My questions:


Is this even possible to provide only certain period time of activities from database as .mdf file? I mean if the .mdf file is required, it must be the entire database right?
If it is possible, how? Query the database for everything happened in that period of time and save it as .mdf file and .ldf file? Or somehow somewhat cut the .mdf file? I don't think so...
or if I provide entire database with only that period of transaction log?


I posted this question on overflow, It should be posted here.
The way to handle this is to create a new database with a different name (for example, MyDB_Export), then use the Export functionality in Sql Server Management Studio - right-click on the database in SSMS, and click Tasks / Export Data... on the pop-up menus. The only thing you will do is to specify a query to select the data to export to the new DB.

Its pretty intuitive to walk through the steps, so you should be able to work out how to complete this easily once you are in the Import/Export Wizard. If not, just add a comment below and I'll expand on this.