Category Archives: Blog
Analysis Services Live Connection in Power BI
Introduction: In this article, we will learn how to configure Live connection for Analysis Services in Power BI. Requirements: Power BI Licence SQL Server Analysis Service Power BI Gateway (Refer this link to configure Power BI Gateway) Steps to Connect Analysis Services Live in PowerBI Open PowerBI Desktop Click Get Data and Select Analysis Services In the Analysis Services Connection details, select Live Connection Mode for Live Connection. Once the Data, Measures, KPIs are loaded you can create Power BI Dashboard. Live Connection enabled status is visible at the right bottom of the Power BI Desktop. Before publishing the Dashboard, login into Power BI Service. Under Manage Gateway, we must add a data source for Analysis Services. Note: The account should be a Server Admin on the Analysis Server and should be a domain account in the same domain that the Analysis Services instance is located. (Click here for more information on Analysis Server Connection) Go back to Power BI Desktop and publish the Power BI dashboard. In the Power BI Service, under the Reports you will be able to see the published Live SQL dashboard.
Share Story :
SQL Live Connection in Power BI
Introduction: In this article, we will learn how to configure Live connection for SQL in Power BI. Requirements: Power BI Licence SQL Server Database Engine. Power BI Gateway (Refer this link to configure Power BI Gateway) Steps to Connect SQL Live in PowerBI: Open PowerBI Desktop Click Get Data and Select SQL Server. In the SQL Connection details, select DirectQuery Mode for Live Connection. Once the Data is loaded, you can create Power BI Dashboard. DirectQuery enabled status is visible at the right bottom of the Power BI Desktop. Before publishing the Dashboard, login into Power BI Service. Under Manage Gateway, we must add a data source for SQL Server. Go back to Power BI Desktop and publish the Power BI dashboard. In the Power BI Service, under the Reports you will be able to see the published Live SQL dashboard.
Share Story :
Setup UserName authentication in Dynamics NAV
Do you feel like the vast majority of your information lives in Excel spreadsheets? Joining deals with that, as well, Microsoft dynamics nav upgrade improves your operational productivity so you have all the more convenient information. This permits you to know things quicker like when to move stock from area to another, when to markdown items, and how to showcase in one district versus another. Coordination prompts snappier dynamics. The present clients request a great deal from vendors. Having the option to settle on basic business choices at the ideal time depends on having perceivability into your tasks. Mix is regularly the way in to that kind of perceivability. It gives you a focal area to oversee and see all your information. Introduction: In this blog, we’ll see the ‘UserName’ authentication in Dynamics NAV. It is used when we want to use the existing Windows User and has a password associated with it. This method is preferred when two or more users use the same machine and require a simple password security so that only they can access their account. Prerequisite: Microsoft Dynamics NAV Procedure: Create a User in Windows Client by going to Administration > IT Administration > General or by typing Users in Search. Create a NAV Server Instance from Administration with Credential Type as ‘UserName’. Change the ClientUserSettings ‘C:\Users\<Username>\AppData\Roaming\Microsoft\Microsoft Dynamics NAV\100\ClientUserSettings ‘Give the Server, ClientServicesPort, Server Instance & ClientServicesCredentialType. Open the Windows Client and enter the credentials. Windows Client HomePage: Conclusion: Thus, this method is preferred when two or more users use the same machine and require a simple password security so that only they can access their account.
Share Story :
Session Time out in Dynamics 365
Introduction: By default, Dynamics 365 online sets user time out 24 hours. In that case a user not required to login in up to 24 hours regardless or active or inactive. Applicable for- Applies to Dynamics 365 (online), version 9.0 Microsoft Dynamics CRM 2016 (on-premises, version 8.2) Microsoft Dynamics CRM 2016 (on-premises, version 8.1) User session timeout: Earlier there was no configuration provided to set the session timeout. Dynamics 365 with specified version have provision to set the session timeout. To enforce the users to re-authenticate after pre-defined time, this can be set by admin. Once the specified time is passes the user will logoff automatically from the system. Configure session timeout: To configure the session timeout, you need to follow the below path and set the time Dynamics 365 -> settings -> Administrator -> System Settings -> General tab By default, it is set to 1440 minutes and maximum value as well. If you want to set session time out as per you convince then you need to select the option “Set Custom” and specify the desire value. You can also specify time for warning message before the session timeouts. Inactivity timeout: By any reason a user forgot to logoff from his system then if Dynamics 365 detects the ideal mode then it will logoff the user automatically after certain period. Configure inactivity timeout: To configure the session inactivity timeout, you need to follow below path and set time Dynamics 365 -> settings -> Administrator -> System Settings -> General tab By default, “session timeout” is inactive and not enabled. If you want to configure inactive timeout, you need to enable it from general tab as shown below point no 6. Session timeout section: Minimum duration for inactivity is 5 minutes and maximum duration of inactivity is 1440. Conclusion: It is good practice to have session timeout and inactive timeout, which will provide security to data.
Share Story :
November 2017 Updates for PowerBI Desktop
Introduction: In this blog article, I will talk about the November Updates for PowerBI Desktop. Conditional Formatting based on Rules: You can now set the colour of the text based on a predefined rule depending on your business logic. This enables you to colour-code your data based on a set of rules that you set based on your business logic. To do this, go to the Conditional Formatting card and select the field you want to make changes to from the drop-down menu. Switch the ‘Font Colour Scales’ option On and select ‘Advanced Controls’. The general Font Colour Scales dialog box will open. Select the ‘Colour by rules’ checkbox. The Rules pane is displayed. There are dropdown lists to select the conditions, text fields to set values and a colour selector to set the colour of the data that satisfies the condition. If left empty, they default to the Minimum and Maximum values. To add additional conditions, click the ‘Add’ button. Once done, click OK. You will see the Conditional Formatting Rules being applied and the data being colour-coded accordingly. Also, if a data value satisfies multiple rules, the bottom rule applies. Cell Alignment for Table and Matrix: Now, you can set the alignment of data to Left, Right or Center for cells in a table or matrix. This feature is very useful when formatting your report. To do this, go to the Field Formatting card and select the field you want to make changes to. Go to the ‘Alignment’ option and select the alignment of your choice from the dropdown menu. You will now see that all the data in the selected fields have been aligned according to your selection. Selection Pane Update: The Selection pane now has an added feature of letting the user select which objects are displayed on top of the canvas if there is overlapping. Locking Report Objects: There is now a checkbox called ‘Lock Objects’ that allows you to fix the position and the size of each object in a report so that no changes are accidentally made. This is very useful when browsing reports as the layout will not be affected. One thing to keep in mind is that this setting will not be saved with the report and to ensure this checkbox is ticked when browsing. New options for slow/large data sources: Sometimes, if you have a large or a slow data source, obtaining a response to actions taken in the report can take time. To improve this, options have been introduced to send fewer queries so that it is easier and quicker to interact with the report. To enable this option, go to Options and settings in the File menu. Select Options and then the Query Reduction tab. From here, you can disable cross-highlighting and automatic slicing and filtering within the report. For slicing and filtering, an apply button can be added instead so that the report is only sliced/filtered once you click the ‘Apply’ button. As you can see above, the pie chart is not sliced when ‘Product 1’ is selected. It is only sliced when the ‘Apply’ button is clicked as seen below. Improvement in filtering: The limit of 500 values on the number of values you can match when filtering has been removed. This is applicable for all data sources except Live connections to analysis services models. Conclusion: As you can see from above, the November Update is full of extremely useful features that further optimize the way we use PowerBI Desktop.
Share Story :
Retrieve Multiple Records using Web API in Dynamics 365 version 9.0
Introduction: In this blog article, we will be showing how use fetch XML to retrieve multiple records with the new Web API in Dynamics 365 version 9.0 Implementation: Step 1: The retrieveMultipleRecords() method retrieves a collection of entity records. The basic syntax is as follows: Xrm.WebApi.retrieveMultipleRecords(entityLogicalName,options,maxPageSize).then(successCallback, errorCallback); Here the options parameter refers to the query that will decide the data which has to be retrieved from the system. We will be using the fetchXml attribute to specify a FetchXML query to retrieve contacts of a specific account. The maxPageSize indicates number of records to be returned per page. If this is not specified the default value is 5000. In this example we have not specified the maxPageSize. Step 2: First we write the code and upload it as a JavaScript web resource. Code var scripting = { retrieveMultipleContacts(executioncontext) { debugger; var formContext = executioncontext.getFormContext(); var accountId = formContext.data.entity.getId(); var fetchXml = “<fetch version=’1.0′ output-format=’xml-platform’ mapping=’logical’ distinct=’false’><entity name=’contact’ ><attribute name=’fullname’ /><attribute name=’telephone1′ /><attribute name=’contactid’ /><order attribute=’fullname’ descending=’false’ /><filter type=’and’><condition attribute=’parentcustomerid’ operator=’eq’ uitype=’account’ value ='” + accountId + “‘ /></filter></entity ></fetch > “; Xrm.WebApi.retrieveMultipleRecords(“contact”, “fetchXml= ” + fetchXml).then( function success(result) { for (var i = 0; i < result.entities.length; i++) { console.log(result.entities[i]); } }, function (error) { console.log(error.message); } ); } }; Here we take the execution context as the input parameter and we get the form context using the getFormContext() method. This method returns a reference to the form or an item on the form. Using the formContext we get get the account id which is used to fetch the contacts of that specific account. Step 3: On the account form, in the form properties we set the Event to OnSave as shown below. Step 4: In the handler properties we set the function name, in our case it is scripting.retrieveMultipleContacts. And it is important to check the “Pass execution context as the first parameter” checkbox as shown below. Step 5: We see that the account A. Datum Corporation (sample) has two contacts. Step 6: The script runs when the form is saved and while debugging we can see in the console, two contacts are returned in the results. We get the the attributes that were present in the FetchXML query. Hope this article was helpful!
Share Story :
Analysis Services Connection Configuration in Power BI for Live Connection
Introduction: In this article, we will learn how to successfully connect to Analysis Services in Power BI for Live Connection. Checklist for Connection: The Domain Account must be a Server Admin in Analysis Server. Right Click on the Analysis Server > Select Properties > Select Security > The domain account must be added/present here. Check Properties of Domain Account User for UPN (User Principle Name) Open Server Manager >Select Tools at right Upper Corner >Select Active Directory Users and Computers. Drill down the domain name >Select Users >Double-Click on the domain account. Click the Account tab. Note the User Logon name. User Principal Name (UPN) Mapping in Power BI Under the Analysis Server Data Source setting in Power BI Service, Navigate to Users and select the user and click Map User Name. Select CustomData and enter Replace data as the User you are logged in with and With Data as the Server Admin Domain Account UserLogon Name you had noted before. You can even test the mapping rule. For more information on UPN, watch the video for UPN Mapping in Power BI.
Share Story :
Steps to configure Power BI Gateway
Introduction: In this article, we will learn how to configure Power BI Gateway. Steps to configure Gateway Login to Power BI service. Select Downloads icon> Data Gateway. You will be redirected to Power BI Gateway Download Page and click Download Gateway. Run the PowerBIGatewayInstaller. Click Next and then Install. The Power BI Gateway will be Installed. Sign to Power BI. Give the Gateway a Name and Recovery Key and Click Configure. Now, we are all set.
Share Story :
DLL Deployment Error on Scribe On-Premise Agent Server
Introduction: Recently, we encountered a strange behavior of Scribe On-Premise Agent when we deployed a DLLs for a Custom Connector. After deployment of DLLs on the Agent, the status of the Scribe Agent was stuck at “Updating” and the Connector was not visible under the connector drop down. Troubleshooting: We checked the “MICROAGE1 Agent 2” Agent log and found out an error in .Net Framework. Error Details: Message: Folder (C:\Program Files (x86)\Scribe Software\TIBCO Cloud Integration Agent 3\Connectors\ConnectorName) has the following exceptions during discovery:System.ApplicationException: Exception Type : FileLoadException Message: Could not load file or assembly ‘file:///C:\Program Files (x86)\Scribe Software\TIBCO Cloud Integration Agent 3\Connectors\ConnectorName\********.dll’ or one of its dependencies. Operation is not supported. (Exception from HRESULT: 0x80131515) StackTrace : at System.Reflection.RuntimeAssembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks) at System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(AssemblyName assemblyRef, Evidence assemblySecurity, RuntimeAssembly reqAssembly, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks) at System.Reflection.RuntimeAssembly.InternalLoadFrom(String assemblyFile, Evidence securityEvidence, Byte[] hashValue, AssemblyHashAlgorithm hashAlgorithm, Boolean forIntrospection, Boolean suppressSecurityChecks, StackCrawlMark& stackMark) at System.Reflection.Assembly.LoadFrom(String assemblyFile) at Scribe.Core.Access.AdapterDiscoverer.DiscoverConnectors(String folderName) — Inner Exception — Type: NotSupportedException Message: An attempt was made to load an assembly from a network location which would have caused the assembly to be sandboxed in previous versions of the .NET Framework. This release of the .NET Framework does not enable CAS policy by default, so this load may be dangerous. If this load is not intended to sandbox the assembly, please enable the loadFromRemoteSources switch. See http://go.microsoft.com/fwlink/?LinkId=155569 for more information. Steps to perform Resolution 1 Login to MICROAGE1 Server C:\Windows\Microsoft.NET\Framework64\v4.0.30319\Config Open CONFIG File “machine” Add the code at line 151 and Save the file <runtime> <loadFromRemoteSources enabled=”true”/> </runtime> Current Code screenshot: Restart the Scribe Agent in Services Check if the DLL’s are deployed successfully by creating a connection in TIBCO Cloud Integration for Channel Online. If still failed then perform Resolution 2. Steps to perform Resolution 2 Login to MICROAGE1 Server Stop Scribe Agent in the Services. Go to C:\Program Files (x86)\Scribe Software\TIBCO Cloud Integration Agent 3\Connectors\ConnectorName and Right Click on a DLL file. (For example: As per the screenshot, “Contact”) Click on “Properties” Under Security Section press “Unblock” Click Apply and Ok Again, open the Properties to check whether it is successfully unblocked. Repeat Step 4-8 for all DLLs. Start the Scribe Agent in the Services.
Share Story :
Dynamics CRM Marketing list members sync with MailChimp- Part 2
Introduction: This blog is the continuation of Part 1 and it will show you the code that are required for the action to work and the workflows created in CRM. Steps: 1. Add a button on marketing list using Ribbon Workbench and script which calls the action. 2. Create an action “MailChimpBatchCreateCall” that triggers on Sync button click. When the button is clicked, action is called using JavaScript. This action Retrieves configuration and Marketing list records from CRM and add the members to Mail Chimp Marketing list by Mail Chimp API Call (Batch request). The code to be included in the action is given below: This is a POST request as we are creating list members in MainChimp using (WebClientEx client = new WebClientEx()) { string authorizationKey = string.Empty; authorizationKey = Convert.ToBase64String(ASCIIEncoding.ASCII.GetBytes(string.Format(CultureInfo.InvariantCulture, “{0}:{1}”, username, api))); client.Timeout = 60000; client.Headers.Add(HttpRequestHeader.ContentType, “application/json”); client.Headers.Add(HttpRequestHeader.Authorization, “Basic ” + authorizationKey); tracer.Trace(“jsonData: ” + jsonData); createBatchResponseJSON = client.UploadString(basicURL, jsonData); } tracer.Trace(“createBatchResponse :” + createBatchResponseJSON); Model.MailChimpContactCreateBatchResponse createBatchResponse = GetInfoFromJSON(createBatchResponseJSON); CreateMailChimpSyncRecord(createBatchResponse, tracer, service, marketinglistid); The JSON request to be passed is given below: The JSON response for the BATCH call is given below: 3. Create an action “MailChimp status” which triggers on MailChimp Sync record creation. Mail Chimp API call is made to get the status of the synchronization process. Batch ID is the unique value which helps to retrieve the status of sync call. If status is finished, sync process is completed. The code to be included in the action is given below: This is a GET request to check the status and update the status record in CRM. //// Call the web service using (WebClientEx client = new WebClientEx()) { string authorizationKey = string.Empty; authorizationKey = Convert.ToBase64String(ASCIIEncoding.ASCII.GetBytes(string.Format(CultureInfo.InvariantCulture, “{0}:{1}”, username, api))); basicURL = basicURL + “/” + batchId; HttpWebRequest request = (HttpWebRequest)WebRequest.Create(basicURL); request.Accept = “application/json”; request.Method = “GET”; request.Headers.Add(“Authorization”, “Basic ” + authorizationKey); using (HttpWebResponse response = (HttpWebResponse)request.GetResponse()) using (Stream stream = response.GetResponseStream()) using (StreamReader reader = new StreamReader(stream)) { getBatchResponseJSON = reader.ReadToEnd(); } } tracer.Trace(“createBatchResponse :” + getBatchResponseJSON); Model.MailChimpContactCreateBatchResponse createBatchResponse = GetInfoFromJSON(getBatchResponseJSON); //// Update the MailChimp Sync record with new status UpdateMailChimpSyncRecord(createBatchResponse, tracer, service, currentRecord.Id); The JSON response for the GET request is given below: 4. Create workflows that keep on checking the status of the batch call. The initial batch call is a sync process and we get a status showing no. of record finished and pending. Thus, the syncing process takes place in background. Therefore, we need to create workflows to keep on checking in specific interval. In the initial call, we have kept waiting time of 5 min and then kept waiting time of 1 hour and called the same workflow again till we get the status of batch call as “finished”. a. Main Workflow: b. Child Workflow 1 Check Mail Chimp Sync. c. Child Workflow 2 Check Mail Chimp Sync. For more code details, you can refer the GitHub link. Hope it help you and thus we can integrate the CRM with Mailchimp and make use of MailChimp API calls listed in their documentation. Members can be added individually or by using the batch operations. You can refer the below links from MaiChimp which shows how we can make individual and batch calls. i. Creating a new member ii. Batch Operations