260 likes | 271 Views
Explore intricate formatting functions and specialized features in Chuck’s Academy Part 2 webinar. Learn to format text, dates, phone numbers, and more. Discover cool functions like Age, Whazzis, and Justdoit for advanced data manipulation.
E N D
Chuck’s AcademyofFunction Anatomy Part 2 An ACEware Webinar
Function Academy – Part 2 • Formatting Functions • Function Categories • Especially Cool! • Advanced and Specialized
Formatting Functions NAMER – formats name namer(rgid);nmfirm;nmaddr1;nmaddr2;nmcity,nmstate,nmzip
Formatting Functions NICEDATE – formats date nicedate(cobegdate,coenddate) nicedate(cobegdate,coenddate,3)
Formatting Functions SHOWPHON – formats phone number showphon(indphone,"Day: ");showphon(inhphone,"Eve: ")
Formatting Functions CSZR – concatenates city, state and zip (frequently combined with other functions) namer(nmid);nmtitle;nmaddr1;nmaddr2;cszr(nmid);nmcntry
Especially cool! AGE– Calculates the number of years between two dates AGE(nmbirth)
Especially cool! GETDATA – Opens a message box in which you can enter a temporary message to be used in a report. (Used in a JUSTDOIT) Required Parameters: Character title expression (i.e. text that will display at the top of the message box) Input variable. Variable can be a date, (e.g. ctod('//') ), a number (e.g. 0.00), or character. If character, use the SPACE() function to specify desired length (i.e. SPACE(50) creates a data entry field 50 characters in length). Note: if you wish to enter a large text block (i.e. a memo), enter a space value 251- SPACE(251). This will let you enter large blocks of text in a scrolling data window.
Especially cool! GETDATA (continued)
Especially cool! JUSTDOIT with GetData Function GetData Function
Especially cool! WHAZZIS – Displays query used on report whazzis(.t.) Optional Parameters: "A" = Query Name, Query Field and Query Value "Q" = Query Name Only "V" = Query Value Only "QV" = Query Name and Value "+" = Query Name and Report Name "++" = Query Name, Report Name and Report Title
Especially cool! QuikCode – shows code description (instead of code) iif(empt(rgtrack),'NO CODE',quikcode(RGTRACK))
Chuck’s Favorites Sometimes we have to humour the boss!
SHOWEXP SHOWEXP Don’t forget to add your formatting!
ADDOMNI When it absolutely, positively has to be there! Returns any field from any table in the system (key value must be in cursor). Required Parameters: Table you want to return a field from in quotes (i.e. "NAMES", "COURSE", "REGISTER") Key from above table in quotes (i.e. "nmid" or "nmid+rgcrse") Key from report cursor, NO quotes (i.e. nmid or nmid+cocrse) Field from specified table to return (i.e. "nmsalut", "cosubcode", "rggrade")
FINDINST FINDINST can display more than a name! 1= Name and SSN 2= Name only 3= Name, day phone, and eve phone 4= Name-Last Name, First Name 5= Name and Address in block form 6= Name, Address and Phone #'s in block form 7= Name and user defined char string (enter char string as parameter 3) 8= Name, SSN, and Pay description
Justdoit JUSTDOIT is a specialized report function that uses SQL to request and manipulate information from the data tables. What can a JUSTDOIT do? • change the sort order of data in a report • filter out unwanted data • execute specialized report functions • gradspec • getdata
Writing a Justdoit All JUSTDOIT’s that change the output order, eliminate duplicates or filter begin the same: justdoit(‘select *,0 as marker from (cursor5) And continue with Order, Group, or Where
Writing a Justdoit And finishes with . . . Into cursor (cursor?) Tells the system to place the data back into the cursor once it has finished executing all the select statements,
Justdoit Examples Change the Sort Order of Report with "Order By" Statement justdoit(‘select *,0 as marker from (cursor5) order by nmname3,nmname1 into cursor(cursor5)’) Eliminating Duplicate records with the "Group By" Statement JUSTDOIT(‘select *,0 as marker from (cursor5) group by nmid,nmname3 into cursor(cursor5)’) Filter the report with "Where" Statement JUSTDOIT(‘select *,0 as marker from (cursor5) where due-paid>0.00 into cursor(cursor5)’)
Justdoit The JUSTDOIT expression box may be placed anywhere on the report template butwe recommend placing it in the header band of the report. It's a non-printing element and will not display on the report itself.
Adding a field with a JUSTDOIT Add a field to the Cursor and then Sort by it JUSTDOIT(‘select *,addcrse(cocrse,"cobegdate") as date, 0 as marker from (cursor5) order by date into cursor(cursor5)’) Use the ADDCRSE function & add “as date” which identifies the new field for the cursor and continue with the justdoit
Additional Help A plethora of additional information on all functions is available in the online help or . . . Call your tech!
Our next webinar . . . Wednesday, June 30th 1:00 Central When we unveil the all new 7.2!