• Hi Ryan,

    the following example shows how to take values from a namespace.

    declare

    @x xml

    set

    @x = '

    <ns0:root xmlns:ns0="http://schemas.microsoft.com/sqlserver/2004/

    07/adventure-works/ProductModelManuInstructionsModified">

    <ns0:Location LocationID="100" SetupHours="10.4"

    MachineHours="10.4" LaborHours="10.4" LotSize="10.4" />

    </ns0:root>'

    select

    x

    .ns.value('@LocationID[1]', 'varchar(10)') as LocationID

    from

    @x

    .nodes('declare namespace ns0="http://schemas.microsoft.com/sqlserver/2004/

    07/adventure-works/ProductModelManuInstructionsModified";/ns0:root/ns0:Location'

    ) as x(ns)

    .