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. Database & SysAdmin
  3. Database
  4. help with data update strategy

help with data update strategy

Scheduled Pinned Locked Moved Database
questiondatabasehelptutorialannouncement
4 Posts 2 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.
  • E Offline
    E Offline
    ekynox
    wrote on last edited by
    #1

    Hi Guys, As of a few days ago I started to venture into the world of SQL. Subsequently I have a question on best practices relating to data population of a win form component. For example, if you have a sql table which has a product column containing about 100 items. Now you want to pass these product items into a combo-box's drop down list ? What would be the best way of doing it ? At the moment, I can set the data source property of the combo-box directly to this table containing the product items column. However, the product item's column changes data changes say couple of items per hour then what would be a good best pratice of keeping the combo box's drop down list updated ? My idea would be to use data caching and apply a time expiry policy. Is my approach incorrect or too extreme for what I want to do. I would really appreciate if someone could give me guidance on this. Thanks Vee

    M 1 Reply Last reply
    0
    • E ekynox

      Hi Guys, As of a few days ago I started to venture into the world of SQL. Subsequently I have a question on best practices relating to data population of a win form component. For example, if you have a sql table which has a product column containing about 100 items. Now you want to pass these product items into a combo-box's drop down list ? What would be the best way of doing it ? At the moment, I can set the data source property of the combo-box directly to this table containing the product items column. However, the product item's column changes data changes say couple of items per hour then what would be a good best pratice of keeping the combo box's drop down list updated ? My idea would be to use data caching and apply a time expiry policy. Is my approach incorrect or too extreme for what I want to do. I would really appreciate if someone could give me guidance on this. Thanks Vee

      M Offline
      M Offline
      Mike Ellison
      wrote on last edited by
      #2

      Hi Vee. I think your expectation of production traffic would drive this question. In many of my apps for low to moderate traffic, I just use a live query at run-time to retrieve the dropDownList items without any caching. But if you found that performance suffered this way for your site, I don't think it's extreme at all to use caching - you could use the Application cache for this, or if you're using ASP.NET 2.0 you could use the new SqlCacheDependency class. Here's a link to an example[^].

      E 1 Reply Last reply
      0
      • M Mike Ellison

        Hi Vee. I think your expectation of production traffic would drive this question. In many of my apps for low to moderate traffic, I just use a live query at run-time to retrieve the dropDownList items without any caching. But if you found that performance suffered this way for your site, I don't think it's extreme at all to use caching - you could use the Application cache for this, or if you're using ASP.NET 2.0 you could use the new SqlCacheDependency class. Here's a link to an example[^].

        E Offline
        E Offline
        ekynox
        wrote on last edited by
        #3

        thanks for the reply Mike. In your reply you stated that the expectation of the production traffic would drive this question. In response to that statement what are the test procedures you undertake to model traffic conditions on your database.

        M 1 Reply Last reply
        0
        • E ekynox

          thanks for the reply Mike. In your reply you stated that the expectation of the production traffic would drive this question. In response to that statement what are the test procedures you undertake to model traffic conditions on your database.

          M Offline
          M Offline
          Mike Ellison
          wrote on last edited by
          #4

          Hi there. Well, if you are really concerned about it, you could acquire software tools to assist in testing your web sites at high loads. There are many commercially available (try Google for "web stress testing" and you'll find a bunch) So how many hits a day/hour/minute do you expect you'll get?

          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