Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Importing long CSV file in asp.net

Posted on 2013-01-10
3
Medium Priority
?
668 Views
Last Modified: 2013-01-16
I have option in my web application, there user can upload a csv list of users. Total number of users can be in 15,000 or 1 million.

We I run the import process in the same thread then I gets Request Timeout error.

what should I do so that I let the user import this much big csv list.
0
Comment
Question by:yadavdep
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 42

Accepted Solution

by:
Meir Rivkin earned 1000 total points
ID: 38762256
first compress the csv list to binary stream, secondly increase the timeout in web.config to the specific page:


<location path="<the-page>.aspx">
        <system.web>
                <httpRuntime executionTimeout="250"/>
        </system.web>
</location>

FYI, ExecutionTimeout specifies the maximum number of seconds that a request is allowed to execute before being automatically shut down by ASP.NET.
The default value for this attribute has been set to 90 seconds in ASP.NET 1.x and was increased to 110 seconds in ASP.NET 2.0.
from
0
 
LVL 39

Expert Comment

by:Pratima Pharande
ID: 38762261
see here are some options .. which may help you

http://www.codeproject.com/Questions/212510/how-import-CSV-file-in-asp-net
0
 
LVL 42

Expert Comment

by:Meir Rivkin
ID: 38762274
by default, iis7 supports up to 30MB files, you can increase this number to over 100MB using the following command:
Adjusting File upload size in IIS7

if you are using asp FileUpload control, here's a tutorial how to achieve this:
FileUpload tutorial

using old fashioned input type="file":
Upload file old-fashioned
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

More often than not, we developers are confronted with a need: a need to make some kind of magic happen via code. Whether it is for a client, for the boss, or for our own personal projects, the need must be satisfied. Most of the time, the Framework…
Entity Framework is a powerful tool to help you interact with the DataBase but still doesn't help much when we have a Stored Procedure that returns more than one resultset. The solution takes some of out-of-the-box thinking; read on!
Sometimes it takes a new vantage point, apart from our everyday security practices, to truly see our Active Directory (AD) vulnerabilities. We get used to implementing the same techniques and checking the same areas for a breach. This pattern can re…
This lesson discusses how to use a Mainform + Subforms in Microsoft Access to find and enter data for payments on orders. The sample data comes from a custom shop that builds and sells movable storage structures that are delivered to your property. …

618 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question