Can you not:
declare @foo as xml
set @foo=N'
<transactions>
<accountno>123456789</accountno>
<name>dan</name>
</transactions>'
SELECT
bar.value('AccountNo[1]', 'varchar(20)') AS AccountNo ,
bar.value('Name[1]', 'varchar (20)') AS Name
FROM @foo.nodes('/Transactions')
xmlData( bar )
(Or have I missed something)