• 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

NX: GUI and Search

 
Ranch Hand
Posts: 103
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
"It must allow the user to search the data for all records,..."
Does this mean that not only should the user be able to search the name and/or location fields but also be able to list all records which aren't deleted? If so, would there be a button for list all records?
 
Ranch Hand
Posts: 146
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
If you leave the search empty its supposed to return all the live records. So just have your app logic check if the search criteria is empty or null and if it is then retrieve all the records and return them to the user.
Regards,
Dave
 
joe black
Ranch Hand
Posts: 103
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
What's the point of returning all records if the user doesnt type anything? Any other search engine wouldn't return any results...
 
Ranch Hand
Posts: 619
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I guess the consensus interpretation of "search all the records" is that the user should be able to see all the records by default. The search then behaves like a filter. Normally the user sees everything, they don't really have to search for anything, they can just scroll down the list of records. The search is just a way for them to display only those records that are of interest to them. Anyway, that's what I did.
If you accept that the user might want to actually see all the records, what would you have the user do? Would they have to type "all" in each of the search fields? If the user sees all the records by default then it's not an issue. Maybe I misunderstood your point.
- George
 
joe black
Ranch Hand
Posts: 103
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Does your GUI display all the records on startup?
 
George Marinkovich
Ranch Hand
Posts: 619
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Yes, when the client comes up for the first time they're all there in the JTable.
 
joe black
Ranch Hand
Posts: 103
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
OK if all the records are there for the client on startup then it makes sense. Thanks George.
 
Ranch Hand
Posts: 75
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
George, which are the fields that you have implemented search for? I have the contractor project.
Currently, I have implemented the search for all 6 fields , maybe that was a bit much...

Originally posted by George Marinkovich:
Yes, when the client comes up for the first time they're all there in the JTable.

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

Originally posted by Sanjay Joshi:
Currently, I have implemented the search for all 6 fields , maybe that was a bit much...


I did as well, and yes, now I think that was too much. I took a very liberal interpretation of the assignment instructions. So, if the assignment instructions said name and location must be searchable, I decided to make all the fields in the database searchable. I now realize these were not very intelligent decisions. My current thinking on what is in the scope of the project and what isn't is heavily influenced by this thread:
Topic: How long should the project take?
Now if you're happy with your implementation of all six search fields, I wouldn't bother to remove the extra fields (that is, fields other than name and location). You've already done the work. I don't think you will lose (or gain) any points by doing what you did. The grader may wonder, however, why you chose to provide six search fields, when they only asked for two. There are lots of such areas where had I taken a more conservative interpretation of the requirements I could have saved an immense amount of time and effort. Oh well, live and learn. Suffice to say I now have a very different opionion of the candidates who said that it took them 2-3 weeks to finish the project. They were right, I was wrong.
Hope this helps,
George
reply
    Bookmark Topic Watch Topic
  • New Topic