I've got that code underneath, and I get the XDMP-CONFLICTINGUPDATES Exception. 
In the exception description they are talking about semi-columns... Do you know 
some example using that semi-column approach which can help me inserting my 
temporal records?

https://help.marklogic.com/knowledgebase/article/View/25/16/xdmp-conflictingupdates-and-how-to-avoid-it

xquery version "1.0-ml";
import module namespace temporal = "http://marklogic.com/xdmp/temporal"; at 
"/MarkLogic/temporal.xqy";
declare namespace html = "http://www.w3.org/1999/xhtml";;
let $rawDocument:= fn:doc("/docs/requete_perf_abs_20170307small.txt")
let $rows := fn:tokenize($rawDocument, ";")
let $rowCount := count($rows)
for $currentRowIndex in 1 to $rowCount -1
  let $currentRow := $rows[$currentRowIndex]
  let $currentRowColumns := fn:tokenize($currentRow,",")
  let $generatedNodeNamspace := 
fn:concat($currentRowColumns[1],'-',$currentRowColumns[2],'-',$currentRowColumns[3],'-',$currentRowColumns[20],'.xml')
  let $generatedNode :=<RiskMetricsOutput>
              <ClientPositionId>{$currentRowColumns[1]}</ClientPositionId>
              <SicavId>{$currentRowColumns[2]}</SicavId>
              <RMG_PositionName>{$currentRowColumns[3]}</RMG_PositionName>
              <clientPortfolioId>{$currentRowColumns[4]}</clientPortfolioId>
              <Poche>{$currentRowColumns[5]}</Poche>
              <PochePere>{$currentRowColumns[6]}</PochePere>
              <AssetType>{$currentRowColumns[7]}</AssetType>
              <Coverred>{$currentRowColumns[8]}</Coverred>
              <RattingIssuer>{$currentRowColumns[9]}</RattingIssuer>
              <Subordonnee>{$currentRowColumns[10]}</Subordonnee>
              <TypeTauxObligation>{$currentRowColumns[11]}</TypeTauxObligation>
              <SecType>{$currentRowColumns[12]}</SecType>
              <Currency>{$currentRowColumns[13]}</Currency>
              <Sector>{$currentRowColumns[14]}</Sector>
              <Pays>{$currentRowColumns[15]}</Pays>
              <PaysRisque>{$currentRowColumns[16]}</PaysRisque>
              <PilierDevMaturity>{$currentRowColumns[17]}</PilierDevMaturity>
              <TypeCollat>{$currentRowColumns[18]}</TypeCollat>
              <Indicateur>{$currentRowColumns[19]}</Indicateur>
              <idDate_Fk>{$currentRowColumns[20]}</idDate_Fk>
              <mesure>{$currentRowColumns[21]}</mesure>
              <date_Insertion>{$currentRowColumns[22]}</date_Insertion>
              <validStart/>
              <validEnd/>
              <systemStart/>
              <systemEnd/>
            </RiskMetricsOutput>
  return 
temporal:document-insert("risk-metrics-temporality",$generatedNodeNamspace,$generatedNode);


----------------------------------------------------------------------------------------------------------
Ce message et toutes les pièces jointes sont confidentiels. Il est établi à 
l'attention exclusive de son ou ses destinataire(s). Toute utilisation de ce 
message non conforme à sa destination, toute diffusion ou toute publication, 
totale ou partielle, est interdite, sauf autorisation expresse préalable. Son 
contenu ne saurait constituer en aucun cas un engagement contractuel, une offre 
de souscrire à quelconque produit ou instrument financier ou une sollicitation 
à investir de la part de Le Groupe La Française et toutes opinions exprimées 
dans ce message ne sauraient nécessairement refléter celle de Le Groupe La 
Française. L'intégrité de ce message n'étant pas assurée sur Internet, Le 
Groupe La Française ne saurait être responsable de son contenu.
Si vous recevez ce courriel par erreur, merci de le détruire et d'en avertir 
immédiatement l'expéditeur. Mentions légales disponibles sur le site Internet 
du Groupe à l?adresse : http://www.lafrancaise-group.com/mentions-legales.html
----------------------------------------------------------------------------------------------------------
This email and any attachment are confidential and may be legally privileged or 
otherwise protected from disclosure. It is intended only for the stated 
addressee(s). Any use, dissemination or disclosure not in accordance with its 
purpose, either in whole or in part, is prohibited without our prior formal 
approval. Its contents, given solely for information, does not constitute a 
commitment or an offer to subscribe to any financial product by Le Groupe La 
Française any opinion expressed in this email may not necessarily reflect the 
opinion of Le Groupe La Française. The integrity of this email cannot be 
guaranteed through internet, Le Groupe La Française therefore is in no way 
liable for any errors or omissions in the content of this message. If you are 
neither the addressee nor an authorized recipient of this message, please 
notify the sender of receipt and delete this message from your system.
Terms of use available on the Group?s website at 
http://www.lafrancaise-group.com/en/terms-of-use.html
_______________________________________________
General mailing list
[email protected]
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general

Reply via email to