Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi all, Is it possible to read data from database field with XML type?
Hi,
Yes it's possible. Add a new table from a file, select your xml file and select XML if Qlikview doesn't recognize it.
You also can load XML from web API.
Thanks Christopher, But is it possibe to read data from the database from field with XML data type? For example i have a table in the SQL Server, like CustomerInfo:
Customer (varchar 40)
Info (xml)
Info value:
<customer id = 111>
<address>aaaaa</address>
<position>bbbb</position>
</customer>
From the example above I need to get data from address and position attributes...
Hi Konstantin,
I just use TextBetween function to return whatever is between '<address>' and '</address>' and use it as a field. Turns the db:
Customer | XML |
111 | <customer id = 111> <address>aaaa</address> <position>bbbb</position> </customer> |
112 | <customer id = 112> <address>cccc</address> <position>dddd</position> </customer> |
into straight table:
Customer | Address | Position |
111 | aaaa | bbbb |
112 | cccc | dddd |
anyone got this working? i too have a xml field in a database and want to extract some data.
I know TEXTBETWEEN, but with this, you first have to get the whole xml field over using SQL SELECT.
I would like to get my text right in the SQL SELECT. This is much more efficient.
I checked google, but we are on ODBC level here. So not all SQL statements are possible.
did you ever get an answer to this question?
Nope .. still looking for the answer .. Don't have solution or workaround yet
Thanks for the reply.
Access the menu script and search for the file by the command "FILES TABLE", load only one file so that the structure QLIKVIEW read this file and create a map. If other files have different fields, add these fields using as reference the map created in the script.
Change the the file path excluding the file name and indicate only the destination folder of all files to be loaded with the expression \ *. Xml.
If the file contains more than one table that requires connection, using the file name to create a key between the tables:
FileName (FILE) as key.