Biztalk 2006r2 Commerce Server Adapter - biztalk

I am trying to query Commerce Server 2007 using the Biztalk Adapter.
I am using the OrdersAdapter and trying to query for all orders with a specific line item on them.
The message xml is
<CommerceServerOrdersQuery>
<CLAUSE OPER="equal" xmlns="http://schemas.microsoft.com/CommerceServer/2004/02/Expressions">
<PROPERTY ID="LineItem.ProductId" MULTIVAL="false" TYPE="String" />
<IMMED-VAL TYPE="String">
<VALUE>xxx</VALUE>
</IMMED-VAL>
</CLAUSE>
</CommerceServerOrdersQuery>
If I query by PurchaseOrder.OrderStatus or some property on the purchase order, it works fine. however if i try to use the line item property as the criteria it fails with this error.
The 'ProductId' property is not a
searchable property of entity
'PurchaseOrder'. Searchable
properties can be discovered by
inspecting the DataSet returned by the
GetSearchableProperties method.
I did query the GetSearchableProperties service specified and it did indeed say that LineItem.ProductId is a searchable property. Furthermore if I do this query with the .NET API, i can see it producing the exact xml i am using and it works. The problem comes when using the BTS Adapter.
The documentation for this is pretty thin with no in depth examples, any help would be greatly appreciated.
Thank You.

Related

Microsoft Graph API- list all users with OneDrive license

