Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 723971
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T06:10:09+00:00 2026-05-14T06:10:09+00:00

currently I’m trying to have a setup where a generic database is distributed to

  • 0

currently I’m trying to have a setup where a generic database is distributed to students. They would develop an application using this database (Say a shopping cart application), submit their project onto our server, and then it would be graded automatically.

These databases are being run in Microsoft SQL Server 2005.

We’re using user instances to instantiate each database, and multiple requests could be serviced at once. But, the problem is when more than one student submitted a project to be graded, the first database to be instantiated would be the only one and would overwrite all other copies that were currently open.

So if stu1 modified his database and stu2 and stu3 had their projects being graded concurrently, at the end of the grading stu1, stu2, and stu3 would have identical DB’s at the end.

Is there any way I can have multiple independent copies of a generic database, each of which I can load concurrently and modify without having any changes made to any one affecting the others?

I did a little reading, and thought it might be possible to do something along the lines of:

  1. Student submits project
  2. Attach the database with unique db
    name (specified by student)
  3. Do all necessary operations
  4. Detach the database

I’m unsure if this would fix our problem or be possible, so any help would be much appreciated!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-14T06:10:09+00:00Added an answer on May 14, 2026 at 6:10 am

    We do something similar where customers login to a website and enter setup information. The website then creates a copy of a generic database and loads the setup information into the database, creates a backup and sends the backup file to the customer. Sounds like your main issue is all the database are named the same. My suggestion is to use the following steps for grading:

    1. Students submit a backup copy of their database (standard .BAK file).
    2. Your grading system uses a script to first create a new blank database with a unique name on the server. It is important to create a new database first so that the files get created in the correct location on the server. To create a unique name you should use a project id, student id, and possibly a timestamp if students will be submitting multiple databases.
    3. The script then replaces the blank database with the database from the backup using the With Replace option.
    4. You are then able to run whatever grading steps are needed and either keep the database attached for future reference or drop it if space is limited.

    You could write the script in either C# or Powershell, and use the following SQL queries:

    USE Master
    CREATE DATABASE [PROJECTID_STUDENTID_TIMESTAMP]
    --Unique database is now created and stored in default SQL data/log file location
    RESTORE DATABASE [PROJECTID_STUDENTID_TIMESTAMP] FROM DISK = 'c:\pathtofile\filename.bak' WITH REPLACE
    --Student database is now available for grading
    USE [PROJECTID_STUDENTID_TIMESTAMP]
    --Add grading scripts here
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 447k
  • Answers 447k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer A partial solution has been found for anyone wondering. The… May 15, 2026 at 7:29 pm
  • Editorial Team
    Editorial Team added an answer Most mail transfer agents let you put in filters that… May 15, 2026 at 7:29 pm
  • Editorial Team
    Editorial Team added an answer i've resolved it. the problem was that the field OBJNRFICHIERS… May 15, 2026 at 7:29 pm

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.