In criteriaFind I am planning to implement criterias for carrier, origin & destination. So restricting criteria search to these 3 fields is ok ? Since nothing specific asked in the requirement! Also instructions for UI says, "The user must be able to describe enter the string value "any" for the origin, destination, or both, so as to implement a wildcard-like feature. " So am i supposed to implement search like for airport, SFO, wildcard search is S* ?
Originally posted by Shivaji Bhosale: In criteriaFind I am planning to implement criterias for carrier, origin & destination. So restricting criteria search to these 3 fields is ok ?
No. Please distinguish between your database and the FBN application. You are specifically required to code the database for reuse. There can be no application dependencies in the database. This rules out restricting criteriaFind() to certain field names. It also rules out supporting the 'ANY' wildcard feature at the database level; that's a user interface thing. There is no requirement to support true wildcards. - Peter
hi, I've got a question about requirements too: a) what would you expect to see if criteriaFind("") is called with an empty String? All records, just as an empty SQL WHERE clause? b) the specs said field names must be matched (<field name>=<value to mach>) and an example is provided ("Carrier='SpeedyAir',Origin='SFO'" ). But the field names contain spaces, like "Origin airport", not just "Origin". So what do you think would be most appropriate? using the original field name including spaces? only the first part? use my own name for each field? or ???
Peter den Haan
posted 17 years ago
a) That's up to you to decide. Given the syntax you are asked to implement, you can make a case for interpreting this as "no criteria set". But you can also make a case for treating this as an illegal argument. I don't think there is a single "right" answer. b) At the database level the only names you can refer to are the field names from the disk file (remember: the re-use requirement implies that the database should be fully generic!) It doesn't really make a lot of sense to introduce aliases. And accepting partial field names introduces unnecessary complexity and ambiguity. - Peter
posted 17 years ago
So to conclude with criteriaFind, 1.Make your search for all the fields (which came along initially)in the Database. 2.In criteria, name must equal to the actual field name in the Database, in order to avoid aliasing field names should not put any complexity for re-use in further enhancements. 3.Wildcard search doesnt mean to be taken literally. Actually wild card search term in requirement is confusing. Is that right with what I understood ?
Time is the best teacher, but unfortunately, it kills all of its students - Robin Williams. tiny ad:
Download Free Java APIs to Work with Office Files and PDF