DB12 Pick An Index Any Index Michael Lonski
DB-12 - Pick An Index, Any Index… Michael Lonski Allegro Consultants, LTD. www. allegroconsultants. com
What’s Next… v Prepare www. allegroconsultants. com
Who I Am… v Started working with Progress® v 3 (1986) v Founded Allegro Consultants in 1993 v Internationally recognized speaker v Author of “Coding Smart” book on ADM 2 v Punster and Frequent Talker www. allegroconsultants. com
…And Why I Am Here v Overview index rules v Practical tools, not bookish theory v Focus on fact, not guesswork v Compile time information v Run-time information v Show off skill at alliteration www. allegroconsultants. com
What’s Next… v Prepare v Predict www. allegroconsultants. com
Hierarchy For A Single Index 1. Unique index with all components 2. 3. 4. 5. 6. involved in the equality matches Most active range matches Most active sort matches First index alphabetically by index name The primary index www. allegroconsultants. com
Multiple Index Usage v If indexes are available for both sides of WHERE. . . AND/OR, more than one index can be used v Multiple indexes will *only* be used to assist in bracketing records www. allegroconsultants. com
WHERE…AND… v WHERE clause includes the use of AND v All components of each index are involved in equality matches v No unique indexes are involved www. allegroconsultants. com
WHERE…OR… v WHERE clause includes the use of OR v Both the left and right side of the OR contain at least the lead component of an index v These lead components are involved in either equality or range matches www. allegroconsultants. com
What’s Next… v Prepare v Predict v Prevent www. allegroconsultants. com
Breaking The Rules USE-INDEX … FIND … WHERE ROWID ( ) = … www. allegroconsultants. com
Breaking The Index WHERE NOT … WHERE Family. Covered. On. Benefits WHERE … MATCHES … WHERE IF … THEN … = vc. Input WHERE SUBSTRING (…) = “A” ELSE TRUE www. allegroconsultants. com
What’s Next… v Prepare v Predict v Prevent v Plan www. allegroconsultants. com
XREF Information COMPILE prog. p XREF prog. xref FOR EACH FIND www. allegroconsultants. com
Demo – XREF-demo. p www. allegroconsultants. com
XREF Information COMPILE prog. p XREF prog. xref CREATE DEFINE Query www. allegroconsultants. com
Demo – Query-demo. p www. allegroconsultants. com
What’s Next… v Prepare v Predict v Prevent v Plan v Prove www. allegroconsultants. com
If A Query Could Talk… What did I use? Did I error? qry. Cust Did I bracket? www. allegroconsultants. com
How To Ask DEFINE VARIABLE vh. Qry. Cust AS HANDLE CREATE QUERY vh. Qry. Cust DEFINE QUERY q. Cust: qry. Cust vh. Qry. Cust = QUERY q. Cust: HANDLE www. allegroconsultants. com
What to Ask What did I use? vh. Qry: INDEX-INFORMATION() Did I error? ERROR-STATUS: NUM-MESSAGES Did I bracket? qry. Cust ENTRY(1, vh. Qry: I-I) = “WHOLEINDEX” www. allegroconsultants. com
Demo – w. Query. Test. w www. allegroconsultants. com
What’s Next… v Prepare v Predict v Prevent v Plan v Prove v Process www. allegroconsultants. com
Open. Edge™ 10 – Log Manager v New features in Open. Edge 10 v Both command-line and run-time controls v Highly configurable www. allegroconsultants. com
Log Manager Controls Command Line LOG-MANAGER v -clientlog v : LOGFILE -NAME v -logentrytypes v : LOG-ENTRY-TYPES v -logginglevel v : LOGGING-LEVEL v -numlogfiles v : NUM-LOG-FILES v -logthreshold v : LOG-THRESHOLD www. allegroconsultants. com
Demo – Logging-demo. p www. allegroconsultants. com
Now that I’ve rambled on, are there any questions? www. allegroconsultants. com
Thanks for attending… www. allegroconsultants. com
- Slides: 28