Results 1 to 5 of 5

Thread: Advice on creating recordset

  1. #1

    Thread Starter
    Software Carpenter dee-u's Avatar
    Join Date
    Feb 2005
    Location
    Pinas
    Posts
    11,127

    Arrow Advice on creating recordset

    In the technique of showing all the records that matches what is typed by a user in a search textbox or something what is more appropriate to use, create a recordset as the user types or create a recordset before the user types and just use a filtering?

    Thanks!
    Regards,


    As a gesture of gratitude please consider rating helpful posts. c",)

    Some stuffs: Mouse Hotkey | Compress file using SQL Server! | WPF - Rounded Combobox | WPF - Notify Icon and Balloon | NetVerser - a WPF chatting system

  2. #2
    I'm about to be a PowerPoster! mendhak's Avatar
    Join Date
    Feb 2002
    Location
    Ulaan Baator GooGoo: Frog
    Posts
    38,170

    Re: Advice on creating recordset

    Use filtering. Less calls and load on your poor server.

  3. #3
    Super Moderator si_the_geek's Avatar
    Join Date
    Jul 2002
    Location
    Bristol, UK
    Posts
    41,974

    Re: Advice on creating recordset

    It depends on several factors... such as how much data you have, which DBMS you are using, how much will be eliminated by the search conditions, how you want the program to work, and network issues.

    If lots of data will be eliminated by searching, the best bet (if using a 'proper' DBMS) will usually be to let the server do the work, as it is much more efficient than a client side filter.

    If you want to show updates as somebody types each letter, then a client side filter may be best as (hopefully) the filter will be clever enough to realise that only the data already shown needs to be searched.

    Returning a decent sized data set over a "slow" connection will not be very quick, and a filter is not as fast as a decent server (such as SQL Server) will do the same work. Even if the server is on the same LAN, returning lots of data will slow down other peoples network speeds - which may or may not be acceptable.

  4. #4

    Thread Starter
    Software Carpenter dee-u's Avatar
    Join Date
    Feb 2005
    Location
    Pinas
    Posts
    11,127

    Re: Advice on creating recordset

    Quote Originally Posted by si_the_geek
    It depends on several factors... such as how much data you have, which DBMS you are using, how much will be eliminated by the search conditions, how you want the program to work, and network issues.

    If lots of data will be eliminated by searching, the best bet (if using a 'proper' DBMS) will usually be to let the server do the work, as it is much more efficient than a client side filter.

    If you want to show updates as somebody types each letter, then a client side filter may be best as (hopefully) the filter will be clever enough to realise that only the data already shown needs to be searched.

    Returning a decent sized data set over a "slow" connection will not be very quick, and a filter is not as fast as a decent server (such as SQL Server) will do the same work. Even if the server is on the same LAN, returning lots of data will slow down other peoples network speeds - which may or may not be acceptable.
    I'm using SQL Server, does that mean creating a recordset at each typed character is just fine?
    Regards,


    As a gesture of gratitude please consider rating helpful posts. c",)

    Some stuffs: Mouse Hotkey | Compress file using SQL Server! | WPF - Rounded Combobox | WPF - Notify Icon and Balloon | NetVerser - a WPF chatting system

  5. #5
    Super Moderator si_the_geek's Avatar
    Join Date
    Jul 2002
    Location
    Bristol, UK
    Posts
    41,974

    Re: Advice on creating recordset

    If you are intending to update for each typed character then it is probably better to filter the recordset.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width