Results 1 to 3 of 3

Thread: Postcodes and Timeouts

  1. #1

    Thread Starter
    Hyperactive Member parkes's Avatar
    Join Date
    Jan 1999
    Location
    Unitied Kingdom
    Posts
    303

    Question Postcodes and Timeouts

    Does anyone have an example of how to create an SQL statement that deals with Postcodes and using ASP. I need to be able to query my database via postcodes, but the trouble I want people to be able to enter something like
    BETWEEN 'NE1' AND 'TS15', I don't get the right results and I've tried several ways.

    Also what is the best way to stop a session timing out. I need to keep the session going till the user closes the browser.
    Thanks in advance for any help provided.

    VB 6 Enterprise Edition SP4
    ADO, SQL 7/2000, ASP and some JavaScript


    >> Life goes on, but for how long? <<
    If you can smile when things go wrong, you have someone in mind to blame

  2. #2
    Black Cat JoshT's Avatar
    Join Date
    Nov 2000
    Location
    WNY, USA
    Posts
    4,032
    1. Try SQL like "... WHERE CODE > 'NE1' AND CODE < 'TS15'" -- It works for Last Names on a SQL Server 2000 db I have.

    2. Well, ASP has no way of knowing when the browser closes, but you could have them keep opening pages - you could use a frameset, and have one of the frames refresh every few minutes.
    Josh
    Get these: Mozilla Opera OpenBSD
    I have books for sale: "MCSD in a Nutshell" and "VB Distributed Exam Cram" - PM me for details. Will also trade for a decent ATX Pentium 2 MB/CPU/RAM combo.

  3. #3

    Thread Starter
    Hyperactive Member parkes's Avatar
    Join Date
    Jan 1999
    Location
    Unitied Kingdom
    Posts
    303
    Thanks I've tried that, but since there are number in the postcodes it doesn't return true results

    Example

    >='Ne1' AND <='TS3'

    Returns things like TS16, TS17, etc
    Thanks in advance for any help provided.

    VB 6 Enterprise Edition SP4
    ADO, SQL 7/2000, ASP and some JavaScript


    >> Life goes on, but for how long? <<
    If you can smile when things go wrong, you have someone in mind to blame

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