How to create Measures using Dynamics 365 Customer Insights


Virendra Agrawal's avatarVirendra Agrawal's Blog

In my previous post, we talked about ingesting the data from various sources with the help of different Dynamics Power Query Connectors and use this data to perform unification in Customer Insights and build a unique customer profile (Part 1 and Part 2).

In continuation of the previous posts, let’s see how we can ingest the purchase (eCommerce or POS) data associated with these unique customer profiles to build various measures in Customer Insights.

Before we begin, let’s understand what measures are and how these are useful.

Measures represent as the “Key Performance Indicators” (KPI’s) that we can define to keep a track of our Customer or Business performance. By setting these KPI’s or measures, we can set goals that we would want to achieve, monitor the actual outcomes from the unified customer profile within Customer Insights and act whenever needed to ensure we meet the goals.

Prerequisites:

View original post 1,205 more words

Fixed – There was an error calculating dependency for this component. Missing component id error while trying to import a solution in Dynamics 365


We got the below error while trying to import the solution.

The error indicates that either the component with the specified GUID in the error message is either missing in the solution or is missing in the target environment.

Search for the GUID either in the customization.xml or solutions.xml to find the component.

Add the missing component in the solution and try the import again.

Or remove the dependency to that component from the source solution.

In our case, it was the Quick View Form referred to in one of the entity’s form but not included in the solution. We added the Quick View Form in our solution and tried the import which worked.

We could have also removed the quick view form from the entity’s form (if the component was not needed) and tried the import.

Hope it helps..

Fixed – Object reference not set to an instance of an object error while calling an Action in Dynamics 365


Recently in one of our JavaScripts which was calling an action (with a plugin registered to it) was giving us the below error.

We had a plugin registered on the call of that action, which in turn was calling an external service.

We figured out the probable cause of this error (related to certificates) and updated the plugin code accordingly on the server.

Unfortunately, this didn’t fix the issue for us, we also tried different possible solutions but to no avail.

As a last resort, we thought of giving this a try – deactivate and activate the Action, and to our surprise that did the trick.

Our thought is maybe Action was somehow still referring to the old plugin code, and the step of deactivating/activating the Action kind of cleared the cache or something, making action to refer to the latest plugin code deployed.

Hope it helps..

Advertisements

Fixed – Column names in each table must be unique. Column name ‘x’ in table ‘y’ is specified more than once while importing solution in Dynamics 365


Recently while trying to import the solution we got the below error.

Below was the outcome of our analysis

  • The column or the field referred to in the error message was not available in the CRM application i.e. customizations – default solution was not having this attribute.
  • The column was only available in the base table of the entity.
  • The column was not available in the filtered view of that entity.
  • The column was not available in the MetadataSchema.Attribute table.
  • We had around 50 such columns in the base table of the entity.

In short, the field was only available in the base table and wasn’t available anywhere else, which could have been the result of the solution being deleted at some point in time, followed by the wrong restoration of the table (i.e. unsupported change to the database).

We raised the Microsoft Support for the same, and the way we resolved the issue was by dropping/deleting those columns from the base table, followed by running the solution import which went successful this time. (fortunately the fields were all blank – null or default value)

ALTER TABLE “table_name” DROP “column_name”;

We can also get this error if we have a field with same schema name as source field created in the target environment (created manually / directly there). In this case also either we can remove the field from the source environment’s solution file or we can delete the field from the target environment.

Hope it helps..

 

Pause and resume enhancements in SLA in Dynamics 365 – 2020 Release Wave 2


The way we currently configure Pause and Resume for an SLA is by setting the Allow Pause and Resume field to Allow.

And within the Service Tab of System Settings, we can define the status values on which the SLA calculation should get paused at the entity level.

So basically, the SLA will be paused for the case record with status as either On Hold and Waiting for Details as we have defined below.

As soon as we change the status to Researching, the timer resumes

With 2020 Release Wave 2, we can now configure Pause Criteria at the SLA Item level, which overrides the criteria defined at the SLA / Entity level as defined above.

Toggle Override Criteria field

We can define the criteria as shown below using the condition builder.

Here we have defined the condition for SLA to be paused in case of case type Request.

Save and activate the SLA.

Let us now create a new case to see it in action.

We can see the SLA timer running.

Update the case type to Request and save.

As expected, we can see the SLA paused

Check other blog posts on Release 2020 Wave 2

Hope it helps..

JWT – JSON Web Token – Introduction


As we know, HTTP is a stateless protocol where each request is treated as an independent request. For rendering static web page, this could still be fine, but what if the web application needs to track a user across multiple requests.That is where Session and state management came to the picture. The server will authenticate the user and if it’s a valid request, the server will save the session id and return the same to the client. The client can pass this session-id for any subsequent request. The server will check for the session id and will process the request for the client.

With server-side session management, scalability can be a challenge, say we have a load-balanced scenario, the user sends a session id in the request which goes to a different server which knows nothing about the session causing failure. Now we can always save the session id in the database which will bring its overhead.

This is where JWT – JSON Web Token comes to rescue that comply with the stateless nature of the HTTP.

JSON is an open standard RFC 7519, that defines a compact and self-contained method for securely transferring information between parties.

The format of JSON Web Token

header.payload.signature

payload is the part of transmitted data that is the actual intended message in computing.

The header will typically contain

  • typ – the type of media, JWT in this case.
  • alg – the algorithm used for signing and/or decryption the JWT

The payload contains information about the client or set of claims. There are seven registered (public) claims and we can define private (custom) claims also.

iss issuer The party that issued the JWT
sub subject The party that this JWT carries information
aud audience Intended recipient
exp expiration Exact moment from which the JWT is considered invalid in ‘seconds since Epoch’ format
nbf from not before Exact moment from which the JWT is considered valid.
Iat Issued at time Time when the JWT was issued
jti JWT ID Unique identifier for this JWT

The third part signature is computed as follows:

Header and Payload are encoded using Base64url encoding and are concatenated with a period separator.

This is then run through the algorithm specified in the header.

HS256(secret, base64URLEncoding(header) + “.” + base64URLEncoding(payload))

The signature is also encoded using Base64urlEncoding

Finally, the token will be

token= base64urlEncoding(header) + ‘.’ + base64urlEncoding(payload) + ‘.’ + base64urlEncoding(signature)

We can encode or decode JWTs at

https://www.jsonwebtoken.io

Here changing the Payload will change the JWT String.

The flow will look something like below

Get the free comprehensive guide on JWT

https://auth0.com/resources/ebooks/jwt-handbook/

Hope it helps..

Nishant Rana's Weblog

Everything related to Microsoft .NET Technology

Skip to content ↓