Find('=<>')

nikeman77
Member Posts: 517
Hi,
anyone knows what symbol is it ?
Table: 554,
Name: Analysis by Dimensions
Functions: ValidateAnalysisViewCode()
If AnalysisView.Find('=<>')
anyone knows what symbol is it ?
Table: 554,
Name: Analysis by Dimensions
Functions: ValidateAnalysisViewCode()
If AnalysisView.Find('=<>')
0
Answers
-
from (a piece of) F1 help:= to search for a record that equals the key values (default)
> to search for a record that is larger than the key values
< to search for a record that is less than the key values
If this parameter contains '=', '>' or '<', then you must assign value to all fields of the current and primary keys before you call FIND.
in other words, the system will try to find one record as close as possible to the supplied key values.0 -
Belias wrote:from (a piece of) F1 help:Belias wrote:= to search for a record that equals the key values (default)
> to search for a record that is larger than the key values
< to search for a record that is less than the key values
If this parameter contains '=', '>' or '<', then you must assign value to all fields of the current and primary keys before you call FIND.Belias wrote:if you use that "Find('=<>')" the system will try to do the find with the "=", then with the "<" and then with the ">" parameter (i don't know if this actually fires 3 quereies to SQL :-k ).
in other words, the system will try to find one record as close as possible to the supplied key values.0 -
nikeman77 wrote:unfortunately, can't find themnikeman77 wrote:if its this case, it would be the same as If Record.Get("Primary Key1", "Primary Key2")Then
)
nikeman77 wrote:ok, thanks a lot, Belias...0 -
Belias wrote:enter in a codeunit, hit f1, search "find", fifth result.Belias wrote:NOPE, record.get don't care about filters on the record, and return false if the record si not exactly the one with the specified key values. (all this stuff is in the F1 help
)
Belias wrote:you're welcome0 -
Belias wrote:search the F1 help for "find" word...
there's not the help for Find('=<>') because it's just the compound of three statements: find=, find<, find>.
finally i get it... system will find for value equalvalent to, cant find will proceed to get the value smaller & nearest to the value, if still cant find then will find the next nearest bigger ones....
:whistle:0 -
belias,
it was clear no doubt about it, just my poor understanding0 -
nikeman77 wrote:Find('=<>')
Actually it should be FIND('=><');
But in any case the command makes sense only on Native database.
In SQL use either FINDFIRST, FINDSET or FIND('-') depending on what you are trying to do. If you are not sure then you can always use FIND('-');David Singleton0 -
actually, ->< is different than =>< ...
clear(mytable); mytable.mykeyfield1 := 1; mytable.mykeyfield1 := 'A'; mytable.find('-><'); //this will always find the first record in the table, if any mytable.find('=><'); //this will find record 1-A if existing, otherwise it will try to find 1-B and then 1-(blank) for example
also, '<' and '>' parameters for the find, has not a "substitute" on sql database...Ok, they're not used so frequently, but sometimes they're useful (e.g.: i used FIND('=<>') recently in RTC)0 -
Belias wrote:actually, ->< is different than =>< ...
Thanks for pointing out the typo.David Singleton0 -
David Singleton wrote:Thanks for pointing out the typo.
PS: i also edited my previous post while you were answering, i added something on '>' and '<'...in case you missed the edited post0 -
The only reason I could see for using find('=<>') would be for the visual effect of positioning the cursor on a form to replicate in code the default behavior in opening a form.David Singleton0
-
David Singleton wrote:The only reason I could see for using find('=<>') would be for the visual effect of positioning the cursor on a form to replicate in code the default behavior in opening a form.
i have a page that interfaces with unposted orders and journals coming from palm device. it is based on a temporary table and the user can post related documents/journals directly from this page. As it is a temporary table, as soon as a journal/document is posted, the table should be recalculated, and the cursor repositioned correctly (or the user gets lost every time he refreshes the temporary table).
NOTE(for completeness): i do not recalculate the table every time the user post something from it...he has to hit a "refresh" action.- here's the code.
//note: savedoldview and savedoldrecord must be temporary, otherwise the RESET instruction clears them SavedOldView := GETVIEW; SavedOldRecord := Rec; RESET; DELETEALL; FillTempTable; SETVIEW(SavedOldView); Rec := SavedOldRecord; IF FIND('=><') THEN;
0 -
Belias wrote:David Singleton wrote:The only reason I could see for using find('=<>') would be for the visual effect of positioning the cursor on a form to replicate in code the default behavior in opening a form.
IF FIND('=><') THEN;
but thats not the same is it? I thought default action in forms was that if the record does notexist then go to the record prior not the next one?David Singleton0 -
David Singleton wrote:
but thats not the same is it? I thought default action in forms was that if the record does notexist then go to the record prior not the next one?
Hmm just checked, and your are correct stadard form functionality is = > <
So I guess I can real ask my question, where would you ever use FIND('=<>'); ?David Singleton0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions