SELECT  REUTER                                                                                                                                                                                                                                                                                                                                    AS RIC         ,
        INDX.LIBELLE                                                                                                                                                                                                                                                                                                                              AS STOCKINDEX  ,
        INDX.SICOVAM                                                                                                                                                                                                                                                                                                                              AS SICOVAM     ,
        IRSA.get_NbStockForIndex(INDX.SICOVAM)                                                                                                                                                                                                                                                                                                    AS NBSTOCKS    ,
        devise_to_str(INDX.DEVISECTT)                                                                                                                                                                                                                                                                                                             AS CURRENCYID  ,
        SUBSTR(INDX.REFERENCE, 0, 12)                                                                                                                                                                                                                                                                                                             AS ISIN        ,
        INDX.MNEMO_V2                                                                                                                                                                                                                                                                                                                             AS MNEMONIC    ,
        HISTO_INDEX.JOUR                                                                                                                                                                                                                                                                                                                          AS ACTIONDATE  ,
        HISTO_INDEX.D                                                                                                                                                                                                                                                                                                                             AS RECORDEDLAST,
        INDX.TAUX                                                                                                                                                                                                                                                                                                                                 AS LAMBDA      ,
        INDX.QUOTITE                                                                                                                                                                                                                                                                                                                              AS QUOTITY     ,
        INDX.NOMINAL                                                                                                                                                                                                                                                                                                                              AS DIVISOR     ,
        num_to_str(INDX.MARCHE)                                                                                                                                                                                                                                                                                                                   AS EXCHANGEID  ,
        DECODE(INDX.modele, 'Standard', 1 /(INDX.TAUX * INDX.NOMINAL) * SUM(BASKET.QUANTITE * HISTO_STOCK.D * DECODE(STOCK.TYPE, 'I', STOCK.QUOTITE, 1)), 1 /(INDX.TAUX * INDX.NOMINAL) * SUM(BASKET.QUANTITE * CL_FOREX.Exchange_Rate_ND(STOCK.devisectt, INDX.DEVISECTT, SYSDATE) * HISTO_STOCK.D * DECODE(STOCK.TYPE, 'I', STOCK.QUOTITE, 1))) AS CALCULATEDLAST
FROM    TITRES STOCK          ,
        TITRES INDX           ,
        HISTORIQUE HISTO_INDEX,
        RIC                   ,
        PANIER BASKET         ,
        HISTORIQUE HISTO_STOCK
WHERE   INDX.sicovam         = RIC.sicovam       + 0
    AND STOCK.SICOVAM        = BASKET.SICOPANIER + 0
    AND HISTO_STOCK.SICOVAM  = BASKET.SICOPANIER + 0
    AND INDX.NOMINAL         > 0
    AND INDX.SICOVAM         = BASKET.SICOVAM      + 0
    AND HISTO_INDEX.SICOVAM  = BASKET.SICOVAM      + 0
    AND BASKET.SICOVAM                            IN (1303390422, 1301320095, 1301464421, 1303934937, 1303390423, 1303934939, 1301297073, 1301554191, 1301851233, 1302266711, 1301696931, 1301713856, 1301442250, 1304305010, 1304304690, 1301713869, 1301418398, 1301696843, 1302266623, 1302034197, 1301730640, 1302034187, 1301837296, 1303218754, 1304177106, 1304177102, 1304244438, 1304244440, 1304045111, 1304301197, 1302266792, 1302266948, 1302293980, 1301609471, 1302720566, 1302533854, 1301713805, 1301446426, 1302266668, 1300526881 , 1300673147, 1300613209, 1300526889, 1300613211, 1300613214, 1300671904, 1300671908, 1300613227, 1300526923, 1300613217, 1300613218, 1300613221, 1301713581, 1300526890, 1300671909, 1300613222, 1301874826, 1301873348, 1300526953, 1300658219, 1300526973, 1301178202, 1300526945, 1300613280, 1301340236, 1303934920, 1300808339, 1300526914, 1303390419, 1303928515, 1303934919, 1301477568, 1303934921, 1300973119, 1300658226, 1303934924, 1303928516, 1302456418, 1300526929, 1300641001, 1300526867, 1300641810 , 1300526868, 1301318237, 1303928517, 1302266902, 1301108114, 1303449497, 1301233163, 1303598379, 1303598175, 1303598179, 1303598134, 1303598137, 1303598153, 1303598155, 1303558847, 1303558420, 1303598280, 1303598282, 1303590525, 1303590528, 1300677240, 1300678132, 1300641658, 1301172311, 1300677137, 1300679918, 1300677362, 1300679764, 1300677462, 1300677774, 1300680110, 1303862022, 1303934862, 1301160858, 1301208264, 1301398074, 1301233241, 1303390432, 1303390430, 1301231477, 1303390431, 1301408697 , 1303928526, 1303934953, 1302092726, 1302092350, 1303934954, 1301583287, 1302651898, 1301608169, 1300753766, 1302651880, 1302438246, 1302651891, 1302326338, 1302326328, 1302326368, 1302326359, 1301843692, 1302671778, 1301920361, 1302395744, 1302650354, 1301843693, 1302438286, 1303934894, 1303934893, 1303390413, 1300683223, 1301340262, 1303934892, 1303928513, 1303390412, 1303934889, 1302322625, 1302322621, 1303928514, 1303390414, 1303785757, 1303785510, 1303934895, 1303934896, 1303934900, 1303934897 , 1303934898, 1303934899, 1303934901, 1303934902, 1303934903, 1303934905, 1300641888, 1300526927, 1303934906, 1303934904, 1300526905, 1301713742, 1300526912, 1300935734, 1301348215, 1301375400, 1302267105, 1300613265, 1301713821, 1300674416, 1303928505, 1304331862, 1301366215, 1301346912, 1301480968, 1302529466, 1303239738, 1302464089, 1302709607, 1302545660, 1301000793, 1300998810, 1300998812, 1300998814, 1300998819, 1302162085, 1301002780, 1301003034, 1302319135, 1301345229, 1303866237, 1301295497 , 1302562288, 1302932615, 1303208772, 1303928510, 1303934883, 1303934884, 1303390410, 1303390409, 1303934888, 1302755702, 1303050639, 1303934886, 1301233172, 1303928508, 1303994911, 1300641820, 1300526981, 1301011228, 1300641813, 1300526930, 1302936701, 1303928509, 1303934890, 1302382897, 1300526878, 1301304254, 1303390411, 1303862026, 1301354908, 1301538055, 1303928511, 1303928512, 1303934891, 1300470839, 1300350715, 1303928518, 1302266797, 1301369127, 1300526866, 1303934926, 1303934925, 1303934927 , 1303934928, 1303934929, 1303934930, 1303934934, 1303928519, 1303934931, 1303934932, 1303934936, 1303438058, 1303934933, 1302266742, 1300613268, 1303934935, 1303390420, 1303928520, 1300961764, 1303934938, 1303390421, 1303928522, 1301344792, 1300567868, 1302266725, 1301790817, 1303934842, 1303934845, 1303390398, 1303934852, 1303934850, 1303934846, 1303934854, 1301323121, 1300844238, 1303006554, 1300734703, 1304505043, 1300882436, 1303041774, 1300776915, 1301572642, 1301569895, 1302707100, 1302575298 , 1303934847, 1300526873, 1303934849, 1301340266, 1301328305, 1303390395, 1301233230, 1303390399, 1303934857, 1303934851, 1302188642, 1302188569, 1301282858, 1300526978, 1300860372, 1300613274, 1301602884, 1303390402, 1303934877, 1303127348, 1303934881, 1303390403, 1303928506, 1303934879, 1303390405, 1303934878, 1303928507, 1303934882, 1303934876, 1303934880, 1304240625, 1300772941, 1303934887, 1301233147, 1303390408, 1301233144, 1302266939, 1300732333, 1302665795, 1303390406, 1300738791, 1303934908 , 1303390415, 1304684862, 1304684890, 1303934907, 1303934911, 1303390416, 1303934915, 1301233156, 1303934912, 1303934918, 1301233251, 1303934913, 1301304256, 1302395595, 1300526875, 1300840816, 1302096780, 1302970461, 1302576010, 1302707129, 1302576056, 1302576040, 1302707152, 1302575935, 1303934917, 1303934916, 1303934914, 1304465153, 1301552457, 1300641837, 1303934945, 1303934948, 1303390426, 1302327651, 1301208846, 1300526871, 1303934947, 1300526952, 1300809201, 1301308036, 1300955001, 1301251949 , 1300895571, 1300788549, 1303934949, 1303390425, 1303390424, 1303934951, 1303390427, 1301368393, 1303928524, 1300526951, 1301217010, 1303934950, 1303390428, 1303934952, 1303390429, 1303934940, 1301328514, 1300719296, 1303934956, 1301458974, 1301398105, 1301480940, 1301606395, 1300640305, 1301713844, 1303928501, 1303934863, 1303934858, 1303934859, 1303934860, 1301233179, 1303934861, 1303934865, 1303934866, 1303934867, 1303390400, 1302113902, 1303987143, 1301159112, 1300526874, 1302165994, 1302167025 , 1302022377, 1302022384, 1303928503, 1303934868, 1303928502, 1301889599, 1301843319, 1303255317, 1301548427, 1301351118, 1301365357, 1302076864, 1302071232, 1302071320, 1302067258, 1302067545, 1302081488, 1302077941, 1302036517, 1302002870, 1302496116, 1303934874, 1303934875, 1302370617, 1302349843, 1302329577, 1302322504, 1300641681, 1300526870, 1300640046, 1300672706, 1301713833, 1302621947, 1302267010, 1300613266, 1302332989, 1302349456, 1301713837, 1301533902, 1301873890, 1300526924, 1300526891 , 1300671912, 1300613225, 1301798189, 1300962035, 1302095349, 1302095662, 1300880599, 1301713777, 1303018748, 1302937322, 1302266685, 1302266675, 1303937966, 1303937965, 1302509097, 1302509129, 1302266709, 1301440406, 1302117277, 1302439700, 1301446355, 1301713796, 1301713789, 1300880601, 1303937963, 1303937960, 1303934870, 1300526872, 1300526903, 1302266970, 1300526968, 1301713605, 1300526900, 1301713619, 1300526904, 1301713626, 1300526907, 1301713633, 1300526908, 1301713636, 1300526910, 1301713641 , 1300526897, 1301713666, 1300526909, 1301713683, 1300526899, 1301713690, 1300526895, 1301713696, 1300526906, 1301713704, 1300526911, 1301713707, 1300526898, 1301713710, 1300526896, 1301713714, 1301103118, 1302395748, 1302326348, 1302326351, 1300887357, 1300526926, 1302446752, 1300733648, 1302719534, 1303934955, 1303994872, 1300814131, 1303928527, 1303934957, 1303934958, 1303934959, 1303554628, 1303934960, 1303934961, 1303934962, 1301461374, 1303934963, 1303934965, 1302266718, 1302065616, 1301233150 , 1303928528, 1303934964, 1300984457, 1303390433, 1300968336, 1303934856, 1301416058, 1303934848, 1303934855, 1303934853, 1300865436, 1300882498, 1302918808, 1302918806, 1300964928, 1303341499, 1301266603, 1301435858, 1303408995, 1303053318, 1302848881, 1304730704, 1302865768, 1302972115, 1303596293, 1303596284, 1303597608, 1303597611, 1303597697, 1303597699, 1303559053, 1303559031, 1303598092, 1303598094, 1303590191, 1303590260, 1301713799, 1301170333, 1302267157, 1301699722, 1300641683, 1302962287 , 1300526880, 1302267218, 1301912377, 1302399162, 1302399144, 1300808349, 1300526921, 1301231455, 1301845486, 1302391580, 1302391577, 1304459357, 1303928504, 1303995289, 1301713829, 1300996758, 1303934871, 1303934872, 1301713586, 1300526901, 1301713590, 1300526902, 1301713596, 1302297017, 1301837274, 1303468375, 1303468368, 1304189103, 1302630256, 1303008171, 1300963092, 1303008361, 1303928525, 1303456033, 1303934832, 1303390390, 1303934834, 1303934836, 1301430091, 1300526876, 1303958943, 1303928500 , 1303934837, 1303934838, 1303934833, 1301340215, 1300526935, 1301521962, 1303934839, 1303934835, 1303934840, 1303934841, 1303934843, 1303934844, 1303390392, 1300641863, 1304045103, 1304155515, 1304155506, 1304149224, 1304149221, 1303441005, 1303441001, 1304155455, 1304155452, 1302599891, 1302599907, 1300570688, 1300674471, 1302431569, 1302012076, 1301649493, 1301713863, 1300567854, 1300808347, 1300526869, 1303934946, 1303436098, 1303928523, 1301233235, 1301214467, 1303934942, 1300786700, 1303570059 , 1303934941)
    AND BASKET.SICOVAM       = RIC.sicovam         + 0
    AND HISTO_STOCK.SICOVAM  = STOCK.SICOVAM       + 0
    AND INDX.SICOVAM         = HISTO_INDEX.SICOVAM + 0
    AND INDX.SICOVAM                              IN (1303390422, 1301320095, 1301464421, 1303934937, 1303390423, 1303934939, 1301297073, 1301554191, 1301851233, 1302266711, 1301696931, 1301713856, 1301442250, 1304305010, 1304304690, 1301713869, 1301418398, 1301696843, 1302266623, 1302034197, 1301730640, 1302034187, 1301837296, 1303218754, 1304177106, 1304177102, 1304244438, 1304244440, 1304045111, 1304301197, 1302266792, 1302266948, 1302293980, 1301609471, 1302720566, 1302533854, 1301713805, 1301446426, 1302266668, 1300526881 , 1300673147, 1300613209, 1300526889, 1300613211, 1300613214, 1300671904, 1300671908, 1300613227, 1300526923, 1300613217, 1300613218, 1300613221, 1301713581, 1300526890, 1300671909, 1300613222, 1301874826, 1301873348, 1300526953, 1300658219, 1300526973, 1301178202, 1300526945, 1300613280, 1301340236, 1303934920, 1300808339, 1300526914, 1303390419, 1303928515, 1303934919, 1301477568, 1303934921, 1300973119, 1300658226, 1303934924, 1303928516, 1302456418, 1300526929, 1300641001, 1300526867, 1300641810 , 1300526868, 1301318237, 1303928517, 1302266902, 1301108114, 1303449497, 1301233163, 1303598379, 1303598175, 1303598179, 1303598134, 1303598137, 1303598153, 1303598155, 1303558847, 1303558420, 1303598280, 1303598282, 1303590525, 1303590528, 1300677240, 1300678132, 1300641658, 1301172311, 1300677137, 1300679918, 1300677362, 1300679764, 1300677462, 1300677774, 1300680110, 1303862022, 1303934862, 1301160858, 1301208264, 1301398074, 1301233241, 1303390432, 1303390430, 1301231477, 1303390431, 1301408697 , 1303928526, 1303934953, 1302092726, 1302092350, 1303934954, 1301583287, 1302651898, 1301608169, 1300753766, 1302651880, 1302438246, 1302651891, 1302326338, 1302326328, 1302326368, 1302326359, 1301843692, 1302671778, 1301920361, 1302395744, 1302650354, 1301843693, 1302438286, 1303934894, 1303934893, 1303390413, 1300683223, 1301340262, 1303934892, 1303928513, 1303390412, 1303934889, 1302322625, 1302322621, 1303928514, 1303390414, 1303785757, 1303785510, 1303934895, 1303934896, 1303934900, 1303934897 , 1303934898, 1303934899, 1303934901, 1303934902, 1303934903, 1303934905, 1300641888, 1300526927, 1303934906, 1303934904, 1300526905, 1301713742, 1300526912, 1300935734, 1301348215, 1301375400, 1302267105, 1300613265, 1301713821, 1300674416, 1303928505, 1304331862, 1301366215, 1301346912, 1301480968, 1302529466, 1303239738, 1302464089, 1302709607, 1302545660, 1301000793, 1300998810, 1300998812, 1300998814, 1300998819, 1302162085, 1301002780, 1301003034, 1302319135, 1301345229, 1303866237, 1301295497 , 1302562288, 1302932615, 1303208772, 1303928510, 1303934883, 1303934884, 1303390410, 1303390409, 1303934888, 1302755702, 1303050639, 1303934886, 1301233172, 1303928508, 1303994911, 1300641820, 1300526981, 1301011228, 1300641813, 1300526930, 1302936701, 1303928509, 1303934890, 1302382897, 1300526878, 1301304254, 1303390411, 1303862026, 1301354908, 1301538055, 1303928511, 1303928512, 1303934891, 1300470839, 1300350715, 1303928518, 1302266797, 1301369127, 1300526866, 1303934926, 1303934925, 1303934927 , 1303934928, 1303934929, 1303934930, 1303934934, 1303928519, 1303934931, 1303934932, 1303934936, 1303438058, 1303934933, 1302266742, 1300613268, 1303934935, 1303390420, 1303928520, 1300961764, 1303934938, 1303390421, 1303928522, 1301344792, 1300567868, 1302266725, 1301790817, 1303934842, 1303934845, 1303390398, 1303934852, 1303934850, 1303934846, 1303934854, 1301323121, 1300844238, 1303006554, 1300734703, 1304505043, 1300882436, 1303041774, 1300776915, 1301572642, 1301569895, 1302707100, 1302575298 , 1303934847, 1300526873, 1303934849, 1301340266, 1301328305, 1303390395, 1301233230, 1303390399, 1303934857, 1303934851, 1302188642, 1302188569, 1301282858, 1300526978, 1300860372, 1300613274, 1301602884, 1303390402, 1303934877, 1303127348, 1303934881, 1303390403, 1303928506, 1303934879, 1303390405, 1303934878, 1303928507, 1303934882, 1303934876, 1303934880, 1304240625, 1300772941, 1303934887, 1301233147, 1303390408, 1301233144, 1302266939, 1300732333, 1302665795, 1303390406, 1300738791, 1303934908 , 1303390415, 1304684862, 1304684890, 1303934907, 1303934911, 1303390416, 1303934915, 1301233156, 1303934912, 1303934918, 1301233251, 1303934913, 1301304256, 1302395595, 1300526875, 1300840816, 1302096780, 1302970461, 1302576010, 1302707129, 1302576056, 1302576040, 1302707152, 1302575935, 1303934917, 1303934916, 1303934914, 1304465153, 1301552457, 1300641837, 1303934945, 1303934948, 1303390426, 1302327651, 1301208846, 1300526871, 1303934947, 1300526952, 1300809201, 1301308036, 1300955001, 1301251949 , 1300895571, 1300788549, 1303934949, 1303390425, 1303390424, 1303934951, 1303390427, 1301368393, 1303928524, 1300526951, 1301217010, 1303934950, 1303390428, 1303934952, 1303390429, 1303934940, 1301328514, 1300719296, 1303934956, 1301458974, 1301398105, 1301480940, 1301606395, 1300640305, 1301713844, 1303928501, 1303934863, 1303934858, 1303934859, 1303934860, 1301233179, 1303934861, 1303934865, 1303934866, 1303934867, 1303390400, 1302113902, 1303987143, 1301159112, 1300526874, 1302165994, 1302167025 , 1302022377, 1302022384, 1303928503, 1303934868, 1303928502, 1301889599, 1301843319, 1303255317, 1301548427, 1301351118, 1301365357, 1302076864, 1302071232, 1302071320, 1302067258, 1302067545, 1302081488, 1302077941, 1302036517, 1302002870, 1302496116, 1303934874, 1303934875, 1302370617, 1302349843, 1302329577, 1302322504, 1300641681, 1300526870, 1300640046, 1300672706, 1301713833, 1302621947, 1302267010, 1300613266, 1302332989, 1302349456, 1301713837, 1301533902, 1301873890, 1300526924, 1300526891 , 1300671912, 1300613225, 1301798189, 1300962035, 1302095349, 1302095662, 1300880599, 1301713777, 1303018748, 1302937322, 1302266685, 1302266675, 1303937966, 1303937965, 1302509097, 1302509129, 1302266709, 1301440406, 1302117277, 1302439700, 1301446355, 1301713796, 1301713789, 1300880601, 1303937963, 1303937960, 1303934870, 1300526872, 1300526903, 1302266970, 1300526968, 1301713605, 1300526900, 1301713619, 1300526904, 1301713626, 1300526907, 1301713633, 1300526908, 1301713636, 1300526910, 1301713641 , 1300526897, 1301713666, 1300526909, 1301713683, 1300526899, 1301713690, 1300526895, 1301713696, 1300526906, 1301713704, 1300526911, 1301713707, 1300526898, 1301713710, 1300526896, 1301713714, 1301103118, 1302395748, 1302326348, 1302326351, 1300887357, 1300526926, 1302446752, 1300733648, 1302719534, 1303934955, 1303994872, 1300814131, 1303928527, 1303934957, 1303934958, 1303934959, 1303554628, 1303934960, 1303934961, 1303934962, 1301461374, 1303934963, 1303934965, 1302266718, 1302065616, 1301233150 , 1303928528, 1303934964, 1300984457, 1303390433, 1300968336, 1303934856, 1301416058, 1303934848, 1303934855, 1303934853, 1300865436, 1300882498, 1302918808, 1302918806, 1300964928, 1303341499, 1301266603, 1301435858, 1303408995, 1303053318, 1302848881, 1304730704, 1302865768, 1302972115, 1303596293, 1303596284, 1303597608, 1303597611, 1303597697, 1303597699, 1303559053, 1303559031, 1303598092, 1303598094, 1303590191, 1303590260, 1301713799, 1301170333, 1302267157, 1301699722, 1300641683, 1302962287 , 1300526880, 1302267218, 1301912377, 1302399162, 1302399144, 1300808349, 1300526921, 1301231455, 1301845486, 1302391580, 1302391577, 1304459357, 1303928504, 1303995289, 1301713829, 1300996758, 1303934871, 1303934872, 1301713586, 1300526901, 1301713590, 1300526902, 1301713596, 1302297017, 1301837274, 1303468375, 1303468368, 1304189103, 1302630256, 1303008171, 1300963092, 1303008361, 1303928525, 1303456033, 1303934832, 1303390390, 1303934834, 1303934836, 1301430091, 1300526876, 1303958943, 1303928500 , 1303934837, 1303934838, 1303934833, 1301340215, 1300526935, 1301521962, 1303934839, 1303934835, 1303934840, 1303934841, 1303934843, 1303934844, 1303390392, 1300641863, 1304045103, 1304155515, 1304155506, 1304149224, 1304149221, 1303441005, 1303441001, 1304155455, 1304155452, 1302599891, 1302599907, 1300570688, 1300674471, 1302431569, 1302012076, 1301649493, 1301713863, 1300567854, 1300808347, 1300526869, 1303934946, 1303436098, 1303928523, 1301233235, 1301214467, 1303934942, 1300786700, 1303570059 , 1303934941)
    AND HISTO_INDEX.SICOVAM                       IN (1303390422, 1301320095, 1301464421, 1303934937, 1303390423, 1303934939, 1301297073, 1301554191, 1301851233, 1302266711, 1301696931, 1301713856, 1301442250, 1304305010, 1304304690, 1301713869, 1301418398, 1301696843, 1302266623, 1302034197, 1301730640, 1302034187, 1301837296, 1303218754, 1304177106, 1304177102, 1304244438, 1304244440, 1304045111, 1304301197, 1302266792, 1302266948, 1302293980, 1301609471, 1302720566, 1302533854, 1301713805, 1301446426, 1302266668, 1300526881 , 1300673147, 1300613209, 1300526889, 1300613211, 1300613214, 1300671904, 1300671908, 1300613227, 1300526923, 1300613217, 1300613218, 1300613221, 1301713581, 1300526890, 1300671909, 1300613222, 1301874826, 1301873348, 1300526953, 1300658219, 1300526973, 1301178202, 1300526945, 1300613280, 1301340236, 1303934920, 1300808339, 1300526914, 1303390419, 1303928515, 1303934919, 1301477568, 1303934921, 1300973119, 1300658226, 1303934924, 1303928516, 1302456418, 1300526929, 1300641001, 1300526867, 1300641810 , 1300526868, 1301318237, 1303928517, 1302266902, 1301108114, 1303449497, 1301233163, 1303598379, 1303598175, 1303598179, 1303598134, 1303598137, 1303598153, 1303598155, 1303558847, 1303558420, 1303598280, 1303598282, 1303590525, 1303590528, 1300677240, 1300678132, 1300641658, 1301172311, 1300677137, 1300679918, 1300677362, 1300679764, 1300677462, 1300677774, 1300680110, 1303862022, 1303934862, 1301160858, 1301208264, 1301398074, 1301233241, 1303390432, 1303390430, 1301231477, 1303390431, 1301408697 , 1303928526, 1303934953, 1302092726, 1302092350, 1303934954, 1301583287, 1302651898, 1301608169, 1300753766, 1302651880, 1302438246, 1302651891, 1302326338, 1302326328, 1302326368, 1302326359, 1301843692, 1302671778, 1301920361, 1302395744, 1302650354, 1301843693, 1302438286, 1303934894, 1303934893, 1303390413, 1300683223, 1301340262, 1303934892, 1303928513, 1303390412, 1303934889, 1302322625, 1302322621, 1303928514, 1303390414, 1303785757, 1303785510, 1303934895, 1303934896, 1303934900, 1303934897 , 1303934898, 1303934899, 1303934901, 1303934902, 1303934903, 1303934905, 1300641888, 1300526927, 1303934906, 1303934904, 1300526905, 1301713742, 1300526912, 1300935734, 1301348215, 1301375400, 1302267105, 1300613265, 1301713821, 1300674416, 1303928505, 1304331862, 1301366215, 1301346912, 1301480968, 1302529466, 1303239738, 1302464089, 1302709607, 1302545660, 1301000793, 1300998810, 1300998812, 1300998814, 1300998819, 1302162085, 1301002780, 1301003034, 1302319135, 1301345229, 1303866237, 1301295497 , 1302562288, 1302932615, 1303208772, 1303928510, 1303934883, 1303934884, 1303390410, 1303390409, 1303934888, 1302755702, 1303050639, 1303934886, 1301233172, 1303928508, 1303994911, 1300641820, 1300526981, 1301011228, 1300641813, 1300526930, 1302936701, 1303928509, 1303934890, 1302382897, 1300526878, 1301304254, 1303390411, 1303862026, 1301354908, 1301538055, 1303928511, 1303928512, 1303934891, 1300470839, 1300350715, 1303928518, 1302266797, 1301369127, 1300526866, 1303934926, 1303934925, 1303934927 , 1303934928, 1303934929, 1303934930, 1303934934, 1303928519, 1303934931, 1303934932, 1303934936, 1303438058, 1303934933, 1302266742, 1300613268, 1303934935, 1303390420, 1303928520, 1300961764, 1303934938, 1303390421, 1303928522, 1301344792, 1300567868, 1302266725, 1301790817, 1303934842, 1303934845, 1303390398, 1303934852, 1303934850, 1303934846, 1303934854, 1301323121, 1300844238, 1303006554, 1300734703, 1304505043, 1300882436, 1303041774, 1300776915, 1301572642, 1301569895, 1302707100, 1302575298 , 1303934847, 1300526873, 1303934849, 1301340266, 1301328305, 1303390395, 1301233230, 1303390399, 1303934857, 1303934851, 1302188642, 1302188569, 1301282858, 1300526978, 1300860372, 1300613274, 1301602884, 1303390402, 1303934877, 1303127348, 1303934881, 1303390403, 1303928506, 1303934879, 1303390405, 1303934878, 1303928507, 1303934882, 1303934876, 1303934880, 1304240625, 1300772941, 1303934887, 1301233147, 1303390408, 1301233144, 1302266939, 1300732333, 1302665795, 1303390406, 1300738791, 1303934908 , 1303390415, 1304684862, 1304684890, 1303934907, 1303934911, 1303390416, 1303934915, 1301233156, 1303934912, 1303934918, 1301233251, 1303934913, 1301304256, 1302395595, 1300526875, 1300840816, 1302096780, 1302970461, 1302576010, 1302707129, 1302576056, 1302576040, 1302707152, 1302575935, 1303934917, 1303934916, 1303934914, 1304465153, 1301552457, 1300641837, 1303934945, 1303934948, 1303390426, 1302327651, 1301208846, 1300526871, 1303934947, 1300526952, 1300809201, 1301308036, 1300955001, 1301251949 , 1300895571, 1300788549, 1303934949, 1303390425, 1303390424, 1303934951, 1303390427, 1301368393, 1303928524, 1300526951, 1301217010, 1303934950, 1303390428, 1303934952, 1303390429, 1303934940, 1301328514, 1300719296, 1303934956, 1301458974, 1301398105, 1301480940, 1301606395, 1300640305, 1301713844, 1303928501, 1303934863, 1303934858, 1303934859, 1303934860, 1301233179, 1303934861, 1303934865, 1303934866, 1303934867, 1303390400, 1302113902, 1303987143, 1301159112, 1300526874, 1302165994, 1302167025 , 1302022377, 1302022384, 1303928503, 1303934868, 1303928502, 1301889599, 1301843319, 1303255317, 1301548427, 1301351118, 1301365357, 1302076864, 1302071232, 1302071320, 1302067258, 1302067545, 1302081488, 1302077941, 1302036517, 1302002870, 1302496116, 1303934874, 1303934875, 1302370617, 1302349843, 1302329577, 1302322504, 1300641681, 1300526870, 1300640046, 1300672706, 1301713833, 1302621947, 1302267010, 1300613266, 1302332989, 1302349456, 1301713837, 1301533902, 1301873890, 1300526924, 1300526891 , 1300671912, 1300613225, 1301798189, 1300962035, 1302095349, 1302095662, 1300880599, 1301713777, 1303018748, 1302937322, 1302266685, 1302266675, 1303937966, 1303937965, 1302509097, 1302509129, 1302266709, 1301440406, 1302117277, 1302439700, 1301446355, 1301713796, 1301713789, 1300880601, 1303937963, 1303937960, 1303934870, 1300526872, 1300526903, 1302266970, 1300526968, 1301713605, 1300526900, 1301713619, 1300526904, 1301713626, 1300526907, 1301713633, 1300526908, 1301713636, 1300526910, 1301713641 , 1300526897, 1301713666, 1300526909, 1301713683, 1300526899, 1301713690, 1300526895, 1301713696, 1300526906, 1301713704, 1300526911, 1301713707, 1300526898, 1301713710, 1300526896, 1301713714, 1301103118, 1302395748, 1302326348, 1302326351, 1300887357, 1300526926, 1302446752, 1300733648, 1302719534, 1303934955, 1303994872, 1300814131, 1303928527, 1303934957, 1303934958, 1303934959, 1303554628, 1303934960, 1303934961, 1303934962, 1301461374, 1303934963, 1303934965, 1302266718, 1302065616, 1301233150 , 1303928528, 1303934964, 1300984457, 1303390433, 1300968336, 1303934856, 1301416058, 1303934848, 1303934855, 1303934853, 1300865436, 1300882498, 1302918808, 1302918806, 1300964928, 1303341499, 1301266603, 1301435858, 1303408995, 1303053318, 1302848881, 1304730704, 1302865768, 1302972115, 1303596293, 1303596284, 1303597608, 1303597611, 1303597697, 1303597699, 1303559053, 1303559031, 1303598092, 1303598094, 1303590191, 1303590260, 1301713799, 1301170333, 1302267157, 1301699722, 1300641683, 1302962287 , 1300526880, 1302267218, 1301912377, 1302399162, 1302399144, 1300808349, 1300526921, 1301231455, 1301845486, 1302391580, 1302391577, 1304459357, 1303928504, 1303995289, 1301713829, 1300996758, 1303934871, 1303934872, 1301713586, 1300526901, 1301713590, 1300526902, 1301713596, 1302297017, 1301837274, 1303468375, 1303468368, 1304189103, 1302630256, 1303008171, 1300963092, 1303008361, 1303928525, 1303456033, 1303934832, 1303390390, 1303934834, 1303934836, 1301430091, 1300526876, 1303958943, 1303928500 , 1303934837, 1303934838, 1303934833, 1301340215, 1300526935, 1301521962, 1303934839, 1303934835, 1303934840, 1303934841, 1303934843, 1303934844, 1303390392, 1300641863, 1304045103, 1304155515, 1304155506, 1304149224, 1304149221, 1303441005, 1303441001, 1304155455, 1304155452, 1302599891, 1302599907, 1300570688, 1300674471, 1302431569, 1302012076, 1301649493, 1301713863, 1300567854, 1300808347, 1300526869, 1303934946, 1303436098, 1303928523, 1301233235, 1301214467, 1303934942, 1300786700, 1303570059 , 1303934941)
    AND HISTO_STOCK.jour     =
        (
                SELECT  MAX(H2.jour)
                FROM    HISTORIQUE H2
                WHERE   H2.sicovam = BASKET.SICOPANIER
                    AND H2.jour IS NOT NULL
        )
    AND HISTO_INDEX.SICOVAM = RIC.sicovam + 0
    AND RIC.sicovam                      IN (1303390422, 1301320095, 1301464421, 1303934937, 1303390423, 1303934939, 1301297073, 1301554191, 1301851233, 1302266711, 1301696931, 1301713856, 1301442250, 1304305010, 1304304690, 1301713869, 1301418398, 1301696843, 1302266623, 1302034197, 1301730640, 1302034187, 1301837296, 1303218754, 1304177106, 1304177102, 1304244438, 1304244440, 1304045111, 1304301197, 1302266792, 1302266948, 1302293980, 1301609471, 1302720566, 1302533854, 1301713805, 1301446426, 1302266668, 1300526881 , 1300673147, 1300613209, 1300526889, 1300613211, 1300613214, 1300671904, 1300671908, 1300613227, 1300526923, 1300613217, 1300613218, 1300613221, 1301713581, 1300526890, 1300671909, 1300613222, 1301874826, 1301873348, 1300526953, 1300658219, 1300526973, 1301178202, 1300526945, 1300613280, 1301340236, 1303934920, 1300808339, 1300526914, 1303390419, 1303928515, 1303934919, 1301477568, 1303934921, 1300973119, 1300658226, 1303934924, 1303928516, 1302456418, 1300526929, 1300641001, 1300526867, 1300641810 , 1300526868, 1301318237, 1303928517, 1302266902, 1301108114, 1303449497, 1301233163, 1303598379, 1303598175, 1303598179, 1303598134, 1303598137, 1303598153, 1303598155, 1303558847, 1303558420, 1303598280, 1303598282, 1303590525, 1303590528, 1300677240, 1300678132, 1300641658, 1301172311, 1300677137, 1300679918, 1300677362, 1300679764, 1300677462, 1300677774, 1300680110, 1303862022, 1303934862, 1301160858, 1301208264, 1301398074, 1301233241, 1303390432, 1303390430, 1301231477, 1303390431, 1301408697 , 1303928526, 1303934953, 1302092726, 1302092350, 1303934954, 1301583287, 1302651898, 1301608169, 1300753766, 1302651880, 1302438246, 1302651891, 1302326338, 1302326328, 1302326368, 1302326359, 1301843692, 1302671778, 1301920361, 1302395744, 1302650354, 1301843693, 1302438286, 1303934894, 1303934893, 1303390413, 1300683223, 1301340262, 1303934892, 1303928513, 1303390412, 1303934889, 1302322625, 1302322621, 1303928514, 1303390414, 1303785757, 1303785510, 1303934895, 1303934896, 1303934900, 1303934897 , 1303934898, 1303934899, 1303934901, 1303934902, 1303934903, 1303934905, 1300641888, 1300526927, 1303934906, 1303934904, 1300526905, 1301713742, 1300526912, 1300935734, 1301348215, 1301375400, 1302267105, 1300613265, 1301713821, 1300674416, 1303928505, 1304331862, 1301366215, 1301346912, 1301480968, 1302529466, 1303239738, 1302464089, 1302709607, 1302545660, 1301000793, 1300998810, 1300998812, 1300998814, 1300998819, 1302162085, 1301002780, 1301003034, 1302319135, 1301345229, 1303866237, 1301295497 , 1302562288, 1302932615, 1303208772, 1303928510, 1303934883, 1303934884, 1303390410, 1303390409, 1303934888, 1302755702, 1303050639, 1303934886, 1301233172, 1303928508, 1303994911, 1300641820, 1300526981, 1301011228, 1300641813, 1300526930, 1302936701, 1303928509, 1303934890, 1302382897, 1300526878, 1301304254, 1303390411, 1303862026, 1301354908, 1301538055, 1303928511, 1303928512, 1303934891, 1300470839, 1300350715, 1303928518, 1302266797, 1301369127, 1300526866, 1303934926, 1303934925, 1303934927 , 1303934928, 1303934929, 1303934930, 1303934934, 1303928519, 1303934931, 1303934932, 1303934936, 1303438058, 1303934933, 1302266742, 1300613268, 1303934935, 1303390420, 1303928520, 1300961764, 1303934938, 1303390421, 1303928522, 1301344792, 1300567868, 1302266725, 1301790817, 1303934842, 1303934845, 1303390398, 1303934852, 1303934850, 1303934846, 1303934854, 1301323121, 1300844238, 1303006554, 1300734703, 1304505043, 1300882436, 1303041774, 1300776915, 1301572642, 1301569895, 1302707100, 1302575298 , 1303934847, 1300526873, 1303934849, 1301340266, 1301328305, 1303390395, 1301233230, 1303390399, 1303934857, 1303934851, 1302188642, 1302188569, 1301282858, 1300526978, 1300860372, 1300613274, 1301602884, 1303390402, 1303934877, 1303127348, 1303934881, 1303390403, 1303928506, 1303934879, 1303390405, 1303934878, 1303928507, 1303934882, 1303934876, 1303934880, 1304240625, 1300772941, 1303934887, 1301233147, 1303390408, 1301233144, 1302266939, 1300732333, 1302665795, 1303390406, 1300738791, 1303934908 , 1303390415, 1304684862, 1304684890, 1303934907, 1303934911, 1303390416, 1303934915, 1301233156, 1303934912, 1303934918, 1301233251, 1303934913, 1301304256, 1302395595, 1300526875, 1300840816, 1302096780, 1302970461, 1302576010, 1302707129, 1302576056, 1302576040, 1302707152, 1302575935, 1303934917, 1303934916, 1303934914, 1304465153, 1301552457, 1300641837, 1303934945, 1303934948, 1303390426, 1302327651, 1301208846, 1300526871, 1303934947, 1300526952, 1300809201, 1301308036, 1300955001, 1301251949 , 1300895571, 1300788549, 1303934949, 1303390425, 1303390424, 1303934951, 1303390427, 1301368393, 1303928524, 1300526951, 1301217010, 1303934950, 1303390428, 1303934952, 1303390429, 1303934940, 1301328514, 1300719296, 1303934956, 1301458974, 1301398105, 1301480940, 1301606395, 1300640305, 1301713844, 1303928501, 1303934863, 1303934858, 1303934859, 1303934860, 1301233179, 1303934861, 1303934865, 1303934866, 1303934867, 1303390400, 1302113902, 1303987143, 1301159112, 1300526874, 1302165994, 1302167025 , 1302022377, 1302022384, 1303928503, 1303934868, 1303928502, 1301889599, 1301843319, 1303255317, 1301548427, 1301351118, 1301365357, 1302076864, 1302071232, 1302071320, 1302067258, 1302067545, 1302081488, 1302077941, 1302036517, 1302002870, 1302496116, 1303934874, 1303934875, 1302370617, 1302349843, 1302329577, 1302322504, 1300641681, 1300526870, 1300640046, 1300672706, 1301713833, 1302621947, 1302267010, 1300613266, 1302332989, 1302349456, 1301713837, 1301533902, 1301873890, 1300526924, 1300526891 , 1300671912, 1300613225, 1301798189, 1300962035, 1302095349, 1302095662, 1300880599, 1301713777, 1303018748, 1302937322, 1302266685, 1302266675, 1303937966, 1303937965, 1302509097, 1302509129, 1302266709, 1301440406, 1302117277, 1302439700, 1301446355, 1301713796, 1301713789, 1300880601, 1303937963, 1303937960, 1303934870, 1300526872, 1300526903, 1302266970, 1300526968, 1301713605, 1300526900, 1301713619, 1300526904, 1301713626, 1300526907, 1301713633, 1300526908, 1301713636, 1300526910, 1301713641 , 1300526897, 1301713666, 1300526909, 1301713683, 1300526899, 1301713690, 1300526895, 1301713696, 1300526906, 1301713704, 1300526911, 1301713707, 1300526898, 1301713710, 1300526896, 1301713714, 1301103118, 1302395748, 1302326348, 1302326351, 1300887357, 1300526926, 1302446752, 1300733648, 1302719534, 1303934955, 1303994872, 1300814131, 1303928527, 1303934957, 1303934958, 1303934959, 1303554628, 1303934960, 1303934961, 1303934962, 1301461374, 1303934963, 1303934965, 1302266718, 1302065616, 1301233150 , 1303928528, 1303934964, 1300984457, 1303390433, 1300968336, 1303934856, 1301416058, 1303934848, 1303934855, 1303934853, 1300865436, 1300882498, 1302918808, 1302918806, 1300964928, 1303341499, 1301266603, 1301435858, 1303408995, 1303053318, 1302848881, 1304730704, 1302865768, 1302972115, 1303596293, 1303596284, 1303597608, 1303597611, 1303597697, 1303597699, 1303559053, 1303559031, 1303598092, 1303598094, 1303590191, 1303590260, 1301713799, 1301170333, 1302267157, 1301699722, 1300641683, 1302962287 , 1300526880, 1302267218, 1301912377, 1302399162, 1302399144, 1300808349, 1300526921, 1301231455, 1301845486, 1302391580, 1302391577, 1304459357, 1303928504, 1303995289, 1301713829, 1300996758, 1303934871, 1303934872, 1301713586, 1300526901, 1301713590, 1300526902, 1301713596, 1302297017, 1301837274, 1303468375, 1303468368, 1304189103, 1302630256, 1303008171, 1300963092, 1303008361, 1303928525, 1303456033, 1303934832, 1303390390, 1303934834, 1303934836, 1301430091, 1300526876, 1303958943, 1303928500 , 1303934837, 1303934838, 1303934833, 1301340215, 1300526935, 1301521962, 1303934839, 1303934835, 1303934840, 1303934841, 1303934843, 1303934844, 1303390392, 1300641863, 1304045103, 1304155515, 1304155506, 1304149224, 1304149221, 1303441005, 1303441001, 1304155455, 1304155452, 1302599891, 1302599907, 1300570688, 1300674471, 1302431569, 1302012076, 1301649493, 1301713863, 1300567854, 1300808347, 1300526869, 1303934946, 1303436098, 1303928523, 1301233235, 1301214467, 1303934942, 1300786700, 1303570059 , 1303934941)
    AND HISTO_INDEX.Jour    = ANY
        (
                SELECT  MAX(H1.Jour)
                FROM    HISTORIQUE H1
                WHERE   H1.sicovam = indx.sicovam
                    AND H1.jour IS NOT NULL
        )
GROUP BY INDX.LIBELLE   ,
        HISTO_INDEX.JOUR,
        HISTO_INDEX.D   ,
        INDX.TAUX       ,
        INDX.NOMINAL    ,
        INDX.modele     ,
        INDX.SICOVAM    ,
        INDX.devisectt  ,
        INDX.REFERENCE  ,
        INDX.MNEMO_V2   ,
        INDX.QUOTITE    ,
        INDX.MARCHE     ,
        ric.reuter
ORDER BY INDX.LIBELLE