MS CRM Charts in Queue not saving - charts

I am trying to create a chart in MS CRM and I keep getting an error.
Unhandled Exception: System.ServiceModel.FaultException`1[[Microsoft.Xrm.Sdk.OrganizationServiceFault, Microsoft.Xrm.Sdk, Version=7.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]]: SecLib::AccessCheckEx failed. Returned hr = -2147187962, ObjectID: 00000000-0000-0000-0000-000000000000, OwnerId: e2e07c90-2105-e611-80f6-00155d293800, OwnerIdType: 8 and CallingUser: e2e07c90-2105-e611-80f6-00155d293800. ObjectTypeCode: 1112, objectBusinessUnitId: b4bd5fdf-2ccf-e311-80ca-00155d293800, AccessRights: CreateAccess Detail:
<OrganizationServiceFault xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.microsoft.com/xrm/2011/Contracts">
<ErrorCode>-2147187962</ErrorCode>
<ErrorDetails xmlns:d2p1="http://schemas.datacontract.org/2004/07/System.Collections.Generic" />
<Message>SecLib::AccessCheckEx failed. Returned hr = -2147187962, ObjectID: 00000000-0000-0000-0000-000000000000, OwnerId: e2e07c90-2105-e611-80f6-00155d293800, OwnerIdType: 8 and CallingUser: e2e07c90-2105-e611-80f6-00155d293800. ObjectTypeCode: 1112, objectBusinessUnitId: b4bd5fdf-2ccf-e311-80ca-00155d293800, AccessRights: CreateAccess </Message>
<Timestamp>2016-08-08T06:05:22.5032353Z</Timestamp>
<InnerFault i:nil="true" />
<TraceText i:nil="true" />
</OrganizationServiceFault>
I understand this is a permissions error, but I can not find which permission to give.

ObjectTypeCode: 1112 is the user chart entity, and it looks like you are missing the CreateAccess right (e.g. create).

Related

Service is failing with no exception thrown

I am somewhat new at developing in the VS C# environment and have come across the following issue. I have developed a C# service (BrassSS) that interfaces to an MS Access database and has been running since February 2018. The service is meant to perform a nightly backup at 4:00am, send reminder emails at 7 am, and status emails at 10,2, and 6 daily. This has all been running fine for years until about a week ago when a customer calls me that reminder emails were not working. BrassSS keeps a log which I checked and noticed that the service is now dying just a few milliseconds later when I attempt to open the database to send reminder emails at 7:00am. This had never happened so I have been trying to scour the internet with my limited knowledge and struggling with this. Note that I have a 'mirror' image of the service that I run as a console app (BrassConsoleApp), which also fails at the same location. I finally made it to the Event Viewer (two log entries shown below) and it would seem that an unhandled exception is occurring.
I don't know if this helps, and may only add to the confusion, but in the last month I have switched MS Access from 2007 to 2016. Having said that, note that at 4:00am, when the backup kicks in, the exact same code you see below to open the database, runs with no issue.
So at 7:00am, the timer elapses and I need to open the database, here is my code:
class DBif
{
const string cstClassName = "DBif";
private OleDbConnection conDB;
private string strPathToBEFile;
public bool openDB(string strFullPathToDB) {
// Connects to the DB
this.strPathToBEFile = strFullPathToDB;
try {
if (this.conDB != null) {
this.conDB.Close();
}
Logs.addEvent("Info", cstClassName, "openDB", "Attempt to Open DB: " + strPathToBEFile); //debug
string connectionString = "Provider=Microsoft.ACE.OLEDB.16.0;Data Source=" + strPathToBEFile + ";Jet OLEDB:Database Password=" + "----------" + ";";
Logs.addEvent("Info", cstClassName, "openDB", "Connection string: " + strPathToBEFile); //debug
this.conDB = new OleDbConnection(connectionString);
Logs.addEvent("Info", cstClassName, "openDB", "conDB successfull " + strPathToBEFile); //debug
this.conDB.Open(); ***<---- I place a breakpoint here, step over it, and the app FAILS WITH NO EXCEPTION***
Logs.addEvent("Info", cstClassName, "openDB", "DB Opened successfully: " + strPathToBEFile); //debug
return true;
} catch (Exception ex) {
Logs.addEvent("CRITICAL", cstClassName, "openConnection", "Error trying to Open database: " + ex.Message);
return false;
}
}
.....
}
I am hoping that some expert can shed some light into this and help me get to the root cause.
This is the Event Viewer log entry showing an ERROR when the app fails;
Log Name: Application
Source: Application Error
Date: 2021-Jun-10 4:30:01 PM
Event ID: 1000
Task Category: (100)
Level: Error
Keywords: Classic
User: N/A
Computer: Dell5759
Description:
Faulting application name: BrassConsoleApp.exe, version: 1.0.0.0, time stamp: 0x60c2722d
Faulting module name: mso20win32client.dll, version: 0.0.0.0, time stamp: 0x60a155a8
Exception code: 0xc000041d
Fault offset: 0x001d3a12
Faulting process id: 0x49a8
Faulting application start time: 0x01d75e34f0fb2b15
Faulting application path: D:\BitCrafters\Dev\Brass\Next\BrassConsoleApp\bin\Debug\BrassConsoleApp.exe
Faulting module path: C:\Program Files (x86)\Common Files\Microsoft Shared\Office16\mso20win32client.dll
Report Id: b2318536-61c1-4958-85c0-a6803c4bbd3b
Faulting package full name:
Faulting package-relative application ID:
Event Xml:
<Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event">
<System>
<Provider Name="Application Error" />
<EventID Qualifiers="0">1000</EventID>
<Version>0</Version>
<Level>2</Level>
<Task>100</Task>
<Opcode>0</Opcode>
<Keywords>0x80000000000000</Keywords>
<TimeCreated SystemTime="2021-06-10T20:30:01.9117979Z" />
<EventRecordID>200410</EventRecordID>
<Correlation />
<Execution ProcessID="0" ThreadID="0" />
<Channel>Application</Channel>
<Computer>Dell5759</Computer>
<Security />
</System>
<EventData>
<Data>BrassConsoleApp.exe</Data>
<Data>1.0.0.0</Data>
<Data>60c2722d</Data>
<Data>mso20win32client.dll</Data>
<Data>0.0.0.0</Data>
<Data>60a155a8</Data>
<Data>c000041d</Data>
<Data>001d3a12</Data>
<Data>49a8</Data>
<Data>01d75e34f0fb2b15</Data>
<Data>D:\BitCrafters\Dev\Brass\Next\BrassConsoleApp\bin\Debug\BrassConsoleApp.exe</Data>
<Data>C:\Program Files (x86)\Common Files\Microsoft Shared\Office16\mso20win32client.dll</Data>
<Data>b2318536-61c1-4958-85c0-a6803c4bbd3b</Data>
<Data>
</Data>
<Data>
</Data>
</EventData>
</Event>
SECOND EVENT VIEWER INFO LOG ENTRY JUST AFTER THE ONE ABOVE ---------------------------------------------------
Log Name: Application
Source: Windows Error Reporting
Date: 2021-Jun-10 4:30:04 PM
Event ID: 1001
Task Category: None
Level: Information
Keywords: Classic
User: N/A
Computer: Dell5759
Description:
Fault bucket 1496835596276001519, type 1
Event Name: APPCRASH
Response: Not available
Cab Id: 0
Problem signature:
P1: BrassConsoleApp.exe
P2: 1.0.0.0
P3: 60c2722d
P4: mso20win32client.dll
P5: 0.0.0.0
P6: 60a155a8
P7: c000041d
P8: 001d3a12
P9:
P10:
Attached files:
\\?\C:\TMP\{348A1C8B-8F9A-4947-A735-1A6662FAB73B} - OProcSessId.dat
\\?\C:\ProgramData\Microsoft\Windows\WER\Temp\WERBA96.tmp.dmp
\\?\C:\ProgramData\Microsoft\Windows\WER\Temp\WERBD95.tmp.WERInternalMetadata.xml
\\?\C:\ProgramData\Microsoft\Windows\WER\Temp\WERBDC5.tmp.xml
\\?\C:\ProgramData\Microsoft\Windows\WER\Temp\WERBDD3.tmp.csv
\\?\C:\ProgramData\Microsoft\Windows\WER\Temp\WERBE22.tmp.txt
These files may be available here:
\\?\C:\ProgramData\Microsoft\Windows\WER\ReportArchive\AppCrash_BrassConsoleApp._a65121a9886cf85d89cc2caea488de84ebbc6379_15a45da1_128d96b7-c591-43c7-8393-71b1b078c790
Analysis symbol:
Rechecking for solution: 0
Report Id: b2318536-61c1-4958-85c0-a6803c4bbd3b
Report Status: 268435456
Hashed bucket: e03e080836cae1e184c5d40b5330eaef
Cab Guid: 0
Event Xml:
<Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event">
<System>
<Provider Name="Windows Error Reporting" />
<EventID Qualifiers="0">1001</EventID>
<Version>0</Version>
<Level>4</Level>
<Task>0</Task>
<Opcode>0</Opcode>
<Keywords>0x80000000000000</Keywords>
<TimeCreated SystemTime="2021-06-10T20:30:04.9119743Z" />
<EventRecordID>200411</EventRecordID>
<Correlation />
<Execution ProcessID="0" ThreadID="0" />
<Channel>Application</Channel>
<Computer>Dell5759</Computer>
<Security />
</System>
<EventData>
<Data>1496835596276001519</Data>
<Data>1</Data>
<Data>APPCRASH</Data>
<Data>Not available</Data>
<Data>0</Data>
<Data>BrassConsoleApp.exe</Data>
<Data>1.0.0.0</Data>
<Data>60c2722d</Data>
<Data>mso20win32client.dll</Data>
<Data>0.0.0.0</Data>
<Data>60a155a8</Data>
<Data>c000041d</Data>
<Data>001d3a12</Data>
<Data>
</Data>
<Data>
</Data>
<Data>
\\?\C:\TMP\{348A1C8B-8F9A-4947-A735-1A6662FAB73B} - OProcSessId.dat
\\?\C:\ProgramData\Microsoft\Windows\WER\Temp\WERBA96.tmp.dmp
\\?\C:\ProgramData\Microsoft\Windows\WER\Temp\WERBD95.tmp.WERInternalMetadata.xml
\\?\C:\ProgramData\Microsoft\Windows\WER\Temp\WERBDC5.tmp.xml
\\?\C:\ProgramData\Microsoft\Windows\WER\Temp\WERBDD3.tmp.csv
\\?\C:\ProgramData\Microsoft\Windows\WER\Temp\WERBE22.tmp.txt</Data>
<Data>\\?\C:\ProgramData\Microsoft\Windows\WER\ReportArchive\AppCrash_BrassConsoleApp._a65121a9886cf85d89cc2caea488de84ebbc6379_15a45da1_128d96b7-c591-43c7-8393-71b1b078c790</Data>
<Data>
</Data>
<Data>0</Data>
<Data>b2318536-61c1-4958-85c0-a6803c4bbd3b</Data>
<Data>268435456</Data>
<Data>e03e080836cae1e184c5d40b5330eaef</Data>
<Data>0</Data>
</EventData>
</Event>
Any help would be appreciated!
Thanks
After trying multiple approaches and dealing with this for over a week, I have decided to restructure my Service by replacing 3 timers with one. The single timer checks the time of day and calls the appropriate process.
I put this question up with the hope that someone would have the knowledge to decipher the Event Log entries. Since I did not get any response, I needed to move on with a solution.
Thank you for those of you that have taken a look and please disregard my original question as I have moved on.

DMN 1.2: Referencing ItemDefinitions from another ItemDefinition results in an error

I load this DMN file (dmnFile):
<definitions name="MyDecision" id="def_12f8a48f-3978-0e29-4251-a66b6e6459bc"
xmlns:ns="http://sample.dmn" namespace="http://sample.dmn"
xmlns:feel="http://www.omg.org/spec/FEEL/20140401" exporter="ex" exporterVersion="12"
xmlns="http://www.omg.org/spec/DMN/20180521/MODEL/">
<itemDefinition name="MyItemDefinition" id="_850f24d9-57a3-131f-2194-ca15bb049a7a">
<itemComponent name="myNumber" id="_29d92e98-3c97-67a3-22f1-d342622424f7">
<typeRef>NumberDefinition</typeRef>
</itemComponent>
</itemDefinition>
<itemDefinition name="NumberDefinition" id="_e6972775-7973-b755-8714-9eff9d61e48e">
<typeRef>number</typeRef>
</itemDefinition>
<inputData name="MyInput" id="_d6395e05-d35c-d667-f227-398d93a97759">
<variable name="MyInput" id="_121ab3bc-b4e2-a6bb-51be-ef8fcc6623a6" typeRef="MyItemDefinition" />
</inputData>
<decision name="MyDecision" id="_12f8a48f-3978-0e29-4251-a66b6e6459bc">
<variable name="MyDecision" id="_098e9619-fa0c-3796-b3da-c4d018a79009" typeRef="boolean" />
<informationRequirement>
<requiredInput href="#_d6395e05-d35c-d667-f227-398d93a97759" />
</informationRequirement>
<context id="_6dcdac84-b03f-badd-a2d7-78c668ece883">
<contextEntry>
<variable name="containsMyNumber" id="_f6078cbe-54e6-d682-b3b7-8ffc638e4846" typeRef="boolean" />
<literalExpression id="_a022013e-4f0c-cfb3-1792-673a9e69be33">
<text>if list contains([0,1,2,3], MyInput.myNumber) then true else false</text>
</literalExpression>
</contextEntry>
<contextEntry>
<literalExpression id="_19c3853c-c63b-a8ac-0608-639ea685f321">
<text>containsMyNumber</text>
</literalExpression>
</contextEntry>
</context>
</decision>
</definitions>
like this:
KieServices ks = KieServices.Factory.get();
KieContainer kieContainer = KieHelper.getKieContainer(ks.newReleaseId("org.kie", "dmn-test-" + UUID.randomUUID(), "1.2"), ks.getResources().newFileSystemResource(dmnFile));
and I get an exception with the following error message:
[Message [id=1, kieBase=defaultKieBase, level=ERROR, path=C:/Users/AppData/Local/Temp/tmpBA10.tmp.dmn, line=4, column=-1
text=DMN: Unable to resolve type reference '{http://www.omg.org/spec/DMN/20180521/MODEL/}NumberDefinition' on node 'MyItemDefinition' (resource: C:/Users/AppData/Local/Temp/tmpBA10.tmp.dmn, DMN id: _29d92e98-3c97-67a3-22f1-d342622424f7, The listed type definition was not found) ]]
Type reference with prefix ("ns:NumberDefinition") results in the following error message:
[Message [id=1, kieBase=defaultKieBase, level=ERROR, path=C:/Users/AppData/Local/Temp/tmpBA10.tmp.dmn, line=4, column=-1
text=DMN: Unable to resolve type reference '{http://www.omg.org/spec/DMN/20180521/MODEL/}ns:NumberDefinition' on node 'MyItemDefinition' (resource: C:/Users/AppData/Local/Temp/tmpBA10.tmp.dmn, DMN id: _29d92e98-3c97-67a3-22f1-d342622424f7, The listed type definition was not found) ]]
What do I do wrong?
When using DMN 1.1 (xmlns="http://www.omg.org/spec/DMN/20151101/dmn.xsd") and type references as QNames (with prefixes) I get the expected result.
Since DMNv1.2, the idiomatic way to reference is ns.<itemDef>.
In your original DMN xml file this happens on line 7 and 14.
In summary the file in the idiomatic DMNv1.2 form should be:
<definitions name="MyDecision" id="def_12f8a48f-3978-0e29-4251-a66b6e6459bc"
xmlns:ns="http://sample.dmn" namespace="http://sample.dmn"
xmlns:feel="http://www.omg.org/spec/FEEL/20140401" exporter="ex" exporterVersion="12"
xmlns="http://www.omg.org/spec/DMN/20180521/MODEL/">
<itemDefinition name="MyItemDefinition" id="_850f24d9-57a3-131f-2194-ca15bb049a7a">
<itemComponent name="myNumber" id="_29d92e98-3c97-67a3-22f1-d342622424f7">
<typeRef>ns.NumberDefinition</typeRef>
</itemComponent>
</itemDefinition>
<itemDefinition name="NumberDefinition" id="_e6972775-7973-b755-8714-9eff9d61e48e">
<typeRef>number</typeRef>
</itemDefinition>
<inputData name="MyInput" id="_d6395e05-d35c-d667-f227-398d93a97759">
<variable name="MyInput" id="_121ab3bc-b4e2-a6bb-51be-ef8fcc6623a6" typeRef="ns.MyItemDefinition" />
</inputData>
<decision name="MyDecision" id="_12f8a48f-3978-0e29-4251-a66b6e6459bc">
<variable name="MyDecision" id="_098e9619-fa0c-3796-b3da-c4d018a79009" typeRef="boolean" />
<informationRequirement>
<requiredInput href="#_d6395e05-d35c-d667-f227-398d93a97759" />
</informationRequirement>
<context id="_6dcdac84-b03f-badd-a2d7-78c668ece883">
<contextEntry>
<variable name="containsMyNumber" id="_f6078cbe-54e6-d682-b3b7-8ffc638e4846" typeRef="boolean" />
<literalExpression id="_a022013e-4f0c-cfb3-1792-673a9e69be33">
<text>if list contains([0,1,2,3], MyInput.myNumber) then true else false</text>
</literalExpression>
</contextEntry>
<contextEntry>
<literalExpression id="_19c3853c-c63b-a8ac-0608-639ea685f321">
<text>containsMyNumber</text>
</literalExpression>
</contextEntry>
</context>
</decision>
</definitions>
That said, with your report we uncovered a bug when the DMN xml file is using the DMN namespace as the default namespace, which we are addressing with
DROOLS-4797.
Thank you for the report !
There is a way to avoid being forced to use ns.<itemDef> and simply use <itemDef>, and that is by setting the default namespace in the DMN xml to be the model's namespace, and just prefixing the DMN xml element with the namespace prefix targeting the DMN namespace.
In other words, the file can make use of <itemDef> reference without having to ns. prefix them:
<semantic:definitions name="MyDecision" id="def_12f8a48f-3978-0e29-4251-a66b6e6459bc"
xmlns="http://sample.dmn" namespace="http://sample.dmn"
xmlns:feel="http://www.omg.org/spec/FEEL/20140401" exporter="ex" exporterVersion="12"
xmlns:semantic="http://www.omg.org/spec/DMN/20180521/MODEL/">
<semantic:itemDefinition name="MyItemDefinition" id="_850f24d9-57a3-131f-2194-ca15bb049a7a">
<semantic:itemComponent name="myNumber" id="_29d92e98-3c97-67a3-22f1-d342622424f7">
<semantic:typeRef>NumberDefinition</semantic:typeRef>
</semantic:itemComponent>
</semantic:itemDefinition>
<semantic:itemDefinition name="NumberDefinition" id="_e6972775-7973-b755-8714-9eff9d61e48e">
<semantic:typeRef>number</semantic:typeRef>
</semantic:itemDefinition>
<semantic:inputData name="MyInput" id="_d6395e05-d35c-d667-f227-398d93a97759">
<semantic:variable name="MyInput" id="_121ab3bc-b4e2-a6bb-51be-ef8fcc6623a6" typeRef="MyItemDefinition" />
</semantic:inputData>
<semantic:decision name="MyDecision" id="_12f8a48f-3978-0e29-4251-a66b6e6459bc">
<semantic:variable name="MyDecision" id="_098e9619-fa0c-3796-b3da-c4d018a79009" typeRef="boolean" />
<semantic:informationRequirement>
<semantic:requiredInput href="#_d6395e05-d35c-d667-f227-398d93a97759" />
</semantic:informationRequirement>
<semantic:context id="_6dcdac84-b03f-badd-a2d7-78c668ece883">
<semantic:contextEntry>
<semantic:variable name="containsMyNumber" id="_f6078cbe-54e6-d682-b3b7-8ffc638e4846" typeRef="boolean" />
<semantic:literalExpression id="_a022013e-4f0c-cfb3-1792-673a9e69be33">
<semantic:text>if list contains([0,1,2,3], MyInput.myNumber) then true else false</semantic:text>
</semantic:literalExpression>
</semantic:contextEntry>
<semantic:contextEntry>
<semantic:literalExpression id="_19c3853c-c63b-a8ac-0608-639ea685f321">
<semantic:text>containsMyNumber</semantic:text>
</semantic:literalExpression>
</semantic:contextEntry>
</semantic:context>
</semantic:decision>
</semantic:definitions>
In this other variant, the default namespace in the xml is the DMN model's namespace, so any itemDef reference does not need any prefix.
Because the default namespace in the xml is the DMN model's namespace, the xml element need to be prefixed with the namespace prefix targeting now the DMN namespace.
Hope this clarifies and provide an insightful explanation!

How to Fix "There has been an error processing your request :: Specified invalid parent id (Magento_Backend::mgs)" in Admin Panel..?

I'm using Magento2,when i login on my website i got this message.
There has been an error processing your request Specified invalid
parent id (Magento_Backend::mgs) Error log record number:
1307308720759
This website was working fine but last day i run a query and recompile and then this issue start coming up....
Below Error Log Detail
{"0":"Specified invalid parent id (Magento_Backend::mgs)","1":"#0
/home/gervetus/public_html/vendor/magento/framework/Interception/Interceptor.php(58):
Magento\Backend\Model\Menu\Builder->getResult(Object(Magento\Backend\Model\Menu))\n#1
/home/gervetus/public_html/vendor/magento/framework/Interception/Interceptor.php(138): Magento\Backend\Model\Menu\Builder\Interceptor->___callParent('getResult',
Array)\n#2
/home/gervetus/public_html/vendor/magento/framework/Interception/Interceptor.php(153): Magento\Backend\Model\Menu\Builder\Interceptor->Magento\Framework\Interception\{closure}(Object(Magento\Backend\Model\Menu))\n#3
/home/gervetus/public_html/generated/code/Magento/Backend/Model/Menu/Builder/Interceptor.php(26):
Magento\Backend\Model\Menu\Builder\Interceptor->___callPlugins('getResult',
Array, Array)\n#4
/home/gervetus/public_html/vendor/magento/module-backend/Model/Menu/Config.php(148):
Magento\Backend\Model\Menu\Builder\Interceptor->getResult(Object(Magento\Backend\Model\Menu))\n#5
/home/gervetus/public_html/vendor/magento/module-backend/Model/Menu/Config.php(111):
Magento\Backend\Model\Menu\Config->_initMenu()\n#6
/home/gervetus/public_html/vendor/magento/module-backend/Model/Url.php(361):
Magento\Backend\Model\Menu\Config->getMenu()\n#7
/home/gervetus/public_html/vendor/magento/module-backend/Model/Url.php(321):
Magento\Backend\Model\Url->_getMenu()\n#8
/home/gervetus/public_html/generated/code/Magento/Backend/Model/Url/Interceptor.php(102):
Magento\Backend\Model\Url->getStartupPageUrl()\n#9
/home/gervetus/public_html/vendor/magento/module-backend/App/AbstractAction.php(276):
Magento\Backend\Model\Url\Interceptor->getStartupPageUrl()\n#10
/home/gervetus/public_html/vendor/magento/module-backend/App/AbstractAction.php(208):
Magento\Backend\App\AbstractAction->_processUrlKeys()\n#11
/home/gervetus/public_html/vendor/magento/framework/Interception/Interceptor.php(58):
Magento\Backend\App\AbstractAction->dispatch(Object(Magento\Framework\App\Request\Http))\n#12
/home/gervetus/public_html/vendor/magento/framework/Interception/Interceptor.php(138): Magento\Backend\Controller\Adminhtml\Index\Index\Interceptor->___callParent('dispatch',
Array)\n#13
/home/gervetus/public_html/vendor/magento/module-backend/App/Action/Plugin/Authentication.php(143):
Magento\Backend\Controller\Adminhtml\Index\Index\Interceptor->Magento\Framework\Interception\{closure}(Object(Magento\Framework\App\Request\Http))\n#14
/home/gervetus/public_html/vendor/magento/framework/Interception/Interceptor.php(135): Magento\Backend\App\Action\Plugin\Authentication->aroundDispatch(Object(Magento\Backend\Controller\Adminhtml\Index\Index\Interceptor),
Object(Closure), Object(Magento\Framework\App\Request\Http))\n#15
/home/gervetus/public_html/vendor/magento/framework/Interception/Interceptor.php(153): Magento\Backend\Controller\Adminhtml\Index\Index\Interceptor->Magento\Framework\Interception\{closure}(Object(Magento\Framework\App\Request\Http))\n#16
/home/gervetus/public_html/generated/code/Magento/Backend/Controller/Adminhtml/Index/Index/Interceptor.php(26):
Magento\Backend\Controller\Adminhtml\Index\Index\Interceptor->___callPlugins('dispatch',
Array, NULL)\n#17
/home/gervetus/public_html/vendor/magento/framework/App/FrontController.php(55):
Magento\Backend\Controller\Adminhtml\Index\Index\Interceptor->dispatch(Object(Magento\Framework\App\Request\Http))\n#18
/home/gervetus/public_html/vendor/magento/framework/Interception/Interceptor.php(58):
Magento\Framework\App\FrontController->dispatch(Object(Magento\Framework\App\Request\Http))\n#19
/home/gervetus/public_html/vendor/magento/framework/Interception/Interceptor.php(138): Magento\Framework\App\FrontController\Interceptor->___callParent('dispatch',
Array)\n#20
/home/gervetus/public_html/vendor/magento/framework/Interception/Interceptor.php(153): Magento\Framework\App\FrontController\Interceptor->Magento\Framework\Interception\{closure}(Object(Magento\Framework\App\Request\Http))\n#21
/home/gervetus/public_html/generated/code/Magento/Framework/App/FrontController/Interceptor.php(26):
Magento\Framework\App\FrontController\Interceptor->___callPlugins('dispatch',
Array, Array)\n#22
/home/gervetus/public_html/vendor/magento/framework/App/Http.php(135):
Magento\Framework\App\FrontController\Interceptor->dispatch(Object(Magento\Framework\App\Request\Http))\n#23
/home/gervetus/public_html/vendor/magento/framework/App/Bootstrap.php(256):
Magento\Framework\App\Http->launch()\n#24
/home/gervetus/public_html/index.php(40):
Magento\Framework\App\Bootstrap->run(Object(Magento\Framework\App\Http))\n#25
{main}","url":"/admin/admin/index/index/key/6570ae1e6f609b1c1c0433e9e2307b5d7250e1e160091871b57a4326817cae2e/","script_name":"/index.php"}
Just modify the menu file located under /vendor/magento/module-cms/etc/adminthml/menu.xml
<add id="Magento_Backend::mgs" title="Blocks" translate="title" module="Magento_Cms" sortOrder="30" parent="Magento_Backend::mgs" action="cms/block" resource="Magento_Cms::block"/>
Here's how it'll look
<?xml version="1.0"?>
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Backend:etc/menu.xsd">
<menu>
<add id="Magento_Cms::cms_page" title="Pages" translate="title" module="Magento_Cms" sortOrder="0" parent="Magento_Backend::content_elements" action="cms/page" resource="Magento_Cms::page"/>
<add id="Magento_Cms::cms_block" title="Blocks" translate="title" module="Magento_Cms" sortOrder="30" parent="Magento_Backend::content_elements" action="cms/block" resource="Magento_Cms::block"/>
<add id="Magento_Backend::mgs" title="Blocks" translate="title" module="Magento_Cms" sortOrder="30" parent="Magento_Backend::mgs" action="cms/block" resource="Magento_Cms::block"/>
</menu>
</config>
As per error there is no any parent id name with mgs so it will throw error.
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Backend:etc/menu.xsd">
<menu>
<add id="Magento_Cms::cms_page" title="Pages" module="Magento_Cms" sortOrder="0" parent="Magento_Backend::content_elements" action="cms/page" resource="Magento_Cms::page"/>
<add id="Magento_Cms::cms_block" title="Blocks" module="Magento_Cms" sortOrder="30" parent="Magento_Backend::content_elements" action="cms/block" resource="Magento_Cms::block"/>
</menu>
In the code above parent="Magento_Backend::content_elements" will display in content menu so give valid id to your menu then it will work.
For reference see this link

Query Xml data in Sql Server holding serialized objects

We are storing some serialized objects in an Xml-column in Sql Server.
I would like to create a query that gives me the list of serialized objects (rows) where a specific field has a specific value.
My Xml looks like this:
<MessageContainer xmlns="http://schemas.datacontract.org/2004/07/D3A.Messages" xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns:z="http://schemas.microsoft.com/2003/10/Serialization/" z:Id="1" z:Type="D3A.Messages.MessageContainer" z:Assembly="D3A.Messages, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null">
<Messages xmlns:a="http://schemas.microsoft.com/2003/10/Serialization/Arrays" z:Id="2" z:Type="System.Collections.Generic.List`1[[D3A.Messages.IMessage, D3A.Messages, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]]" z:Assembly="0">
<a:_items z:Id="3" z:Size="512">
<a:anyType z:Id="4" z:Type="D3A.Messages.MessageAlarmLog" z:Assembly="D3A.Messages, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null">
<_x003C_Id_x003E_k__BackingField>00000000-0000-0000-0000-000000000000</_x003C_Id_x003E_k__BackingField>
<_x003C_StorageOperation_x003E_k__BackingField>Create</_x003C_StorageOperation_x003E_k__BackingField>
<_x003C_Comment_x003E_k__BackingField z:Id="5" />
<_x003C_ErrorCodeTranslation_x003E_k__BackingField>Ok</_x003C_ErrorCodeTranslation_x003E_k__BackingField>
<_x003C_ErrorCode_x003E_k__BackingField>0</_x003C_ErrorCode_x003E_k__BackingField>
<_x003C_GroupType_x003E_k__BackingField>System</_x003C_GroupType_x003E_k__BackingField>
<_x003C_LogType_x003E_k__BackingField z:Id="6">1</_x003C_LogType_x003E_k__BackingField>
<_x003C_Parameter_x003E_k__BackingField z:Id="7">Timed out.</_x003C_Parameter_x003E_k__BackingField>
<_x003C_TimeStampOff_x003E_k__BackingField i:nil="true" />
<_x003C_TimeStamp_x003E_k__BackingField>2014-05-10T03:10:04Z</_x003C_TimeStamp_x003E_k__BackingField>
<_x003C_Unit_x003E_k__BackingField z:Id="8">100001</_x003C_Unit_x003E_k__BackingField>
<_x003C_UserName_x003E_k__BackingField z:Id="9">e2_fælles</_x003C_UserName_x003E_k__BackingField>
<_x003C_Value_x003E_k__BackingField z:Id="10">50101</_x003C_Value_x003E_k__BackingField>
<_x003C_WindFarm_x003E_k__BackingField z:Id="11">HR2</_x003C_WindFarm_x003E_k__BackingField>
</a:anyType>
<a:anyType z:Id="12" z:Type="D3A.Messages.MessageAlarmLog" z:Assembly="D3A.Messages, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null">
<_x003C_Id_x003E_k__BackingField>00000000-0000-0000-0000-000000000000</_x003C_Id_x003E_k__BackingField>
<_x003C_StorageOperation_x003E_k__BackingField>Create</_x003C_StorageOperation_x003E_k__BackingField>
<_x003C_Comment_x003E_k__BackingField z:Ref="5" i:nil="true" />
<_x003C_ErrorCodeTranslation_x003E_k__BackingField>Ok</_x003C_ErrorCodeTranslation_x003E_k__BackingField>
<_x003C_ErrorCode_x003E_k__BackingField>0</_x003C_ErrorCode_x003E_k__BackingField>
<_x003C_GroupType_x003E_k__BackingField>System</_x003C_GroupType_x003E_k__BackingField>
<_x003C_LogType_x003E_k__BackingField z:Id="13">1</_x003C_LogType_x003E_k__BackingField>
<_x003C_Parameter_x003E_k__BackingField z:Ref="5" i:nil="true" />
<_x003C_TimeStampOff_x003E_k__BackingField i:nil="true" />
<_x003C_TimeStamp_x003E_k__BackingField>2014-05-10T03:10:09Z</_x003C_TimeStamp_x003E_k__BackingField>
<_x003C_Unit_x003E_k__BackingField z:Id="14">100001</_x003C_Unit_x003E_k__BackingField>
<_x003C_UserName_x003E_k__BackingField z:Id="15">e2_fælles</_x003C_UserName_x003E_k__BackingField>
<_x003C_Value_x003E_k__BackingField z:Id="16">50100</_x003C_Value_x003E_k__BackingField>
<_x003C_WindFarm_x003E_k__BackingField z:Ref="11" i:nil="true" />
</a:anyType>
</a:_items>
</Messages>
</MessageContainer>
I am particularly interested in those Xml-chunks that have a specific value in the Xml-field called _x003C_Unit_x003E_k__BackingField. There may be many <a:anytype>-fragments, and I am interested in a result with the complete <MessagesContainer>-fragments with at least one <a:anyType> matching my criteria.
Can you help here? I cannot seem to get the namespace declarations in place in the query.
Thank you :-)
In the query below, replace "100001" with the required value. You can use sql:variable() to make this value dynamic if required.
select #x.query('
declare namespace d3a="http://schemas.datacontract.org/2004/07/D3A.Messages";
declare namespace a="http://schemas.microsoft.com/2003/10/Serialization/Arrays";
/d3a:MessageContainer[
d3a:Messages[
a:_items[
a:anyType[d3a:_x003C_Unit_x003E_k__BackingField/text() = "100001"]
]
]
]'
);
See this article for more details on how to handle namespaces in XQuery.

