久久久久久久av_日韩在线中文_看一级毛片视频_日本精品二区_成人深夜福利视频_武道仙尊动漫在线观看

      • <bdo id='H5ZEX'></bdo><ul id='H5ZEX'></ul>
    1. <i id='H5ZEX'><tr id='H5ZEX'><dt id='H5ZEX'><q id='H5ZEX'><span id='H5ZEX'><b id='H5ZEX'><form id='H5ZEX'><ins id='H5ZEX'></ins><ul id='H5ZEX'></ul><sub id='H5ZEX'></sub></form><legend id='H5ZEX'></legend><bdo id='H5ZEX'><pre id='H5ZEX'><center id='H5ZEX'></center></pre></bdo></b><th id='H5ZEX'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='H5ZEX'><tfoot id='H5ZEX'></tfoot><dl id='H5ZEX'><fieldset id='H5ZEX'></fieldset></dl></div>
      <tfoot id='H5ZEX'></tfoot>

      <small id='H5ZEX'></small><noframes id='H5ZEX'>

        <legend id='H5ZEX'><style id='H5ZEX'><dir id='H5ZEX'><q id='H5ZEX'></q></dir></style></legend>

      1. SQL Server 中的 XML 解析

        XML Parsing in SQL Server(SQL Server 中的 XML 解析)
          <tfoot id='ZIFhC'></tfoot>

                • <bdo id='ZIFhC'></bdo><ul id='ZIFhC'></ul>
                  <legend id='ZIFhC'><style id='ZIFhC'><dir id='ZIFhC'><q id='ZIFhC'></q></dir></style></legend>
                • <small id='ZIFhC'></small><noframes id='ZIFhC'>

                  <i id='ZIFhC'><tr id='ZIFhC'><dt id='ZIFhC'><q id='ZIFhC'><span id='ZIFhC'><b id='ZIFhC'><form id='ZIFhC'><ins id='ZIFhC'></ins><ul id='ZIFhC'></ul><sub id='ZIFhC'></sub></form><legend id='ZIFhC'></legend><bdo id='ZIFhC'><pre id='ZIFhC'><center id='ZIFhC'></center></pre></bdo></b><th id='ZIFhC'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='ZIFhC'><tfoot id='ZIFhC'></tfoot><dl id='ZIFhC'><fieldset id='ZIFhC'></fieldset></dl></div>

                    <tbody id='ZIFhC'></tbody>
                  本文介紹了SQL Server 中的 XML 解析的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學習吧!

                  問題描述

                  限時送ChatGPT賬號..

                  要求解析與 MarginRevenue/Cost/Value 相關的所有 27 個值.作為標準方案,這些元素可以按任意順序出現(xiàn),也可以出現(xiàn)任意次數(shù).簡而言之,XML 是完全動態(tài)的.唯一的一點是 Under Margins/Margin,可以有任意數(shù)量的 MarginRevenue、MarginCost 和 MarginValue.

                  The requirement is to parse all the 27 values related to MarginRevenue/Cost/Value. As a standard scenario, these elements can come in any order and also can come in any number of time. In short, the XML is completely dynamic. The only point is Under Margins/Margin, there can be any number of MarginRevenue, MarginCost and MarginValue.

                  declare @xml xml = '<Margins>
                  <Margin type="type1" currencyCode="currencyCode1"> 
                  <MarginRevenue>1.1</MarginRevenue> 
                  <MarginRevenue>1.2</MarginRevenue> 
                  <MarginRevenue>1.3</MarginRevenue> 
                  <MarginCost>2.1</MarginCost> 
                  <MarginCost>2.2</MarginCost> 
                  <MarginCost>2.3</MarginCost> 
                  <MarginValue>3.1</MarginValue> 
                  <MarginValue>3.2</MarginValue> 
                  <MarginValue>3.3</MarginValue> </Margin> 
                  <Margin type="type2"  currencyCode="currencyCode2"> 
                  <MarginRevenue>1.4</MarginRevenue> 
                  <MarginRevenue>1.5</MarginRevenue> 
                  <MarginRevenue>1.6</MarginRevenue> 
                  <MarginCost>2.4</MarginCost> 
                  <MarginCost>2.5</MarginCost> 
                  <MarginCost>2.6</MarginCost> 
                  <MarginValue>3.4</MarginValue> 
                  <MarginValue>3.5</MarginValue> 
                  <MarginValue>3.6</MarginValue> </Margin> 
                  <Margin type="type3" currencyCode="currencyCode3"> 
                  <MarginRevenue>1.7</MarginRevenue> 
                  <MarginRevenue>1.8</MarginRevenue> 
                  <MarginRevenue>1.9</MarginRevenue> 
                  <MarginCost>2.7</MarginCost> 
                  <MarginCost>2.8</MarginCost> 
                  <MarginCost>2.9</MarginCost> 
                  <MarginValue>3.7</MarginValue> 
                  <MarginValue>3.8</MarginValue> 
                  <MarginValue>3.9</MarginValue> </Margin>
                  </Margins>'
                  

                  推薦答案

                  不太清楚您要實現(xiàn)的目標/想要獲得的目標 - 但此 XQuery 將為您返回所有 27 個值:

                  Not quite clear what you're trying to achieve / what you're looking to get - but this XQuery will return all 27 values for you:

                  SELECT
                      Name = XC.value('local-name(.)', 'varchar(100)'),
                      Value = XC.value('.', 'varchar(100)')
                  FROM
                      @xml.nodes('/Margins/Margin/*') AS XT(XC)
                  

                  SSMS 中的結果:

                  這篇關于SQL Server 中的 XML 解析的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網(wǎng)!

                  【網(wǎng)站聲明】本站部分內(nèi)容來源于互聯(lián)網(wǎng),旨在幫助大家更快的解決問題,如果有圖片或者內(nèi)容侵犯了您的權益,請聯(lián)系我們刪除處理,感謝您的支持!

                  相關文檔推薦

                  SQL query to get all products, categories and meta data woocommerce/wordpress(獲取所有產(chǎn)品、類別和元數(shù)據(jù)的 SQL 查詢 woocommerce/wordpress)
                  Can I figure out a list of databases and the space used by SQL Server instances without writing SQL queries?(我可以在不編寫 SQL 查詢的情況下找出數(shù)據(jù)庫列表和 SQL Server 實例使用的空間嗎?) - IT屋-程序員軟件開發(fā)
                  How to create a login to a SQL Server instance?(如何創(chuàng)建對 SQL Server 實例的登錄?)
                  How to know the version and edition of SQL Server through registry search(如何通過注冊表搜索知道SQL Server的版本和版本)
                  Why do I get a quot;data type conversion errorquot; with ExecuteNonQuery()?(為什么會出現(xiàn)“數(shù)據(jù)類型轉換錯誤?使用 ExecuteNonQuery()?)
                  How to show an image from a DataGridView to a PictureBox?(如何將 DataGridView 中的圖像顯示到 PictureBox?)

                  <i id='RllBF'><tr id='RllBF'><dt id='RllBF'><q id='RllBF'><span id='RllBF'><b id='RllBF'><form id='RllBF'><ins id='RllBF'></ins><ul id='RllBF'></ul><sub id='RllBF'></sub></form><legend id='RllBF'></legend><bdo id='RllBF'><pre id='RllBF'><center id='RllBF'></center></pre></bdo></b><th id='RllBF'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='RllBF'><tfoot id='RllBF'></tfoot><dl id='RllBF'><fieldset id='RllBF'></fieldset></dl></div>
                    <bdo id='RllBF'></bdo><ul id='RllBF'></ul>
                    <legend id='RllBF'><style id='RllBF'><dir id='RllBF'><q id='RllBF'></q></dir></style></legend>
                      <tbody id='RllBF'></tbody>

                    <small id='RllBF'></small><noframes id='RllBF'>

                    <tfoot id='RllBF'></tfoot>

                            主站蜘蛛池模板: 午夜精品久久 | 欧美h | 日日干夜夜草 | 日本中文字幕在线观看 | 91免费福利视频 | 午夜专区 | 国产精品一区二 | 久久久精品一区 | 欧美成人专区 | 久久精品一区二区三区四区 | 交专区videossex农村 | 中文字幕 国产精品 | 99精品一区二区三区 | 国产一区二区三区久久久久久久久 | 国产精品欧美日韩 | 少妇诱惑av | 日韩精品在线免费观看视频 | 国产自产21区 | 婷婷成人在线 | 久久伊人操 | 香蕉视频黄色 | 欧美二区乱c黑人 | 搞av.com| 亚洲一区二区av | 日韩影院一区 | 91天堂网 | 一区二区三区不卡视频 | 欧美国产视频 | 久久久久久999| 一区二区视频在线 | 粉嫩av | 亚av在线| 亚洲综合色视频在线观看 | 精品一区二区三区91 | www狠狠爱com | 国内精品视频一区二区三区 | 精品成人一区二区 | 亚洲精品欧美一区二区三区 | 99久久精品国产毛片 | 久久激情网 | 另类二区|