I want to list all users that have OneDrive license.
I an using this URL but doesn't work.
https://graph.microsoft.com/v1.0/users?$filter=assignedLicenses/any(x:x/skuId eq 4b585984-651b-448a-9e53-3b10f069cf7f or x/skuId eq c7df2760-2c81-4ef7-b578-5b5392b571df)
Do you have any idea how to do it?
Unfortunately complex query (Whatever you're trying to do above) on property assignedLicenses is not supported. If you do so, the API will throw the error:
Complex query on property assignedLicenses is not supported
Being said that i can see it
works for simple filter, like,
https://graph.microsoft.com/v1.0/users?$filter=assignedLicenses/any(x:x/skuId eq 4b585984-651b-448a-9e53-3b10f069cf7f)

Drupal 7 views of type Services fetches incomplete data

I have created a Service View using views module, where I have a field body of which the formatted as services raw. It is only showing me the first character in the body string (eg: if body string is "All men must die", It shows "A") shown as folling:
I wanted to get the complete text from the field body.
This is also happening if I have an entity reference field where formatter is set to Entity id, It gives me only the first digit of Entity uid (eg: if uid is 16, It shows 1)
Please help
I'm guessing you are using PHP 7.1
There's a known issue with the Services Views module; and seems like a fix has been committed to 7.x-1.x-dev branch on December 1, 2017.
I'd recommend reading through the issue #2910966
https://www.drupal.org/project/services_views/issues/2910966
Then, you will have to upgrade to the development branch to fix the issue you are having.
Make sure to backup your files and database before upgrading the module code.

Is there a way or a plugin to configure SQL Dialects as DQL in PhpStorm?

In PhpStorm, I can change global, project or directories settings with existing SQL Dialects, but is there a way to configure SQL Dialects as Symfony/DQL in PhpStorm or a way to detect that App:Panel is a valid entity, not a table? (App:Panel table name is te_panel)
I read this answer which explains that we have to add a Java plugin, because it's currently not possible to add a new SQL Dialect on PhpStorm.
As example, this is an error that PhpStorm is throwing:
The : between App and Panel is not understood. It cannot understand the table name provided (because I provide the name of the Symfony entity).
DQL is not supported.
https://youtrack.jetbrains.com/issue/WI-9948 -- watch this ticket (star/vote/comment) to get notified on any progress.
You may try and treat App:Panel as placeholder (similar to how it was described in that linked question). But I have no ideas if it will help (have not really worked with Symfony/DQL so cannot test it myself).
What I may suggest though -- threat the whole query as plain text. Yes, no syntax highlighting and stuff but will not show errors either.
How? One way by placing special comment just before the string, e.g.
->query(/** #lang text */'SELECT ...');
Or by disabling Language Injection rule for SQL altogether.
Alternatively try what has been suggested in this comment -- custom SQL detection syntax(?): https://gist.github.com/willemnviljoen/d20ad8ad0cc365a7e80744328246610f

How to enable Content Delivery Loggin

How to enable content delivery logging in Tridion 2011 sp1. We have .net version of content delivery. After installation of content delivery we changed logback file present in our application folder (D:\Inetpub\MyPortal\bin\config), below is the setting in logback xml
<property name="log.history" value="7"/>
<property name="log.folder" value="D:\tridion\log"/>
<property name="log.level" value="DEBUG"/>
After doing the change we reset the IIS. But we don't see any log file at above location.
Reason why we want to check log file is.
We have implemented content filter mechanism. In which we are using various Query Criteria like ItemSchemaCriteria, CustomMetaKeyCriteria, KeywordCriteria.
Somehow for some filters results are not displayed, though we have component present in broker database. How to check exactly what query is getting fired when filter mechanism is executed on page.
Note : At location d:\Tridion\log\ We can see files like cd_core.2012-10-25,cd_monitor.2012-10-25, cd_deployer.2012-10-25,cd_transport.2012-10-25 but these files are old we need today's log. (04-11-2012)
More inputs on issue :
We found that when we add cirteria for Category that time results are not coming.
KeywordCriteria FilterCategory5303Criteria0= new KeywordCriteria("FilterCategory","Administrative");
Criteria[] filterCatCriteria5303 = {FilterCategory5303Criteria0};
Criteria filterCatOrCriteria5303 = CriteriaFactory.Or(filterCatCriteria5303);
mainCriteria5303 =CriteriaFactory.And(mainCriteria5303, filterCatOrCriteria5303);
In CUSTOM_META table in broker db we have entry for 2 component.
KEY_NAME = "FilterCategory" and KEY_STRING_VALUE="Administrative"
If you're using:
<property name="log.folder" value="D:\tridion\log"/>
then it's expected that you'll get no logging. Logback expects either double backslashes or simple (fwd)slashes. Example:
<property name="log.folder" value="D:\\tridion\\log"/>
or
<property name="log.folder" value="D:/tridion/log"/>
Further more, if you want to see what (JPQL) query Tridion creates for you from your Broker query then you need to set the logging to TRACE and to search in your logs for the following:
TRACE JPAQueryDAO - Broker Query generated:
This will give you an impression about the final SQL query generated in the end.
My last remark is about the KeywordCriteria and how you're using it. You should know that KeywordCriteria does not relate in any way to the CUSTOM_META table. For queries related to that table you should use the criterias called "CustomMeta***Criteria"
Probably, in your case you need to use:
new CustomMetaValueCriteria(new CustomMetaKeyCriteria("FilterCategory"), "Administrative");
Hope this helps.
Cheers,
Daniel.
Whenever a Broker Query doesn't give me the results I expect, I head towards the MSSQL Query Profiler to see what actually happens on the database level.
I documented this process in an article on the Tridion practice wiki: http://code.google.com/p/tridion-practice/wiki/TroubleshootBrokerQueryGeneration .
A quick summary of the steps:
start the MSSQL Query Profiler
start a new Trace
filter the trace on database name
reload your page, so the query fires
find the query in the Profiler
copy the query into a better tool and reformat it
Once you reach step 6, it is often somewhat clear why there are no results. I often end up then modifying the SQL to give the results that I'm looking for. And from that I modify the Criteria to generate that SQL, which can at times be a challenge.

How are keywords in metadata stored?

I'm researching options to synchronize external data to a Category and Keyword list.
I have a metadata field with a states field that uses a category called US States.
When I preview my component with a simple XSLT component template (<xsl:copy-of select="." />), I can see:
<tcm:Content>
...
</tcm:Content>
<tcm:Metadata><Metadata xmlns="http://createandbreak.net/schema/generic">
<states>California</states>
<states>New York</states>
</Metadata></tcm:Metadata>
When I update the keyword and preview, I can see updated values.
<tcm:Content>
...
</tcm:Content>
<tcm:Metadata><Metadata xmlns="http://createandbreak.net/schema/generic">
<states>Californias</states>
<states>New York</states>
</Metadata></tcm:Metadata>
Which is great. It looks like we do not need to synchronize components (open, edit, and save) to use updated keywords. Is that a safe assumption?
If I update a keyword, do I need to update components that use it in order to publish component presentations with the updated values?
Do I need to also be careful when moving components with content porter?
No, you don't need to do anything manually for those Keyword fields to be "Content Porter"-safe. Tridion stores the link from your Keyword field to the Keyword definition (in the category) as a so-called managed link (a TCM URI).
The reason you don't see this value in your XSLT has to do with the way Tridion traditionally exposes the Keywords in WebDAV: it hides the TCM URIs there and instead just exposes the value of the selected keyword. Since Keyword values must be unique within their category, this will always allow you to look up the correct TCM URI if needed.
But when exporting (and in general when you're using the API to access content) you should retrieve the Component XML with the TCM URIs in place. Check the API documentation for your programming language to see which Filter/ReadOption you need to specify for that.

Resources