tuple9i
17th October 2005, 22:03
Hello, I am fairly new to BaaN. I am a Senior Oracle DBA who has started a new position that appears substantially heavier with the Application versus the RDBMS.
I am competent with shell scripting and very comfortable with command line scripting to get to the relevent information that I need to proactively manage my Database and Environment, but I am trying to also manage the BaaN without having to rely on the clumsy GUI.
I have followed threads regarding the BSHCMD, QPtool and BIC, but I have yet to determine how they will help and I have developed queries against the database for Job Performance and errors.
Also, I can't seem to find any pertinent information on the query structure of the BaaN 4GL scripting language. I am quite amazed at the paucity of information on the web regarding 4GL BaaN and am at a loss on where to go to get more information.
Any help would be greatly appreciated.
Thank you
BaaN Vc Porting set 7.1d.03
O/S Win2000 Server
Oracle 8.1.7.4
Brendan Shine
18th October 2005, 02:11
On our Unix systems we put the following Baan qptool query into a shell script called every hour via cron that checks to see if any jobs in a particular company are present with a status of "Waiting", "Canceled", "Runtime error", or "In Queue" and then if so an e-mail is generated notifying the appropriate person(s).
$BSE/bin/qptool6.1 -c$compnbr -q"select jsta, user, cjob, ttaad500.desc from ttaad500 where (jsta=2 or jsta=4 or jsta=5 or jsta=6)" >> $DIR/JobStatusTemp.txt 2>&1
# STATUS (jsta)
# 1=Free
# 2=Waiting
# 3=Running
# 4=Canceled
# 5=Runtime error
# 6=In queue
# 7=Blocked
# JOB NAME (cjob)
Brendan Shine
18th October 2005, 02:27
The bshcmd basically sends commands to the Baan bshell. You might use it to see what Baan session number a user is in and whether or not their bshell is getting any ticks (Baan to a great extent is structured like Unix--so you can think of $BSE/bin/bshcmd6.2 -p -s -u2 -w2 <bshell_unix_pid> as being similar to Unix command ps -ef). You can also turn on debugging so you can see what sql is being generated/used. Lastly, you can send a message to a particular user (i.e., "Please log out of the system for scheduled maintenance"). These are just a few examples.
In regards to qptool, I forgot to mention it is a read-only tool / you cannot update tables with it.
tuple9i
20th October 2005, 16:08
Thanks for the input. I have the jobs check running already - using a combination of KSH and BAT files to query the Oracle database for job status.
I am checking out the BSHCMD command.
Any more input is greatly appreciate, I am monitoring this thread.
Thanks again,
Tuple9i
Han Brinkman
21st October 2005, 15:37
You probably are already using SFU or cygwin since you stated that you use ksh and bat scripts.
You can indeed do a lot in scripts by querying the database directly. However be carefull if you delete/insert because baan uses it's own way of referencing between the records.
You can script the import/export of baan tables easily with the bdbpre/bdbpost commands. However on windoze it can only be done on the console because of the way how they implemented the shared memory stuff.
Guess you have to use bshcmd as well on the console.
The baan gui is probably not really windows but did you ever use Oracle Apps? I have to and you have to agree that Baan windows is more windows than Oracle Apps.
The licmon command can be used to determine who's using baan at the moment. Don't forget to schedule the cleanup option to remove 'haning' licenses.
Kind regards,
Han
tuple9i
30th October 2005, 23:36
Han, thanks for the input. yes, I have experience with Oracle Applications and I agree that BaaN is more "windows" the Oracle. That is also the problem ;-)
I have been making inroads with getting to the information via scripting by calling the sessions directly, so I guess all is going as fast as could be expected. I am using UWIN for the KSH emulator and it works fine for the most part, although I have found it appears to hang if not carefully tended. Probably something to do with my environment since I have used it at home with no problems for quite awhile.
The one problem I have with getting used to BaaN is that it doesn't appear to use any features of the Oracle database that can improve performance. My opinion is that the push for platform independence has reduced the ability to tune for an individual environment. Again, please remember that I am new to this application and will probably reform my opinion several times over the next few months.
Thanks for the reply. It really helps to have a board that is current and dynamic rather than just historical in nature.
Later,
tupl9i