I am trying to use Entity Enrichment pipeline for document conversion. I have the following XQuery in the Query Console for a DB that has Content processing installed:
let $myxml := <node>George Washington never visited Norway. If he had a Social Security number, it might be 000-00-0001.
</node>
return cts:entity-highlight($myxml,
element { fn:replace($cts:entity-type, ":", "-") }
{ $cts:text })
...which results in the following error:
"Entity enrichment libraries not installed for host"
How to resolve this issue?
cts:entity-enrich() and cts:entity-highlight() are no longer available, so that piece of code will not work in MarkLogic 8.
There are a number of ways to do entity enrichment of documents in MarkLogic, such as
install a third-party entity extraction tool such as Smartlogic or PoolParty or Temis
If you know how to define your entities in terms of queries, write a reverse query for each entity type and use cts:highlight() to markup those entities.
For more information, drop me a note at stephen dot buxton at marklogic dot com
For MarkLogic 6, you can add entity enrichment libraries for your database by going to the MarkLogic console at 8001, choosing Configure, then Databases. Select your database and Content Processing beneath the database in the tree. Choose Install to install content processing libraries.
For MarkLogic 8, cts:entity-highlight is no longer supported. Entity Enrichment Pipelines can be created, and cts:highlight can be used for highlighting, e.g.:
cts:highlight($myxml, "Norway", <b>{ fn:replace($cts:text, "-", ":") }</b>)
...where the second parameter can be a query and the third parameter can include any markup.
It may also be useful to take a look at the MarkLogic Search Developer's Guide.
Related
I have more than 50 namespaces used in my Marklogic API's .The count can go on increasing further - I am looking for a way to find the feasibility if there is any way to utilise or store them in database or add them in app-server and later on how to invoke them in all the Xquery files- where they have been till now are updated manually in case of any new addition.
Yes! If you go to the Admin API (port 8001) and go under either your Group or App Servers, you'll see a Namespaces section on the left and in there you can enter your commonly used namespaces. After that they'll just exist in all the code automatically.
After implicit contract upgrade i got an error when execute tx - java.lang.IllegalArgumentException: Multiple attachments set for the same contract.
the problem related to net.corda.core.transactions.TransactionBuilder.selectContractAttachmentsAndOutputStateConstraints method which detect groups contained more than one attachment for the same contract name.
To perform upgrade I have changed the version of the contracts, so I do not have contracts with the same version on the node.
In the table NODE_ATTACHMENTS_CONTRACTS i really have the same CONTRACT_CLASS_NAME and different ATT_ID, however it should be in this way when I add new contract version (add jar to cordapps folder).
Such approach described in https://github.com/corda/samples/tree/release-V4/implicit-cordapp-upgrades and in the example it functioning well.
Thanks for any help.
Normally Multiple attachments error is caused by incorrect project structures that have multiple sub-projects(with the same name) under the root project.
Unfortunately, without seeing your code, we cannot really see what is the issue with your code.
Thus, i would suggest you follow the sample and do it again, and consult with
our documentation at
https://docs.corda.net/docs/corda-os/4.4/api-contract-constraints.html#implicit-vs-explicit-contract-upgrades
the contract upgrade article
https://medium.com/corda/contract-upgrades-and-constraints-in-corda-425055a9a47f
Does anyone know how to set/change a repository name in alfresco?
id=-default-, name=, description=, capabilities=Repository Capabilities
The Alfresco CMIS calls started returning an empty string for name sometime around 5.0, I believe. According to the spec, the name is not a required piece of information. The server is required to return a unique ID for each repository in the system, but that's it.
I do not believe you can change the name without touching Alfresco CMIS implementation Java classes.
Besides, Alfresco only supports a single repository so a name isn't going to add a lot of value.
I've been trying to store my strings in a database using resource files to fetch them. I've been following the guide from http://afana.me/post/aspnet-mvc-internationalization-store-strings-in-database-or-xml.aspx
The example works fine enough when i use his sql code based on ADO.net to fetch the strings from the database.
But i want to use Entity Framework to fetch the strings from the database, because my translation table is quite different. Could anyone show me an example of how to use Entity Framework in the resource project(assembly?), because i can't seem to get it to work. I cant import any of my models or contexts from my main project with "using", and it tells me i have duplicate models when i copy them to the resources project/assembly
How does Flyway handle multiple schema dependencies?
Ie
V1_CREATE_TABLE.sql in SCHEMA_A
V2_CREATE_VIEW.sql in SCHEMA_B (based on table in schema A)
Is it possible to ensure that V1 is created before V2?
It is also possible to get into a cross dependency. For example say V3_CREATE_VIEW_2.sql in SCHEMA_A (based on view in schema B). How do we ensure that dependency?
Flyway will execute the scripts in order based on their version numbers. If you want a single instance of Flyway to manage objects in multiple schemas, you must prefix the object names in the migration scripts.