| Author |
criteriaFind Questions?
|
seagullz peizhi
Greenhorn
Joined: Jun 05, 2002
Posts: 13
|
|
in criteriaFind() it takes in a String "Carrier='SpeedyAir',Origin='SFO'",and we split them as what we want,but when i compare the field name as the db's field name,you know they arenot exactly same, like "Orgin" as "Orgin airport",so it's wrong with the method getName(),i want to change the criteriastring as "Carrier='SpeedyAir',Origin airport='SFO'",am i right? maybe it is a simple question,but any help is precious to me 3ks
|
i am a beginner ,thank you
|
 |
Michael Morris
Ranch Hand
Joined: Jan 30, 2002
Posts: 3451
|
|
Hi Seagullz, Yep, the field names have to match. What I did was create an interface called FBNConstants which contained an array of the field names and int constants like ORIGIN, DESTINATION, DURATION, etc. So I would just build my criteria using those constants, for example SCHEMA[CARRIER] would then be the exact field name for carrier. Hope this helps, Michael Morris
|
Any intelligent fool can make things bigger, more complex, and more violent. It takes a touch of genius - and a lot of courage - to move in the opposite direction. - Ernst F. Schumacher
|
 |
seagullz peizhi
Greenhorn
Joined: Jun 05, 2002
Posts: 13
|
|
|
thank you very much
|
 |
 |
|
|
subject: criteriaFind Questions?
|
|
|