How can i resolve this MULE_ERROR-109

I am performing a transformation and getting the following error:
ERROR 2013-10-02 12:38:19,763 [[vistaesb].VistaESBFlow1.stage1.04] org.mule.exception.DefaultMessagingExceptionStrategy:
Message : Failed to transform from "json" to "personal_information"
Code : MULE_ERROR-109
Exception stack is:
1. Unrecognized field "phone_number" (Class personal_information), not marked as ignorable
at [Source: java.io.InputStreamReader#ac7e4af; line: 2, column: 21] (through reference chain: personal_information["phone_number"]) (org.codehaus.jackson.map.exc.UnrecognizedPropertyException)
org.codehaus.jackson.map.exc.UnrecognizedPropertyException:53 (null)
2. Failed to transform from "json" to "personal_information" (org.mule.api.transformer.TransformerException)
org.mule.module.json.transformers.JsonToObject:136 (http://www.mulesoft.org/docs/site/current3/apidocs/org/mule/api/transformer/TransformerException.html)
MY configuration is simple enough:
<flow name="VistaESBFlow1" doc:name="VistaESBFlow1">
<jdbc-ee:inbound-endpoint queryKey="personal_information" responseTimeout="1000" encoding="UTF-8" mimeType="text/plain" queryTimeout="-1" pollingFrequency="10000" connector-ref="applyVista_dev" doc:name="Data Entry Point">
</jdbc-ee:inbound-endpoint>
<json:object-to-json-transformer doc:name="Object to JSON"/>
<data-mapper:transform config-ref="new_mapping_grf" doc:name="DataMapper"/>
<json:json-to-object-transformer doc:name="JSON to Object" encoding="utf8" returnClass="personal_information" mimeType="text/plain"/>
<file:outbound-endpoint path="C:\Users\abrowning\Desktop\test" responseTimeout="10000" doc:name="File" encoding="utf8" mimeType="text/plain"/>
</flow>
There is a link to a similar problem here, 109 Error, but i don't think this has to do with my endpoint.
I'm guessing a 109 is a bush-league error, so nay help is appreciated.
The source of my issue was that I had a data mismatch in my get/set methods and after having written a lot of PHP over the last year, I over looked that.