Record sequence numbers in QTP

Joe Boyle atla38 at dsl.pipex.com
Fri Jun 8 10:56:03 CDT 2007


You could always run a second pass which updates the subfile along the lines
below,

 

Acc * odscust

 

Temp t-num int*10

Item t-num = t-num + 1 

Define d-final char*522 = d-cust[1:4] + ascii( t-num,10) + d-cust[5:507]

 

Output odscust update

Item cust final d-final

 

  _____  

From: powerh-l-bounces+atla38=dsl.pipex.com at lists.sowder.com
[mailto:powerh-l-bounces+atla38=dsl.pipex.com at lists.sowder.com] On Behalf Of
Robert Mills
Sent: 08 June 2007 16:20
To: powerh-l at lists.sowder.com
Subject: Record sequence numbers in QTP

 

Greetings to the -L,

 

Environment: QTP 8.49.D1 on MPE/iX 6.5

 

I have a program (see extract below) where for each record read I write two
records (a customer and a customer address) to a subfile. When it has
processed the last input record it writes a trailer record to the subfile.
Each record written to the subfile needs a sequence number.

 

My problem is that each cust/addr record pair has the same sequence number.
The tlr record has the same sequence number as the last cust/addr pair.

 

Any suggestions on how to correct this?

 

 

access custmstr

 

temporary t-seq

item t-seq count

 

define d-seq character *6 = ascii(t-seq,6)

define d-cust character *512 = "CUST" + d-seq + ...

define d-addr character *512 = "ADDR" + d-seq + ...

define d-tlr character *512 = "TLR" + d-seq + ...

 

subfile odscust alias cust keep include d-cust

subfile odscust alias addr keep include d-addr

subfile odscust alias tlr at final keep include d-tlr

regards, 
  
Robert W.Mills 
Systems Development Manager 
Pinnacle Arvato 
(020) 8309 3604 

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.sowder.com/pipermail/powerh-l/attachments/20070608/d0576e7d/attachment.htm


More information about the powerh-l mailing list