Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. Help About the posting the large amount data through the HTTP POST Method

Help About the posting the large amount data through the HTTP POST Method

Scheduled Pinned Locked Moved ASP.NET
helpdatabase
9 Posts 4 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D Offline
    D Offline
    Deepak the Cool
    wrote on last edited by
    #1

    Hi All, I am facing one problem,tht is I upload an excel file with 65,000 of rows.So the task is tht First I hav to insert these rows into my DB is it ok I had done it and the whole execution done within 10 secs. Second task is tht,I hav to post tht data into a another site through HTTP POST method tht is ok for me ,But the main problem is tht, I hav to post only the 500 number of rows into a single execution.So the sceniro is tht 65000/500 the total number of execution. So i want to run tht execution fastly,Coz if I run traditionl method then my posting page has expird or connection forcily closed. So is it possible I have to save that file into a particular laocation and when tht file will be posting into lacation then an automtic service run at background and tht will done all work.I am not talking about the windows scheduling.It is might be a windows service but I want to initate when my file will be save on a particular laocation. If anybody can help me for the same then please help me. :-O

    Deepak :) Smile a Lots,Its Costs Nothing

    C J 2 Replies Last reply
    0
    • D Deepak the Cool

      Hi All, I am facing one problem,tht is I upload an excel file with 65,000 of rows.So the task is tht First I hav to insert these rows into my DB is it ok I had done it and the whole execution done within 10 secs. Second task is tht,I hav to post tht data into a another site through HTTP POST method tht is ok for me ,But the main problem is tht, I hav to post only the 500 number of rows into a single execution.So the sceniro is tht 65000/500 the total number of execution. So i want to run tht execution fastly,Coz if I run traditionl method then my posting page has expird or connection forcily closed. So is it possible I have to save that file into a particular laocation and when tht file will be posting into lacation then an automtic service run at background and tht will done all work.I am not talking about the windows scheduling.It is might be a windows service but I want to initate when my file will be save on a particular laocation. If anybody can help me for the same then please help me. :-O

      Deepak :) Smile a Lots,Its Costs Nothing

      C Offline
      C Offline
      Christian Graus
      wrote on last edited by
      #2

      Your best bet IMO is to have a webservice at the other end and to do multiple calls that send the data a bit at a time. A windows service could handle this on the server and the ASP.NET page could simply tell it to start work, then return a page to the client.

      Christian Graus Driven to the arms of OSX by Vista. Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.

      D 1 Reply Last reply
      0
      • C Christian Graus

        Your best bet IMO is to have a webservice at the other end and to do multiple calls that send the data a bit at a time. A windows service could handle this on the server and the ASP.NET page could simply tell it to start work, then return a page to the client.

        Christian Graus Driven to the arms of OSX by Vista. Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.

        D Offline
        D Offline
        Deepak the Cool
        wrote on last edited by
        #3

        Hi Crisitan, Thanks for ur help.Can u discribe it more.And how can I initate a windows service through asp.net page.Please tell me or if any link for tht particular tutorial then give me.

        Deepak :) Smile a Lots,Its Costs Nothing

        C 1 Reply Last reply
        0
        • D Deepak the Cool

          Hi Crisitan, Thanks for ur help.Can u discribe it more.And how can I initate a windows service through asp.net page.Please tell me or if any link for tht particular tutorial then give me.

          Deepak :) Smile a Lots,Its Costs Nothing

          C Offline
          C Offline
          Christian Graus
          wrote on last edited by
          #4

          Well, I am assuming you have control over the whole process. I'm not sure exactly how an ASP.NET process would kick off a service, I've done it, but it was a long time ago. The core thing is, do you have control over the end that is recieving the Excel data, to replace your HTTP Post code with a web service ? If not, a windows service could still do the post without holding up a web page lifecycle, but you wouldn't be able to fully take my advice in that case.

          Christian Graus Driven to the arms of OSX by Vista. Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.

          D 1 Reply Last reply
          0
          • C Christian Graus

            Well, I am assuming you have control over the whole process. I'm not sure exactly how an ASP.NET process would kick off a service, I've done it, but it was a long time ago. The core thing is, do you have control over the end that is recieving the Excel data, to replace your HTTP Post code with a web service ? If not, a windows service could still do the post without holding up a web page lifecycle, but you wouldn't be able to fully take my advice in that case.

            Christian Graus Driven to the arms of OSX by Vista. Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.

            D Offline
            D Offline
            Deepak the Cool
            wrote on last edited by
            #5

            Crisitan My sceniro is this suppose i hav 65,000 number of rows.Now I uplaod the file and click the send button.then I create the insert command for tht to DB.Now I hav a web service instance which is get the data from DB and post it a another site page by the size of 500 number of rows.So my web service work on tht and it will a slow proceess to sent the data meanwile my web page expird after 20,000 number of rows post on the another server.coz it has several simeltenous task to work e.g. inventory management,retrun response to insert the data. so i want to do only data insertion into my web page after that a background process will be done it.if i create windows scervice for tht then the schedule will be run after a schedule time.But I want to run it at the time of posting the data.

            Deepak :) Smile a Lots,Its Costs Nothing

            N 1 Reply Last reply
            0
            • D Deepak the Cool

              Crisitan My sceniro is this suppose i hav 65,000 number of rows.Now I uplaod the file and click the send button.then I create the insert command for tht to DB.Now I hav a web service instance which is get the data from DB and post it a another site page by the size of 500 number of rows.So my web service work on tht and it will a slow proceess to sent the data meanwile my web page expird after 20,000 number of rows post on the another server.coz it has several simeltenous task to work e.g. inventory management,retrun response to insert the data. so i want to do only data insertion into my web page after that a background process will be done it.if i create windows scervice for tht then the schedule will be run after a schedule time.But I want to run it at the time of posting the data.

              Deepak :) Smile a Lots,Its Costs Nothing

              N Offline
              N Offline
              N a v a n e e t h
              wrote on last edited by
              #6

              Your design is confusing. Here is my suggestion though. Don't call web service from your ASP.NET application as it is taking long time. Delegate this task to the background service. You may need to create a database table in which all the records that has to be processed should reside. Your ASP.NET application has to insert rows into this table and background service should poll this table regularly. Get the data from this table and call required webservice. :)

              Best wishes, Navaneeth

              D 1 Reply Last reply
              0
              • N N a v a n e e t h

                Your design is confusing. Here is my suggestion though. Don't call web service from your ASP.NET application as it is taking long time. Delegate this task to the background service. You may need to create a database table in which all the records that has to be processed should reside. Your ASP.NET application has to insert rows into this table and background service should poll this table regularly. Get the data from this table and call required webservice. :)

                Best wishes, Navaneeth

                D Offline
                D Offline
                Deepak the Cool
                wrote on last edited by
                #7

                Boss How do I call the service through windows service.If yes the it has some time of interval to run for.But i want run it to current task.if i set the interval at least then procees execution time will be more then the time callback time.if I set it 5 to 10 minutes of timer then user is not ready to accept to much time to show the response.

                Deepak :) Smile a Lots,Its Costs Nothing

                N 1 Reply Last reply
                0
                • D Deepak the Cool

                  Boss How do I call the service through windows service.If yes the it has some time of interval to run for.But i want run it to current task.if i set the interval at least then procees execution time will be more then the time callback time.if I set it 5 to 10 minutes of timer then user is not ready to accept to much time to show the response.

                  Deepak :) Smile a Lots,Its Costs Nothing

                  N Offline
                  N Offline
                  N a v a n e e t h
                  wrote on last edited by
                  #8

                  Windows services are expected to run all the time. So there won't be any scheduling. You run each web service call on a separate thread and keep the other thread polling the table. So you don't find any delays in the processing.

                  Best wishes, Navaneeth

                  1 Reply Last reply
                  0
                  • D Deepak the Cool

                    Hi All, I am facing one problem,tht is I upload an excel file with 65,000 of rows.So the task is tht First I hav to insert these rows into my DB is it ok I had done it and the whole execution done within 10 secs. Second task is tht,I hav to post tht data into a another site through HTTP POST method tht is ok for me ,But the main problem is tht, I hav to post only the 500 number of rows into a single execution.So the sceniro is tht 65000/500 the total number of execution. So i want to run tht execution fastly,Coz if I run traditionl method then my posting page has expird or connection forcily closed. So is it possible I have to save that file into a particular laocation and when tht file will be posting into lacation then an automtic service run at background and tht will done all work.I am not talking about the windows scheduling.It is might be a windows service but I want to initate when my file will be save on a particular laocation. If anybody can help me for the same then please help me. :-O

                    Deepak :) Smile a Lots,Its Costs Nothing

                    J Offline
                    J Offline
                    Jaiprakash M Bankolli
                    wrote on last edited by
                    #9

                    I want to know do you have control over other database, I mean lets assume that DB1 is where you are uploading excel data, and post the these details to DB2. So if you have access to that DB then I would suggest right CLR enabled SP which will run at MS SQL server level rather calling it via web application which is very very slow. So to improve the performance you can divide the task and process it in separate places. Let me know if you need any further details on the above design.

                    Regards, Jaiprakash M Bankolli jaiprakash.bankolli@gmail.com My Blog Suggestions for me

                    1 Reply Last reply
                    0
                    Reply
                    • Reply as topic
                    Log in to reply
                    • Oldest to Newest
                    • Newest to Oldest
                    • Most Votes


                    • Login

                    • Don't have an account? Register

                    • Login or register to search.
                    • First post
                      Last post
                    0
                    • Categories
                    • Recent
                    • Tags
                    • Popular
                    • World
                    • Users
                    • Groups