Fabric is Generally Available. Browse Fabric Presentations. Work towards your Fabric certification with the Cloud Skills Challenge.
We are trying to extract Incident ticket data from ServiceNow to Power BI using Rest API. We are able to bring Incident tickets data from ServiceNow but our client requirement is,
We have Table called ‘X’ in Power BI and in that table have Incident number column and which is having latest to 2 year old data.
Now we need to have functionality like, pick the incident number from X table and that Ticket number should validate and bring matching data from ServiceNow RESTAPI. It means, whatever the data we have in X table only those incidents should come from ServiceNow REST API.
Solved! Go to Solution.
Hi @Anonymous
Currently, you are succeed to get data from ServiceNow to Power BI using Rest API. Now your requirement is to filter data by incident number in Table X. Try to update your api to invoke incident number list from Table X.
Here I a sample query to get version from sharepoint by api.
let
Source = (VersionsRelevantSharePointListName as text, VersionsRelevantSharePointLocation as text, VersionsRelevantItemID as number) => let
Source = Xml.Tables(Web.Contents(Text.Combine({
VersionsRelevantSharePointLocation,
"/_api/web/Lists/getbytitle('",
VersionsRelevantSharePointListName ,
"')/items(",
Text.From(VersionsRelevantItemID),
")/versions"}
))),
entry = Source{0}[entry],
#"Removed Other Columns2" = Table.SelectColumns(entry,{"content"}),
#"Expanded content" = Table.ExpandTableColumn(#"Removed Other Columns2", "content", {"http://schemas.microsoft.com/ado/2007/08/dataservices/metadata"}, {"content"}),
#"Expanded content1" = Table.ExpandTableColumn(#"Expanded content", "content", {"properties"}, {"properties"}),
#"Expanded properties" = Table.ExpandTableColumn(#"Expanded content1", "properties", {"http://schemas.microsoft.com/ado/2007/08/dataservices"}, {"properties"})
in
#"Expanded properties"
in
Source
It looks like as below.
Invoke list with this query and add parameters into query, then expand the table to get your result.
So you just need to filter incident number list from X table to filter the result in power query.
Best Regards,
Rico Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hello,
Much easier way would be using out Power BI Connector for ServiceNow app:
We have a handy User and Admin Guides for your convenience, but feel free to reach out support team at support@alpha-serve.com if you need any assistance.
Thank you.
Regards,
Anton
===
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Anonymous
Currently, you are succeed to get data from ServiceNow to Power BI using Rest API. Now your requirement is to filter data by incident number in Table X. Try to update your api to invoke incident number list from Table X.
Here I a sample query to get version from sharepoint by api.
let
Source = (VersionsRelevantSharePointListName as text, VersionsRelevantSharePointLocation as text, VersionsRelevantItemID as number) => let
Source = Xml.Tables(Web.Contents(Text.Combine({
VersionsRelevantSharePointLocation,
"/_api/web/Lists/getbytitle('",
VersionsRelevantSharePointListName ,
"')/items(",
Text.From(VersionsRelevantItemID),
")/versions"}
))),
entry = Source{0}[entry],
#"Removed Other Columns2" = Table.SelectColumns(entry,{"content"}),
#"Expanded content" = Table.ExpandTableColumn(#"Removed Other Columns2", "content", {"http://schemas.microsoft.com/ado/2007/08/dataservices/metadata"}, {"content"}),
#"Expanded content1" = Table.ExpandTableColumn(#"Expanded content", "content", {"properties"}, {"properties"}),
#"Expanded properties" = Table.ExpandTableColumn(#"Expanded content1", "properties", {"http://schemas.microsoft.com/ado/2007/08/dataservices"}, {"properties"})
in
#"Expanded properties"
in
Source
It looks like as below.
Invoke list with this query and add parameters into query, then expand the table to get your result.
So you just need to filter incident number list from X table to filter the result in power query.
Best Regards,
Rico Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Add a custom column to your table, construct the URL for the incident in each row and then use Web.Contents to pull the individual records. Then expand that new column as needed. Is the data in XML or in JSON?
Check out the November 2023 Power BI update to learn about new features.
Read the latest Fabric Community announcements, including updates on Power BI, Synapse, Data Factory and Data Activator.
User | Count |
---|---|
7 | |
2 | |
1 | |
1 | |
1 |
User | Count |
---|---|
9 | |
2 | |
2 | |
2 | |
2 |