• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Is idiot-proofing user input a requirement?

 
Ranch Hand
Posts: 81
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Ranchers,

Some people here have said that we should only do what the spec asks us to do, nothing more. That leads to my question:

Since my requirement spec says no where that I must implement any kind of input validation and further more says "Note that for this application, you should assume that customers and CSRs know their customer ids."

Will I lose points for lack of validation?

Should I prompt the user to retry or end the program on bad input?

Thanks in advance!
 
ranger
Posts: 17347
11
Mac IntelliJ IDE Spring
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Good questions, in which parts could they put in bad data. You don't need to worry about Customer ID, but it there any other areas.

The search shouldn't be an issue if you use JComboBoxes they will be filled with only valid data.

Mark
 
Sean Gildea
Ranch Hand
Posts: 81
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Mark,

Thanks for your reply,

In my search, users can specify a hotel name and/or location.

Should I validate correct text there?

Should I create a dialog box popup if incorrect and allow them to retry?
[ December 03, 2004: Message edited by: Sean Gildea ]
 
Ranch Hand
Posts: 64
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I did not put input validation on the hotelname/city box... if they enter a non-existent hotel name, the search simply yields 0 results (the search criteria and number of matching records are contiuously displayed in a statusbar).

The best way IMHO to put input validation on that dialog box is to make a list of all hotel names and all cities in the database, and put them both in JComboBoxes. That's friendlier to your users [than my approach] but more work to implement.
 
Barend Garvelink
Ranch Hand
Posts: 64
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Also, if you have the URLyBird assignment, keep in mind that the "Urlybird only takes reservations within 48 hours..." line in the intro text appears to be graded as a hard requirement (automatic failure) by some assessors, but not by others.
 
Mark Spritzler
ranger
Posts: 17347
11
Mac IntelliJ IDE Spring
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Sean Gildea:
Mark,

Thanks for your reply,

In my search, users can specify a hotel name and/or location.

Should I validate correct text there?

Should I create a dialog box popup if incorrect and allow them to retry?

[ December 03, 2004: Message edited by: Sean Gildea ]



You see with a JComboBox for these fileds, they can only select the values in the database, and therefore never put in bad data, since it is in the database. This is the most user friendly.

Mark
 
And then the flying monkeys attacked. My only defense was this tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic