d-debums.w 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508
  1. &ANALYZE-SUSPEND _VERSION-NUMBER AB_v10r12 GUI ADM2
  2. &ANALYZE-RESUME
  3. /* Connected Databases
  4. anadat PROGRESS
  5. */
  6. &Scoped-define WINDOW-NAME CURRENT-WINDOW
  7. {adecomm/appserv.i}
  8. &ANALYZE-SUSPEND _UIB-CODE-BLOCK _CUSTOM _DEFINITIONS dTables
  9. /*------------------------------------------------------------------------
  10. File:
  11. Description: from DATA.W - Template For SmartData objects in the ADM
  12. Input Parameters:
  13. <none>
  14. Output Parameters:
  15. <none>
  16. Modified: February 24, 1999
  17. ------------------------------------------------------------------------*/
  18. /* This .W file was created with the Progress AppBuilder. */
  19. /*----------------------------------------------------------------------*/
  20. /* Create an unnamed pool to store all the widgets created
  21. by this procedure. This is a good default which assures
  22. that this procedure's triggers and internal procedures
  23. will execute in this procedure's storage, and that proper
  24. cleanup will occur on deletion of the procedure. */
  25. CREATE WIDGET-POOL.
  26. /* *************************** Definitions ************************** */
  27. /* Parameters Definitions --- */
  28. /* Local Variable Definitions --- */
  29. &SCOPED-DEFINE Tabelle DebUms
  30. /* &SCOPED-DEFINE TabWhere USE-INDEX DebUms-k1 ~ */
  31. /* WHERE {&Tabelle}.Firma = tRowObject.Firma ~ */
  32. /* AND {&Tabelle}.Aufnr = tRowObject.Aufnr */
  33. { incl/datdefinition.i }
  34. /* _UIB-CODE-BLOCK-END */
  35. &ANALYZE-RESUME
  36. &ANALYZE-SUSPEND _UIB-PREPROCESSOR-BLOCK
  37. /* ******************** Preprocessor Definitions ******************** */
  38. &Scoped-define PROCEDURE-TYPE SmartDataObject
  39. &Scoped-define DB-AWARE yes
  40. &Scoped-define ADM-SUPPORTED-LINKS Data-Source,Data-Target,Navigation-Target,Update-Target,Commit-Target,Filter-Target
  41. /* Db-Required definitions. */
  42. &IF DEFINED(DB-REQUIRED) = 0 &THEN
  43. &GLOBAL-DEFINE DB-REQUIRED TRUE
  44. &ENDIF
  45. &GLOBAL-DEFINE DB-REQUIRED-START &IF {&DB-REQUIRED} &THEN
  46. &GLOBAL-DEFINE DB-REQUIRED-END &ENDIF
  47. &Scoped-define QUERY-NAME Query-Main
  48. /* Internal Tables (found by Frame, Query & Browse Queries) */
  49. &Scoped-define INTERNAL-TABLES DebUms
  50. /* Definitions for QUERY Query-Main */
  51. &Scoped-Define ENABLED-FIELDS Firma Knr Jahr Ums_Grp Umsatzgrp Me_Mon1 Me_Mon2 Me_Mon3 Me_Mon4 Me_Mon5~
  52. Me_Mon6 Me_Mon7 Me_Mon8 Me_Mon9 Me_Mon10 Me_Mon11 Me_Mon12 Ep_Mon1 Ep_Mon2~
  53. Ep_Mon3 Ep_Mon4 Ep_Mon5 Ep_Mon6 Ep_Mon7 Ep_Mon8 Ep_Mon9 Ep_Mon10 Ep_Mon11~
  54. Ep_Mon12 Vp_Mon1 Vp_Mon2 Vp_Mon3 Vp_Mon4 Vp_Mon5 Vp_Mon6 Vp_Mon7 Vp_Mon8~
  55. Vp_Mon9 Vp_Mon10 Vp_Mon11 Vp_Mon12 Me_Kum Ep_Kum Vp_Kum Marge
  56. &Scoped-define ENABLED-FIELDS-IN-DebUms Firma Knr Jahr Ums_Grp Me_Mon1 ~
  57. Me_Mon2 Me_Mon3 Me_Mon4 Me_Mon5 Me_Mon6 Me_Mon7 Me_Mon8 Me_Mon9 Me_Mon10 ~
  58. Me_Mon11 Me_Mon12 Ep_Mon1 Ep_Mon2 Ep_Mon3 Ep_Mon4 Ep_Mon5 Ep_Mon6 Ep_Mon7 ~
  59. Ep_Mon8 Ep_Mon9 Ep_Mon10 Ep_Mon11 Ep_Mon12 Vp_Mon1 Vp_Mon2 Vp_Mon3 Vp_Mon4 ~
  60. Vp_Mon5 Vp_Mon6 Vp_Mon7 Vp_Mon8 Vp_Mon9 Vp_Mon10 Vp_Mon11 Vp_Mon12 Me_Kum ~
  61. Ep_Kum Vp_Kum
  62. &Scoped-Define DATA-FIELDS Firma Knr Jahr Ums_Grp Umsatzgrp Me_Mon1 Me_Mon2 Me_Mon3 Me_Mon4 Me_Mon5~
  63. Me_Mon6 Me_Mon7 Me_Mon8 Me_Mon9 Me_Mon10 Me_Mon11 Me_Mon12 Ep_Mon1 Ep_Mon2~
  64. Ep_Mon3 Ep_Mon4 Ep_Mon5 Ep_Mon6 Ep_Mon7 Ep_Mon8 Ep_Mon9 Ep_Mon10 Ep_Mon11~
  65. Ep_Mon12 Vp_Mon1 Vp_Mon2 Vp_Mon3 Vp_Mon4 Vp_Mon5 Vp_Mon6 Vp_Mon7 Vp_Mon8~
  66. Vp_Mon9 Vp_Mon10 Vp_Mon11 Vp_Mon12 Me_Kum Ep_Kum Vp_Kum Marge
  67. &Scoped-define DATA-FIELDS-IN-DebUms Firma Knr Jahr Ums_Grp Me_Mon1 Me_Mon2 ~
  68. Me_Mon3 Me_Mon4 Me_Mon5 Me_Mon6 Me_Mon7 Me_Mon8 Me_Mon9 Me_Mon10 Me_Mon11 ~
  69. Me_Mon12 Ep_Mon1 Ep_Mon2 Ep_Mon3 Ep_Mon4 Ep_Mon5 Ep_Mon6 Ep_Mon7 Ep_Mon8 ~
  70. Ep_Mon9 Ep_Mon10 Ep_Mon11 Ep_Mon12 Vp_Mon1 Vp_Mon2 Vp_Mon3 Vp_Mon4 Vp_Mon5 ~
  71. Vp_Mon6 Vp_Mon7 Vp_Mon8 Vp_Mon9 Vp_Mon10 Vp_Mon11 Vp_Mon12 Me_Kum Ep_Kum ~
  72. Vp_Kum
  73. &Scoped-Define MANDATORY-FIELDS Firma Knr
  74. &Scoped-Define APPLICATION-SERVICE
  75. &Scoped-Define ASSIGN-LIST rowObject.Me_Mon1 = DebUms.Me_Mon[1] rowObject.Me_Mon2 = DebUms.Me_Mon[2]~
  76. rowObject.Me_Mon3 = DebUms.Me_Mon[3] rowObject.Me_Mon4 = DebUms.Me_Mon[4]~
  77. rowObject.Me_Mon5 = DebUms.Me_Mon[5] rowObject.Me_Mon6 = DebUms.Me_Mon[6]~
  78. rowObject.Me_Mon7 = DebUms.Me_Mon[7] rowObject.Me_Mon8 = DebUms.Me_Mon[8]~
  79. rowObject.Me_Mon9 = DebUms.Me_Mon[9]~
  80. rowObject.Me_Mon10 = DebUms.Me_Mon[10]~
  81. rowObject.Me_Mon11 = DebUms.Me_Mon[11]~
  82. rowObject.Me_Mon12 = DebUms.Me_Mon[12]~
  83. rowObject.Ep_Mon1 = DebUms.Ep_Mon[1] rowObject.Ep_Mon2 = DebUms.Ep_Mon[2]~
  84. rowObject.Ep_Mon3 = DebUms.Ep_Mon[3] rowObject.Ep_Mon4 = DebUms.Ep_Mon[4]~
  85. rowObject.Ep_Mon5 = DebUms.Ep_Mon[5] rowObject.Ep_Mon6 = DebUms.Ep_Mon[6]~
  86. rowObject.Ep_Mon7 = DebUms.Ep_Mon[7] rowObject.Ep_Mon8 = DebUms.Ep_Mon[8]~
  87. rowObject.Ep_Mon9 = DebUms.Ep_Mon[9]~
  88. rowObject.Ep_Mon10 = DebUms.Ep_Mon[10]~
  89. rowObject.Ep_Mon11 = DebUms.Ep_Mon[11]~
  90. rowObject.Ep_Mon12 = DebUms.Ep_Mon[12]~
  91. rowObject.Vp_Mon1 = DebUms.Vp_Mon[1] rowObject.Vp_Mon2 = DebUms.Vp_Mon[2]~
  92. rowObject.Vp_Mon3 = DebUms.Vp_Mon[3] rowObject.Vp_Mon4 = DebUms.Vp_Mon[4]~
  93. rowObject.Vp_Mon5 = DebUms.Vp_Mon[5] rowObject.Vp_Mon6 = DebUms.Vp_Mon[6]~
  94. rowObject.Vp_Mon7 = DebUms.Vp_Mon[7] rowObject.Vp_Mon8 = DebUms.Vp_Mon[8]~
  95. rowObject.Vp_Mon9 = DebUms.Vp_Mon[9]~
  96. rowObject.Vp_Mon10 = DebUms.Vp_Mon[10]~
  97. rowObject.Vp_Mon11 = DebUms.Vp_Mon[11]~
  98. rowObject.Vp_Mon12 = DebUms.Vp_Mon[12]
  99. &Scoped-Define DATA-FIELD-DEFS "d-debums.i"
  100. &Scoped-define QUERY-STRING-Query-Main FOR EACH DebUms NO-LOCK ~
  101. BY DebUms.Jahr DESCENDING INDEXED-REPOSITION
  102. {&DB-REQUIRED-START}
  103. &Scoped-define OPEN-QUERY-Query-Main OPEN QUERY Query-Main FOR EACH DebUms NO-LOCK ~
  104. BY DebUms.Jahr DESCENDING INDEXED-REPOSITION.
  105. {&DB-REQUIRED-END}
  106. &Scoped-define TABLES-IN-QUERY-Query-Main DebUms
  107. &Scoped-define FIRST-TABLE-IN-QUERY-Query-Main DebUms
  108. /* Custom List Definitions */
  109. /* List-1,List-2,List-3,List-4,List-5,List-6 */
  110. /* _UIB-PREPROCESSOR-BLOCK-END */
  111. &ANALYZE-RESUME
  112. /* ************************ Function Prototypes ********************** */
  113. {&DB-REQUIRED-START}
  114. &ANALYZE-SUSPEND _UIB-CODE-BLOCK _FUNCTION-FORWARD getCurrentRecid dTables _DB-REQUIRED
  115. FUNCTION getCurrentRecid RETURNS RECID
  116. ( /* parameter-definitions */ ) FORWARD.
  117. /* _UIB-CODE-BLOCK-END */
  118. &ANALYZE-RESUME
  119. {&DB-REQUIRED-END}
  120. {&DB-REQUIRED-START}
  121. &ANALYZE-SUSPEND _UIB-CODE-BLOCK _FUNCTION-FORWARD openQuery dTables _DB-REQUIRED
  122. FUNCTION openQuery RETURNS LOGICAL
  123. ( /* parameter-definitions */ ) FORWARD.
  124. /* _UIB-CODE-BLOCK-END */
  125. &ANALYZE-RESUME
  126. {&DB-REQUIRED-END}
  127. /* *********************** Control Definitions ********************** */
  128. {&DB-REQUIRED-START}
  129. /* Query definitions */
  130. &ANALYZE-SUSPEND
  131. DEFINE QUERY Query-Main FOR
  132. DebUms SCROLLING.
  133. &ANALYZE-RESUME
  134. {&DB-REQUIRED-END}
  135. /* ************************ Frame Definitions *********************** */
  136. /* *********************** Procedure Settings ************************ */
  137. &ANALYZE-SUSPEND _PROCEDURE-SETTINGS
  138. /* Settings for THIS-PROCEDURE
  139. Type: SmartDataObject
  140. Allow: Query
  141. Frames: 0
  142. Add Fields to: Neither
  143. Other Settings: PERSISTENT-ONLY COMPILE APPSERVER DB-AWARE
  144. */
  145. /* This procedure should always be RUN PERSISTENT. Report the error, */
  146. /* then cleanup and return. */
  147. IF NOT THIS-PROCEDURE:PERSISTENT THEN DO:
  148. MESSAGE "{&FILE-NAME} should only be RUN PERSISTENT.":U
  149. VIEW-AS ALERT-BOX ERROR BUTTONS OK.
  150. RETURN.
  151. END.
  152. &ANALYZE-RESUME _END-PROCEDURE-SETTINGS
  153. /* ************************* Create Window ************************** */
  154. &ANALYZE-SUSPEND _CREATE-WINDOW
  155. /* DESIGN Window definition (used by the UIB)
  156. CREATE WINDOW dTables ASSIGN
  157. HEIGHT = 3.91
  158. WIDTH = 98.2.
  159. /* END WINDOW DEFINITION */
  160. */
  161. &ANALYZE-RESUME
  162. &ANALYZE-SUSPEND _UIB-CODE-BLOCK _CUSTOM _INCLUDED-LIB dTables
  163. /* ************************* Included-Libraries *********************** */
  164. {src/adm2/data.i}
  165. /* _UIB-CODE-BLOCK-END */
  166. &ANALYZE-RESUME
  167. /* *********** Runtime Attributes and AppBuilder Settings *********** */
  168. &ANALYZE-SUSPEND _RUN-TIME-ATTRIBUTES
  169. /* SETTINGS FOR WINDOW dTables
  170. VISIBLE,,RUN-PERSISTENT */
  171. /* _RUN-TIME-ATTRIBUTES-END */
  172. &ANALYZE-RESUME
  173. /* Setting information for Queries and Browse Widgets fields */
  174. &ANALYZE-SUSPEND _QUERY-BLOCK QUERY Query-Main
  175. /* Query rebuild information for SmartDataObject Query-Main
  176. _TblList = "AnaDat.DebUms"
  177. _Options = "NO-LOCK INDEXED-REPOSITION"
  178. _OrdList = "AnaDat.DebUms.Jahr|no"
  179. _FldNameList[1] > AnaDat.DebUms.Firma
  180. "Firma" "Firma" ? ? "character" ? ? ? ? ? ? yes ? yes 8 yes ""
  181. _FldNameList[2] > AnaDat.DebUms.Knr
  182. "Knr" "Knr" ? ? "integer" ? ? ? ? ? ? yes ? yes 8.4 yes ""
  183. _FldNameList[3] > AnaDat.DebUms.Jahr
  184. "Jahr" "Jahr" ? ? "integer" ? ? ? ? ? ? yes ? no 4.8 yes ""
  185. _FldNameList[4] > AnaDat.DebUms.Ums_Grp
  186. "Ums_Grp" "Ums_Grp" ? ? "integer" ? ? ? ? ? ? yes ? no 8.8 yes ""
  187. _FldNameList[5] > "_<CALC>"
  188. "DYNAMIC-FUNCTION('GETUMSATZGRP':U, INPUT RowObject.Ums_Grp)" "Umsatzgrp" "Umsatzgruppe" "x(30)" "character" ? ? ? ? ? ? yes ? no 30 no ?
  189. _FldNameList[6] > AnaDat.DebUms.Me_Mon[1]
  190. "Me_Mon[1]" "Me_Mon1" ? ? "decimal" ? ? ? ? ? ? yes ? no 15.2 yes ""
  191. _FldNameList[7] > AnaDat.DebUms.Me_Mon[2]
  192. "Me_Mon[2]" "Me_Mon2" ? ? "decimal" ? ? ? ? ? ? yes ? no 15.2 yes ""
  193. _FldNameList[8] > AnaDat.DebUms.Me_Mon[3]
  194. "Me_Mon[3]" "Me_Mon3" ? ? "decimal" ? ? ? ? ? ? yes ? no 15.2 yes ""
  195. _FldNameList[9] > AnaDat.DebUms.Me_Mon[4]
  196. "Me_Mon[4]" "Me_Mon4" ? ? "decimal" ? ? ? ? ? ? yes ? no 15.2 yes ""
  197. _FldNameList[10] > AnaDat.DebUms.Me_Mon[5]
  198. "Me_Mon[5]" "Me_Mon5" ? ? "decimal" ? ? ? ? ? ? yes ? no 15.2 yes ""
  199. _FldNameList[11] > AnaDat.DebUms.Me_Mon[6]
  200. "Me_Mon[6]" "Me_Mon6" ? ? "decimal" ? ? ? ? ? ? yes ? no 15.2 yes ""
  201. _FldNameList[12] > AnaDat.DebUms.Me_Mon[7]
  202. "Me_Mon[7]" "Me_Mon7" ? ? "decimal" ? ? ? ? ? ? yes ? no 15.2 yes ""
  203. _FldNameList[13] > AnaDat.DebUms.Me_Mon[8]
  204. "Me_Mon[8]" "Me_Mon8" ? ? "decimal" ? ? ? ? ? ? yes ? no 15.2 yes ""
  205. _FldNameList[14] > AnaDat.DebUms.Me_Mon[9]
  206. "Me_Mon[9]" "Me_Mon9" ? ? "decimal" ? ? ? ? ? ? yes ? no 15.2 yes ""
  207. _FldNameList[15] > AnaDat.DebUms.Me_Mon[10]
  208. "Me_Mon[10]" "Me_Mon10" ? ? "decimal" ? ? ? ? ? ? yes ? no 15.2 yes ""
  209. _FldNameList[16] > AnaDat.DebUms.Me_Mon[11]
  210. "Me_Mon[11]" "Me_Mon11" ? ? "decimal" ? ? ? ? ? ? yes ? no 15.2 yes ""
  211. _FldNameList[17] > AnaDat.DebUms.Me_Mon[12]
  212. "Me_Mon[12]" "Me_Mon12" ? ? "decimal" ? ? ? ? ? ? yes ? no 15.2 yes ""
  213. _FldNameList[18] > AnaDat.DebUms.Ep_Mon[1]
  214. "Ep_Mon[1]" "Ep_Mon1" ? ? "decimal" ? ? ? ? ? ? yes ? no 13 yes ""
  215. _FldNameList[19] > AnaDat.DebUms.Ep_Mon[2]
  216. "Ep_Mon[2]" "Ep_Mon2" ? ? "decimal" ? ? ? ? ? ? yes ? no 13 yes ""
  217. _FldNameList[20] > AnaDat.DebUms.Ep_Mon[3]
  218. "Ep_Mon[3]" "Ep_Mon3" ? ? "decimal" ? ? ? ? ? ? yes ? no 13 yes ""
  219. _FldNameList[21] > AnaDat.DebUms.Ep_Mon[4]
  220. "Ep_Mon[4]" "Ep_Mon4" ? ? "decimal" ? ? ? ? ? ? yes ? no 13 yes ""
  221. _FldNameList[22] > AnaDat.DebUms.Ep_Mon[5]
  222. "Ep_Mon[5]" "Ep_Mon5" ? ? "decimal" ? ? ? ? ? ? yes ? no 13 yes ""
  223. _FldNameList[23] > AnaDat.DebUms.Ep_Mon[6]
  224. "Ep_Mon[6]" "Ep_Mon6" ? ? "decimal" ? ? ? ? ? ? yes ? no 13 yes ""
  225. _FldNameList[24] > AnaDat.DebUms.Ep_Mon[7]
  226. "Ep_Mon[7]" "Ep_Mon7" ? ? "decimal" ? ? ? ? ? ? yes ? no 13 yes ""
  227. _FldNameList[25] > AnaDat.DebUms.Ep_Mon[8]
  228. "Ep_Mon[8]" "Ep_Mon8" ? ? "decimal" ? ? ? ? ? ? yes ? no 13 yes ""
  229. _FldNameList[26] > AnaDat.DebUms.Ep_Mon[9]
  230. "Ep_Mon[9]" "Ep_Mon9" ? ? "decimal" ? ? ? ? ? ? yes ? no 13 yes ""
  231. _FldNameList[27] > AnaDat.DebUms.Ep_Mon[10]
  232. "Ep_Mon[10]" "Ep_Mon10" ? ? "decimal" ? ? ? ? ? ? yes ? no 13 yes ""
  233. _FldNameList[28] > AnaDat.DebUms.Ep_Mon[11]
  234. "Ep_Mon[11]" "Ep_Mon11" ? ? "decimal" ? ? ? ? ? ? yes ? no 13 yes ""
  235. _FldNameList[29] > AnaDat.DebUms.Ep_Mon[12]
  236. "Ep_Mon[12]" "Ep_Mon12" ? ? "decimal" ? ? ? ? ? ? yes ? no 13 yes ""
  237. _FldNameList[30] > AnaDat.DebUms.Vp_Mon[1]
  238. "Vp_Mon[1]" "Vp_Mon1" ? ? "decimal" ? ? ? ? ? ? yes ? no 13 yes ""
  239. _FldNameList[31] > AnaDat.DebUms.Vp_Mon[2]
  240. "Vp_Mon[2]" "Vp_Mon2" ? ? "decimal" ? ? ? ? ? ? yes ? no 13 yes ""
  241. _FldNameList[32] > AnaDat.DebUms.Vp_Mon[3]
  242. "Vp_Mon[3]" "Vp_Mon3" ? ? "decimal" ? ? ? ? ? ? yes ? no 13 yes ""
  243. _FldNameList[33] > AnaDat.DebUms.Vp_Mon[4]
  244. "Vp_Mon[4]" "Vp_Mon4" ? ? "decimal" ? ? ? ? ? ? yes ? no 13 yes ""
  245. _FldNameList[34] > AnaDat.DebUms.Vp_Mon[5]
  246. "Vp_Mon[5]" "Vp_Mon5" ? ? "decimal" ? ? ? ? ? ? yes ? no 13 yes ""
  247. _FldNameList[35] > AnaDat.DebUms.Vp_Mon[6]
  248. "Vp_Mon[6]" "Vp_Mon6" ? ? "decimal" ? ? ? ? ? ? yes ? no 13 yes ""
  249. _FldNameList[36] > AnaDat.DebUms.Vp_Mon[7]
  250. "Vp_Mon[7]" "Vp_Mon7" ? ? "decimal" ? ? ? ? ? ? yes ? no 13 yes ""
  251. _FldNameList[37] > AnaDat.DebUms.Vp_Mon[8]
  252. "Vp_Mon[8]" "Vp_Mon8" ? ? "decimal" ? ? ? ? ? ? yes ? no 13 yes ""
  253. _FldNameList[38] > AnaDat.DebUms.Vp_Mon[9]
  254. "Vp_Mon[9]" "Vp_Mon9" ? ? "decimal" ? ? ? ? ? ? yes ? no 13 yes ""
  255. _FldNameList[39] > AnaDat.DebUms.Vp_Mon[10]
  256. "Vp_Mon[10]" "Vp_Mon10" ? ? "decimal" ? ? ? ? ? ? yes ? no 13 yes ""
  257. _FldNameList[40] > AnaDat.DebUms.Vp_Mon[11]
  258. "Vp_Mon[11]" "Vp_Mon11" ? ? "decimal" ? ? ? ? ? ? yes ? no 13 yes ""
  259. _FldNameList[41] > AnaDat.DebUms.Vp_Mon[12]
  260. "Vp_Mon[12]" "Vp_Mon12" ? ? "decimal" ? ? ? ? ? ? yes ? no 13 yes ""
  261. _FldNameList[42] > AnaDat.DebUms.Me_Kum
  262. "Me_Kum" "Me_Kum" ? ? "decimal" ? ? ? ? ? ? yes ? no 15.2 yes ""
  263. _FldNameList[43] > AnaDat.DebUms.Ep_Kum
  264. "Ep_Kum" "Ep_Kum" ? ? "decimal" ? ? ? ? ? ? yes ? no 13 yes ""
  265. _FldNameList[44] > AnaDat.DebUms.Vp_Kum
  266. "Vp_Kum" "Vp_Kum" ? ? "decimal" ? ? ? ? ? ? yes ? no 13 yes ""
  267. _FldNameList[45] > "_<CALC>"
  268. "IF ABS(IF (RowObject.Ep_Kum <> 0 AND RowObject.Vp_Kum <> 0) THEN ((100 - (RowObject.Ep_Kum * 100 / RowObject.Vp_Kum))) ELSE (0)) > 999.99 THEN 0.0 ELSE (IF (RowObject.Ep_Kum <> 0 AND RowObject.Vp_Kum <> 0) THEN ((100 - (RowObject.Ep_Kum * 100 / RowObject.Vp_Kum))) ELSE 0.0)" "Marge" "Marge-%" "zzz9.99-" "Decimal" ? ? ? ? ? ? yes ? no 8.2 no ?
  269. _Design-Parent is WINDOW dTables @ ( 1.14 , 2.6 )
  270. */ /* QUERY Query-Main */
  271. &ANALYZE-RESUME
  272. &ANALYZE-SUSPEND _UIB-CODE-BLOCK _CUSTOM _MAIN-BLOCK dTables
  273. /* *************************** Main Block *************************** */
  274. { incl/datmainblock.i }
  275. SUBSCRIBE TO 'SETOPENFLAGDEBST' ANYWHERE.
  276. &IF DEFINED(UIB_IS_RUNNING) <> 0 &THEN
  277. RUN initializeObject.
  278. &ENDIF
  279. /* _UIB-CODE-BLOCK-END */
  280. &ANALYZE-RESUME
  281. /* ********************** Internal Procedures *********************** */
  282. {&DB-REQUIRED-START}
  283. &ANALYZE-SUSPEND _UIB-CODE-BLOCK _PROCEDURE DATA.CALCULATE dTables DATA.CALCULATE _DB-REQUIRED
  284. PROCEDURE DATA.CALCULATE :
  285. /*------------------------------------------------------------------------------
  286. Purpose: Calculate all the Calculated Expressions found in the
  287. SmartDataObject.
  288. Parameters: <none>
  289. ------------------------------------------------------------------------------*/
  290. ASSIGN
  291. rowObject.Marge = (IF ABS(IF (RowObject.Ep_Kum <> 0 AND RowObject.Vp_Kum <> 0) THEN ((100 - (RowObject.Ep_Kum * 100 / RowObject.Vp_Kum))) ELSE (0)) > 999.99 THEN 0.0 ELSE (IF (RowObject.Ep_Kum <> 0 AND RowObject.Vp_Kum <> 0) THEN ((100 - (RowObject.Ep_Kum * 100 / RowObject.Vp_Kum))) ELSE 0.0))
  292. rowObject.Umsatzgrp = (DYNAMIC-FUNCTION('GETUMSATZGRP':U, INPUT RowObject.Ums_Grp))
  293. .
  294. END PROCEDURE.
  295. /* _UIB-CODE-BLOCK-END */
  296. &ANALYZE-RESUME
  297. {&DB-REQUIRED-END}
  298. {&DB-REQUIRED-START}
  299. &ANALYZE-SUSPEND _UIB-CODE-BLOCK _PROCEDURE dataAvailable dTables _DB-REQUIRED
  300. PROCEDURE dataAvailable :
  301. /*------------------------------------------------------------------------------
  302. Purpose: Super Override
  303. Parameters:
  304. Notes:
  305. ------------------------------------------------------------------------------*/
  306. { incl/datdataavailable.i }
  307. END PROCEDURE.
  308. /* _UIB-CODE-BLOCK-END */
  309. &ANALYZE-RESUME
  310. {&DB-REQUIRED-END}
  311. &ANALYZE-SUSPEND _UIB-CODE-BLOCK _PROCEDURE disable_UI dTables _DEFAULT-DISABLE
  312. PROCEDURE disable_UI :
  313. /*------------------------------------------------------------------------------
  314. Purpose: DISABLE the User Interface
  315. Parameters: <none>
  316. Notes: Here we clean-up the user-interface by deleting
  317. dynamic widgets we have created and/or hide
  318. frames. This procedure is usually called when
  319. we are ready to "clean-up" after running.
  320. ------------------------------------------------------------------------------*/
  321. /* Hide all frames. */
  322. IF THIS-PROCEDURE:PERSISTENT THEN DELETE PROCEDURE THIS-PROCEDURE.
  323. END PROCEDURE.
  324. /* _UIB-CODE-BLOCK-END */
  325. &ANALYZE-RESUME
  326. {&DB-REQUIRED-START}
  327. &ANALYZE-SUSPEND _UIB-CODE-BLOCK _PROCEDURE initializeObject dTables _DB-REQUIRED
  328. PROCEDURE initializeObject :
  329. /*------------------------------------------------------------------------------
  330. Purpose: Super Override
  331. Parameters:
  332. Notes:
  333. ------------------------------------------------------------------------------*/
  334. { incl/datinitialize.i }
  335. END PROCEDURE.
  336. /* _UIB-CODE-BLOCK-END */
  337. &ANALYZE-RESUME
  338. {&DB-REQUIRED-END}
  339. {&DB-REQUIRED-START}
  340. &ANALYZE-SUSPEND _UIB-CODE-BLOCK _PROCEDURE SETOPENFLAGDEBST dTables _DB-REQUIRED
  341. PROCEDURE SETOPENFLAGDEBST :
  342. /*------------------------------------------------------------------------------
  343. Purpose:
  344. Parameters: <none>
  345. Notes:
  346. ------------------------------------------------------------------------------*/
  347. DEF INPUT PARAMETER ipFlag AS LOG NO-UNDO.
  348. FOpen = ipFlag.
  349. IF FOpen THEN DYNAMIC-FUNCTION('openQuery':U).
  350. END PROCEDURE.
  351. /* _UIB-CODE-BLOCK-END */
  352. &ANALYZE-RESUME
  353. {&DB-REQUIRED-END}
  354. /* ************************ Function Implementations ***************** */
  355. {&DB-REQUIRED-START}
  356. &ANALYZE-SUSPEND _UIB-CODE-BLOCK _FUNCTION getCurrentRecid dTables _DB-REQUIRED
  357. FUNCTION getCurrentRecid RETURNS RECID
  358. ( /* parameter-definitions */ ) :
  359. /*------------------------------------------------------------------------------
  360. Purpose:
  361. Notes:
  362. ------------------------------------------------------------------------------*/
  363. { incl/datgetcurrentrecid.i }
  364. END FUNCTION.
  365. /* _UIB-CODE-BLOCK-END */
  366. &ANALYZE-RESUME
  367. {&DB-REQUIRED-END}
  368. {&DB-REQUIRED-START}
  369. &ANALYZE-SUSPEND _UIB-CODE-BLOCK _FUNCTION openQuery dTables _DB-REQUIRED
  370. FUNCTION openQuery RETURNS LOGICAL
  371. ( /* parameter-definitions */ ) :
  372. /*------------------------------------------------------------------------------
  373. Purpose: Super Override
  374. Notes:
  375. ------------------------------------------------------------------------------*/
  376. DEF VAR cString AS CHAR NO-UNDO.
  377. cString = DYNAMIC-FUNCTION('getForeignValues':U).
  378. IF cString = ? THEN RETURN FALSE.
  379. IF NOT FOpen THEN RETURN FALSE.
  380. /* xWhere = ''. */
  381. /* DYNAMIC-FUNCTION('setQueryWhere':U, INPUT xWhere). */
  382. /* xSort = ''. */
  383. /* DYNAMIC-FUNCTION('setQuerySort':U, INPUT xSort). */
  384. /* xWhere = ''. */
  385. /* DYNAMIC-FUNCTION('setQueryString':U, INPUT xWhere). */
  386. RETURN SUPER( ).
  387. END FUNCTION.
  388. /* _UIB-CODE-BLOCK-END */
  389. &ANALYZE-RESUME
  390. {&DB-REQUIRED-END}