Posts

Showing posts from December, 2015

Feedback/Suggestions on completion of this year

Image
Dear Professionals, I started writing this blog more than a year ago. The purpose of this blog was to help the people with day to day coding in WebFOCUS. I also use the codes for my reference as well. Whenever I put some effort to resolve a problem or find some solution, and I feel it could be used in future also either by myself or it can benefit to others, I share it on this blog. As we all know feedback is always a good motivation. I request all of you to please share your feedback/ suggestions on the same if you have any. If you want me to share on some specific topic or some common issue. Is it really helping you? If not? What else we can do to make it helpful? If you have something to share, send it to my mail id er.pravin007@gmail.com. I'll publish it over there with your name as presenter. I long run, this can become a place where you can find code for most of your day to day solutions. In last 6-8 months, I started liking WebFOCUS 8 version (initially I found it h

IBI WebFOCUS - Finding Run Time Stamp in A.M./P.M. format

Almost all reports (including WebFOCUS) usually need to show Report Run Date and Time. WebFOCUS provides us the variables &DATE and &TOD(system variables) to get system date and time and use it in our report without calculating anything in the procedure. However in some of the report we need to show time stamp in a.m./p.m. format. I have created the logic and I feel that sharing it might save some hours of development time for developers looking for such requirement. Below is the piece of code you can put in your procedure and you can use &TOD2 in your report header. -SET &M=''; -SET &H1 = EDIT(&TOD,'99'); -SET &H2 = IF &H1 GT 12 THEN &H1 - 12 ELSE &H1; -SET &M = IF &H1 GT 12 THEN ' PM' ELSE ' AM'; -SET &TOD2 = &H2 | EDIT(&TOD,'$$$:99$') | EDIT(&TOD,'$$$:$$$99') | &M; -TYPE &TOD -TYPE &TOD2 Please share your thoughts/ feedback's.  Happy coding