QTP 8.19C1 Bug???

Deskin, Bob Bob.Deskin@Cognos.COM
Fri, 29 Jan 1999 06:19:32 -0500


It looks like you got trapped with QTP timing. The initialization of values
will occur vefore you set your values in your temporary items. In effect we
do an initialization pass and then do a processing pass. The initialization
(ITEM INITIAL) will occur before you set the values in your temporary items
(TEMPORARY =). Matt Ohmes wrote a wonderful paper on this a number of years
ago. Also, if you try out the QTP Tracer (now available in 8.19), you should
see this processing in detail.

Another thing to keep in mind in situations with IMAGE is that QTP does deal
differently with IMAGE manual masters. In an effort to be a true 4GL and
take the load off of the programmer, we take into account the differences
between IMAGE manual masters and other indexed files. The main thing is that
since the master must exist before any associated detail, when you code an
ADD (at end of) we actually do an ADD (at start of) and an UPDATE (at end
of). This means that if you are calculating or changing your key value, you
may well get garbage.

But in this case, I think timing is the problem.

Bob Deskin              
Senior Product Advisor  bob.deskin@cognos.com
Cognos Inc.             (613) 738-1338 ext 4205 FAX: (613) 228-3149
3755 Riverside Drive P.O. Box 9707 Stn. T, Ottawa ON K1G 4K9 CANADA


> ----------
> From: 	John Pearce[SMTP:jpearce@rmi.net]
> Sent: 	January 29, 1999 12:36 AM
> To: 	powerh-l@lists.swau.edu
> Subject: 	QTP 8.19C1 Bug???
> 
> I have spent more hours trying to fix a QTP problem than I care to think
> about and now I believe the problem is a bug in 8.19C1 QTP.  Here's a
> snippet of the code.
> 
> access *sfgla
> 
> use convtu1  ; this is a file containing a case statement to convert GL
> acct numbers
>              ; it's USEd by six different pieces of QTP code.  convtu1
> looks like this-
>              ;   temporary t-old-acct char*12
>              ;   define t-new-acct char*12 = case of t-old-acct & 
>              ;     when "1210" then "10110" else &  etc.
> 
> temporary t-new-dept1 char*12
> temporary t-new-labor char*12
> 
> item t-old-acct = dept1 of sfgla
> item t-new-dept1 = t-new-acct
> item t-old-acct = labor of sfgla
> item t-new-labor = t-new-acct
> 
> output gla add
> item dept1 initial t-new-dept1
> item labor initial t-new-labor
> item pension initial "21151"
> 
> The code sample above has been used successfully to create detail sets and
> automatic masters.  However it does not work correctly with with manual
> masters.  In one production run, the output in GLA is literally scrambled
> garbage.  The GLA file has twelve records and the data is easily
> identified.  I have found parts of different records from the subfile
> combined into a single record in the manual master.  Another interesting
> point is that record #5 of the twelve records in GLA is ALWAYS blank.
> It's
> blank even if the input file is sorted.
> 
> The work around is to create a new subfile with the new data values, e.g.
> subfile sfnewgla keep include t-new-dept1, t-new-labor, etc. then run a
> separate request to read the subfile sfglanew and load the manual master
> file gla.
> 
> Obviously, at 10 pm MST I'm not planning to call Cognos support until
> tomorrow morning.  I'm curious if anyone has seen or knows about this
> problem.  I've revised the code for all the manual masters since the
> production conversion run will be done Friday.
> 
> Thanks.
> 
> ------------------------------------------------------------------
> John Pearce  <jpearce@rmi.net>       | Bethesda Management Company 
> Speaking for only myself             | Colorado Springs, CO  USA
> = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
> =
> Subscribe: "subscribe powerh-l" in message body to
> majordomo@lists.swau.edu
> Unsubscribe: "unsubscribe powerh-l" in message to majordomo@lists.swau.edu
> powerh-l@lists.swau.edu is gatewayed one-way to bit.listserv.powerh-l
> This list is closed, thus to post to the list, you must be a subscriber.
> 
= = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
Subscribe: "subscribe powerh-l" in message body to majordomo@lists.swau.edu
Unsubscribe: "unsubscribe powerh-l" in message to majordomo@lists.swau.edu
powerh-l@lists.swau.edu is gatewayed one-way to bit.listserv.powerh-l
This list is closed, thus to post to the list, you must be a subscriber.