{"id":251,"date":"2023-02-22T17:29:39","date_gmt":"2023-02-22T16:29:39","guid":{"rendered":"http:\/\/www.sepchat.com\/SC\/?p=251"},"modified":"2023-02-23T15:00:26","modified_gmt":"2023-02-23T14:00:26","slug":"ibm-i-des-couleurs-dans-le-resultat-dune-requete-sql","status":"publish","type":"post","link":"http:\/\/www.sepchat.com\/SC\/index.php\/2023\/02\/22\/ibm-i-des-couleurs-dans-le-resultat-dune-requete-sql\/","title":{"rendered":"IBM\u00a0i &#8211; Des couleurs dans le r\u00e9sultat d\u2019une requ\u00eate SQL"},"content":{"rendered":"\n<p>En 5250, il est possible d&rsquo;afficher le r\u00e9sultat d&rsquo;une requ\u00eate avec plusieurs couleurs.<\/p>\n\n\n\n<p>tout d&rsquo;abord, il faut savoir que les couleurs se d\u00e9finissent pas des code Hexa :<\/p>\n\n\n\n<p>x\u201920\u2019 Vert<br>x\u201921\u2019 Vert en inverse vid\u00e9o<br>x\u201922\u2019 Blanc<br>x\u201923\u2019 Blanc en inverse vid\u00e9o<br>x\u201928\u2019 Rouge<br>x\u201929\u2019 Rouge en inverse vid\u00e9o<br>x\u20192A\u2019 Clignotant<br>x\u20192B\u2019 Clignotant en inverse vid\u00e9o<br>x\u20193a\u2019 Bleu<\/p>\n\n\n\n<p>SELECT CASE<br>&nbsp;WHEN COUNT(*) &gt; 10 THEN (X&rsquo;20&rsquo;!!CDAPL)<br>&nbsp;WHEN COUNT(*) &gt; &nbsp;5 THEN (X&rsquo;22&rsquo;!!CDAPL)<br>&nbsp;WHEN COUNT(*) &gt; &nbsp;0 THEN (X&rsquo;28&rsquo;!!CDAPL)<br>&nbsp;END &nbsp;AS CODE_APPLI,<br>&nbsp;LIBELLE AS LIBELLE,<br>&nbsp;COUNT(*) AS NOMBRE_OPTIONS<br>FROM MNOPT1PF GROUP BY CDAPL, LIBELLE<br>HAVING COUNT(*) &gt; 0<\/p>\n\n\n\n<p>Et hop !<\/p>\n\n\n\n<figure class=\"wp-block-image is-resized size-full has-custom-border\"><a href=\"sql2\"><img decoding=\"async\" loading=\"lazy\" src=\"http:\/\/www.sepchat.com\/SC\/wp-content\/uploads\/2023\/02\/fleche-r-edited.png\" alt=\"\" width=\"57\" height=\"57\"\/><\/a><\/figure>\n\n\n\n<div class=\"wp-block-buttons is-layout-flex\">\n<div class=\"wp-block-button is-style-outline\"><a class=\"wp-block-button__link wp-element-button\" style=\"border-radius:100px\">Cet article vous a \u00e9t\u00e9 utile ? N\u2019h\u00e9sitez pas \u00e0 le partager.<\/a><\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>En 5250, il est possible d&rsquo;afficher le r\u00e9sultat d&rsquo;une requ\u00eate avec plusieurs couleurs. tout d&rsquo;abord, il faut savoir que les couleurs se d\u00e9finissent pas des code Hexa : x\u201920\u2019 Vertx\u201921\u2019 Vert en inverse vid\u00e9ox\u201922\u2019 Blancx\u201923\u2019 Blanc en inverse vid\u00e9ox\u201928\u2019 Rougex\u201929\u2019 Rouge en inverse vid\u00e9ox\u20192A\u2019 Clignotantx\u20192B\u2019 Clignotant en inverse vid\u00e9ox\u20193a\u2019 Bleu SELECT CASE&nbsp;WHEN COUNT(*) &gt; 10 [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[8],"tags":[],"_links":{"self":[{"href":"http:\/\/www.sepchat.com\/SC\/index.php\/wp-json\/wp\/v2\/posts\/251"}],"collection":[{"href":"http:\/\/www.sepchat.com\/SC\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.sepchat.com\/SC\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.sepchat.com\/SC\/index.php\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"http:\/\/www.sepchat.com\/SC\/index.php\/wp-json\/wp\/v2\/comments?post=251"}],"version-history":[{"count":3,"href":"http:\/\/www.sepchat.com\/SC\/index.php\/wp-json\/wp\/v2\/posts\/251\/revisions"}],"predecessor-version":[{"id":330,"href":"http:\/\/www.sepchat.com\/SC\/index.php\/wp-json\/wp\/v2\/posts\/251\/revisions\/330"}],"wp:attachment":[{"href":"http:\/\/www.sepchat.com\/SC\/index.php\/wp-json\/wp\/v2\/media?parent=251"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.sepchat.com\/SC\/index.php\/wp-json\/wp\/v2\/categories?post=251"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.sepchat.com\/SC\/index.php\/wp-json\/wp\/v2\/tags?post=251"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}