In what ways can I use the DUP keyword in DDS for the IBMi?

TLDR

In what ways can I define DUP in a DDS file that I haven’t tried?

Note: I don’t care about the RPG to hook it up. I’m only looking at the Display File definition.

In a perfect world, someone out there knows exactly what I need to get the 0x06 keyword on a field when reading in the results of calling the QDFRTVFD api.

I’ll take any suggestions for DDS to try, particularly unusual ones.
At this point, I’m not sure if the api is bugged or the documentation is wrong, or if I’m just missing something.

Background:

I’m working on fixing a bug in a C++ class that calls the QDFRTVFD api ([https://www.ibm.com/docs/en/i/7.3?topic=ssw_ibm_i_73/apis/qdfrtvfd.html) from IBM and parses the returned buffer.
The bug was in a method that handles a particular category of keywords. Basically, we misunderstood the api documentation (or it is just plain wrong), and cast some of the keywords to the wrong size data structure, throwing off our pointer arithmetic.
I am now manually testing each keyword in the affected category to make sure that we’re using the correct data structure for each.
Here’s the list:

Category 22 (Miscellaneous Field-Level Keywords)

The following table shows the keyword ID that corresponds to miscellaneous field-level keywords. Not all keywords require a structure. There are no structures for keyword IDs X’01’, X’02’, X’03’, X’04’, X’05’, X’06’ and X’07’.

ID Keyword ID Keyword
0x01 PUTRETAIN 0x10 MSGID
0x02 OVRDTA 0x15 ERRMSG
0x03 OVRATR 0x16 ERRMSGID
0x04 BLANKS 0x17 DSPATR(PFLD)
0x05 CHANGE 0x18 DATTIMFMT
0x06 DUP 0x19 DATTIMSEP
0x07 DUP 0x1A DATE
0x1B MAPVAL

I have been able to generate all of the above keywords except for 0x06 DUP.
The documentation does not make it clear what the difference between 0x06 and 0x07 is. I can generate a 0x07 by defining the DUP keyword with a Response Indicator.
For example, this field definition gives me 3 category 22 keywords, 0x04, 0x05, and 0x07:

     A            FLD4           5A  B  4 30BLANKS(12) 
     A                                      DUP(04) 
     A                                      CHANGE(06) 

I thought that since some keywords take response indicators and some don’t, and because DUP can be defined with and without an indicator, that 0x07 must be DUP with an indicator and 0x06 must be DUP without an indicator. However, when I tried to define a field with DUP with no indicator, the result was no category 22 keyword at all.
For example, if I remove the (04) from the above example, I only get 2 category 22 keywords, not 3.

Here is my current test DDS source. It just defines a bunch of fields with various combinations of keywords. Most are from the above list, but there are some others there as well as I was testing other categories too.

     A                                      REF(SUBFILE3) 
     A                                      DSPSIZ(24 80 *DS3) 
     A                                      PRINT 
     A                                      INDARA 
     A                                      CA03(03 'F3=EXIT') 
     A          R SCRN                      OVERLAY 
     A            FLD1           5   B  3  2CHANGE(41) 
     A                                      PUTRETAIN 
     A  48                                  DSPATR(HI) 
     A                                  2 20'SOMETHING SOMETHING SOMETHING' 
     A                                      PUTRETAIN 
     A            FLD2          15   B  3 50 
     A                                      CHANGE(25) 
     A            FLD3           5Y 0B  4 10BLANKS(10) 
     A  49                                  DSPATR(RI) 
     A                                      CHANGE(15) 
     A                                      PUTRETAIN 
     A            FLD4           5A  B  4 30BLANKS(12) 
     A                                      DUP(04) 
     A                                      CHANGE(06) 
     A            FLD5           5   B  4 50COLOR(BLU) 
     A  50                                  DSPATR(RI) 
     A  51                                  DSPATR(PC) 
     A          R SCRN2                     PUTOVR 
     A            FLD6           6   B  5  2DFT('FOOBAR') 
     A                                      OVRDTA 
     A                                      CHANGE(03) 
     A                                      DUP(09 'comment') 
     A  20        FLD7           5   B  5 20DSPATR(BL) 
     A  21                                  DSPATR(RI) 
     A                                      OVRATR 
     A                                      OVRDTA 
     A                                      DFT('MEH!!') 
     A            FLD8          25   O  5 50MSGID(*NONE) 
     A            FLD9          25   B  6  2CHANGE(47) 
     A  60                                  ERRMSG('TEST1' 60) 
     A  66                                  ERRMSG('TEST2' 66) 
     A  63                                  ERRMSGID(MSG2000 TEST 63) 
     A            FLD10           L  B  7  2DATFMT(*JOB) 
     A                                      CHANGE(72) 
     A            FLD11           T  B  7 20TIMFMT(*EUR) 
     A                                      CHANGE(73) 
     A            FLD12           T  B  7 40TIMFMT(*HMS) TIMSEP('.') 
     A                                      CHANGE(81) 
     A            FLD13           L  B  7 60DATFMT(*DMY) DATSEP('-') 
     A                                      CHANGE(82) 
     A                                  8  2DATE(*SYS) 
     A                                  8 12DATE(*Y) 
     A            FLD14           L     8 24DATFMT(*MDY) DATSEP('/') 
     A                                      MAPVAL(('06/17/95' *BLANK)) 
     A            FLD15         10   B  9  5COLOR(BLU) 
     A  70                                  DSPATR(RI) 
     A  71                                  DSPATR(PC) 
     A                                      OVRDTA 
     A                                      DFT('My value') 
     A            FLD16          5Y 0B  9 25 
     A  65                                  DSPATR(HI) 
     A                                      DSPATR(&PFLD1) 
     A            PFLD1          1A  P 
     A            FLD17          3A  I 10  5DUP 

Some variations I have tried for defining DUP:

  1. As in FLD4 above, no option indicator but with a response indicator (result: 0x07)
  2. As in FLD17 above, no option indicator and no response indicator (result: no keyword)
  3. With an option indicator and a response indicator (result: 0x07)
  4. With an option indicator and no response indicator (result: no keyword)
  5. On a field in a subfile record with response indicator (result: 0x07)
  6. On a field in a subfile record, no response indicator (result: no keyword)
  7. The above fields are character fields. I also tried a numeric, which requires the response indicator (result: 0x07)

New contributor

Traagen is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.

Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa Dịch vụ tổ chức sự kiện 5 sao Thông tin về chúng tôi Dịch vụ sinh nhật bé trai Dịch vụ sinh nhật bé gái Sự kiện trọn gói Các tiết mục giải trí Dịch vụ bổ trợ Tiệc cưới sang trọng Dịch vụ khai trương Tư vấn tổ chức sự kiện Hình ảnh sự kiện Cập nhật tin tức Liên hệ ngay Thuê chú hề chuyên nghiệp Tiệc tất niên cho công ty Trang trí tiệc cuối năm Tiệc tất niên độc đáo Sinh nhật bé Hải Đăng Sinh nhật đáng yêu bé Khánh Vân Sinh nhật sang trọng Bích Ngân Tiệc sinh nhật bé Thanh Trang Dịch vụ ông già Noel Xiếc thú vui nhộn Biểu diễn xiếc quay đĩa Dịch vụ tổ chức tiệc uy tín Khám phá dịch vụ của chúng tôi Tiệc sinh nhật cho bé trai Trang trí tiệc cho bé gái Gói sự kiện chuyên nghiệp Chương trình giải trí hấp dẫn Dịch vụ hỗ trợ sự kiện Trang trí tiệc cưới đẹp Khởi đầu thành công với khai trương Chuyên gia tư vấn sự kiện Xem ảnh các sự kiện đẹp Tin mới về sự kiện Kết nối với đội ngũ chuyên gia Chú hề vui nhộn cho tiệc sinh nhật Ý tưởng tiệc cuối năm Tất niên độc đáo Trang trí tiệc hiện đại Tổ chức sinh nhật cho Hải Đăng Sinh nhật độc quyền Khánh Vân Phong cách tiệc Bích Ngân Trang trí tiệc bé Thanh Trang Thuê dịch vụ ông già Noel chuyên nghiệp Xem xiếc khỉ đặc sắc Xiếc quay đĩa thú vị
Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa
Thiết kế website Thiết kế website Thiết kế website Cách kháng tài khoản quảng cáo Mua bán Fanpage Facebook Dịch vụ SEO Tổ chức sinh nhật