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

  • SEARCH
  • Home
  • 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 4560810
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 21, 20262026-05-21T17:59:04+00:00 2026-05-21T17:59:04+00:00

I am designing a File Server application in ASP.NET. I have to upload a

  • 0

I am designing a File Server application in ASP.NET. I have to upload a file of size 100MB and then save it into SQL Server 2008 database in varbinary(max). Saving file in DB is must. I am using FileUpload control. Please suggest me how to handle such large file?

UPDATE
Any code example would be great help, any code sample?
How to read file in chunks?

  • 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-21T17:59:05+00:00Added an answer on May 21, 2026 at 5:59 pm

    You can change the default limit (4mb) for a directory and its children by dropping a special web.config into that directory. That way you don’t have to make your whole site allow huge uploads (doing so would open you up to a certain kinds of attacks).

    Here’s an example from a production app. This one is set for 200mb:

    <?xml version="1.0"?>
    <!-- Nested this web.config here to allow for huge uploads (up to 200mb)  -->
    
    <configuration>
        <system.web>
          <httpRuntime maxRequestLength="200000"/>
        </system.web>
    </configuration>
    

    Nesting web.configs does not have any negative side-effects — your existing web.config settings will still work site-wide, and from this directory on down, these httpRuntime settings will be inherited.

    On the page that handles the upload, make sure you have a higher than normal ScriptTimeout. This is measured in seconds:

    Server.ScriptTimeout = 1200;
    

    I like setting this on the page rather than web.config because it isolates the increased timeout down to just this one page.

    On the SQL side, varbinary columns can be up to 2 gigs so you’re good to go there.

    Update: I’ve used this approach with 50+ meg files, but it’s possible that at the 100 meg point the standard methods might break down. There are a lot of third party controls available that could take over from there, but I would probably look hard at Telerik’s RadUpload since they’re a quality name and it looks very polished: RadUpload

    As for your update regarding reading the file in chunks, if you really want to write that yourself, Bobby D pointed out this article: Uploading Large Files Using an HttpModule

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

When designing a ASP.net WebForm application what are some important steps to take (or
I am designing a file-server application where I want to check if a cached
I'm looking into designing a media server application for a school project and was
I have a .aspx file with a datagrid in it: <asp:DataGrid ID=Gifts AutoGenerateColumns=True runat=server
It's been a while since I've created a new ASP.NET web application. (I've been
I have a unique issue - I am designing a web application that creates
I am designing an image file upload page for a website and, on Submit,
I have a WSDL file defining the interface for a web service and I
When designing LINQ classes using the LINQ to SQL designer I've sometimes needed to
When designing user table what would be the must have fields from the security/user

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.