Quantcast
Channel: Transact-SQL forum
Viewing all articles
Browse latest Browse all 23857

Transform xml in column

$
0
0

Hi,

I wrote a Clr who returns an SqlXml object that i need to transform,

here's the query and the result i have

Select top 1 id_RefPdr, RefCln, Ncl, IT.dbo.Clr_NclSplitByMask(MasqeTri, Ncl, AM_R2.dbo.FN_NCL_NCLUNQPOS(Ncl))
From dbo.REFS_PDR
Where LibRef = 'Amortisseur'

the result:

6927A890 Hydraulique; Bitube; Automatique; Données PSE30/13X100A; Oeil/Tige; Vérin<DocumentElement><dtaMask><_x0032_8>-</_x0032_8><_x0032_8.5>PREMIUM</_x0032_8.5><Hydraulique>Hydraulique</Hydraulique><GAZ>-</GAZ><Bitube>Bitube</Bitube><Monotube>-</Monotube><Inf._x002A__x002F_Sup_x002A_>-</Inf._x002A__x002F_Sup_x002A_><Inf._x002A_>-</Inf._x002A_><Sup._x002A_>-</Sup._x002A_><L._x0040_mm.>-</L._x0040_mm.><L._x0040__x002F__x0040_mm.>-</L._x0040__x002F__x0040_mm.><D._x0040_mm.>-</D._x0040_mm.><D1._x0040_mm.>-</D1._x0040_mm.><D2._x0040_mm.>-</D2._x0040_mm.><D.Tige_x0020__x0040_mm.>-</D.Tige_x0020__x0040_mm.><D.Oeil_x0020__x0040_mm.>-</D.Oeil_x0020__x0040_mm.><Larg.Oeil_x0020__x0040_mm.>-</Larg.Oeil_x0020__x0040_mm.><Larg1._x0040_mm.>-</Larg1._x0040_mm.><Larg2._x0040_mm.>-</Larg2._x0040_mm.><HorsMasque>Automatique; Données PSE30/13X100A; Oeil/Tige; Vérin</HorsMasque></dtaMask></DocumentElement>

The xml is a one row datatable with multiple columns.

What I want to do is to get the result like this

69102027A890Hydraulique; Bitube; Automatique; Données PSE30/13X100A; Oeil/Tige; Vérin-- Hydraulique- Bitube- ----- ----- ---Automatique; Données PSE30/13X100A; Oeil/Tige; Vérin

Is there a simple method to do that or do i need to reconsider my approach.

Any help would be appreciated


Viewing all articles
Browse latest Browse all 23857

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>