Re: [MarkLogic Dev General] increasing # of results on appbuilder built app

2013-11-04 Thread Micah Dubinko
? It doesn’t appear to be in some of the early 6.0-x deployments. Thanks, David From: general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com [mailto:general-boun...@developer.marklogic.commailto:boun...@developer.marklogic.com] On Behalf Of Micah Dubinko Sent: Friday

Re: [MarkLogic Dev General] How to move content from one data base to another

2013-02-11 Thread Micah Dubinko
Hi Gurbeer, It will be more than worth your while to get familiar with a tool to help with this. Many folks have had success with Corb. http://developer.marklogic.com/code/corb If you really want to do it from QC, you'll have to do some work to break the job down into smaller pieces to avoid

Re: [MarkLogic Dev General] Custom results display

2013-01-03 Thread Micah Dubinko
Hi Sini, You'll want to look at application/lib/viz/results/results.js in the built app to see how the current result page gets rendered, and adjust accordingly. Note that this file gets overwritten upon redeploy, so take care with backups. We're currently looking into ways to make this

Re: [MarkLogic Dev General] Syntax error?

2012-12-05 Thread Micah Dubinko
Check for '' characters, particularly inside quoted strings. They must be escaped as amp;. -m On Dec 5, 2012, at 11:24 AM, Kalinosky, Mary mary.kalino...@thieme.commailto:mary.kalino...@thieme.com wrote: I’m trying to insert a document into the database in the query console. The following

Re: [MarkLogic Dev General] Performance Overhead - cts:sum

2012-10-24 Thread Micah Dubinko
If you have a range index defined for this (and you definitely should for this kind of operation) and you're running on 6 or later, try to use cts:sum-aggregate instead of cts:sum. -m On Oct 23, 2012, at 10:20 PM, Abhishek53 S abhishek5...@tcs.commailto:abhishek5...@tcs.com wrote: Hi All,

Re: [MarkLogic Dev General] Customizing the Generated Search Options Node

2012-10-23 Thread Micah Dubinko
Hi Shannon, There exists on the Search tab a new UI element called Custom XML Options, where you can enter XML that gets saved into the project and appended into the REST interface options upon deploy. As with $ADDITIONAL-OPTIONS, it won't work for things such as constraints that already have

Re: [MarkLogic Dev General] EXPath Console for MarkLogic

2012-10-01 Thread Micah Dubinko
This is great. -m On Sep 20, 2012, at 8:39 AM, Florent Georges wrote: Hi, I've been working on an EXPath Console for MarkLogic, providing you the opportunity to install EXPath XAR packages into MarkLogic. If you want to have a look at it, look at the following page, and install it on

Re: [MarkLogic Dev General] Faster alternative to fn:last()

2012-06-22 Thread Micah Dubinko
An efficient way is to use fn:subsequence instead of a predicate. -m On Jun 22, 2012, at 2:00 PM, Damon Feldman wrote: Danny, Try subsequence($pageSessionLogs, count($pageSessionLogs), 1) Anything in square brackets is evaluated once for each element of the sequence, so if you profile that

Re: [MarkLogic Dev General] Issue with operator in Search api

2012-06-08 Thread Micah Dubinko
depending on this override behavior since 4.2. -Will From: general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com [mailto:general-boun...@developer.marklogic.com] On Behalf Of Micah Dubinko Sent: Wednesday, June 06, 2012 9:43 PM To: MarkLogic Developer Discussion

Re: [MarkLogic Dev General] Issue with operator in Search api

2012-06-06 Thread Micah Dubinko
Hi Amit, Welcome. First a bit of general advice, which you may have heard before. Run the function search:check-options often. Set up your build environment so that it runs every time you do a search. If it returns empty-sequence, you're golden, otherwise it's alerting you to current or

Re: [MarkLogic Dev General] How to use near query in search:search function

2012-04-16 Thread Micah Dubinko
I believe you can add options=ordered to the joiner element here. -m On Apr 16, 2012, at 12:14 PM, Steiner, David J. (LNG-DAY) wrote: Is there a way to specify “ordered”? I see: joiner strength=30 apply=near2 consume=2 element=cts:near-queryNEAR//joiner” And “near2”s implementation… So,

Re: [MarkLogic Dev General] Server field scope / safety?

2012-02-29 Thread Micah Dubinko
Ron, The plugin implementation uses a map stored in a server-field. Accessor functions that return one of these maps explicitly make a copy of it in order to prevent the situation you described. -m On Feb 29, 2012, at 9:28 AM, Ron Hitchens wrote: I have a question about how server

Re: [MarkLogic Dev General] Timing in snippet extension module

2012-02-22 Thread Micah Dubinko
Hi Will, xdmp:elapsed-time measures the overall elapsed time for the request, at the instant it is called. Inside Search API, at the start of processing the specific search we record $t-minus-zero then subtract that from the elapsed-time at the end to produce the total-time value. This is to

Re: [MarkLogic Dev General] Timing in snippet extension module

2012-02-22 Thread Micah Dubinko
Message- From: general-boun...@developer.marklogic.com [mailto:general-boun...@developer.marklogic.com] On Behalf Of Micah Dubinko Sent: Wednesday, February 22, 2012 4:43 PM To: MarkLogic Developer Discussion Subject: Re: [MarkLogic Dev General] Timing in snippet extension module Hi

Re: [MarkLogic Dev General] App Builder Question

2012-01-30 Thread Micah Dubinko
Hi Randy, This is a known bug. I don't have a specific date for a fix, though we're working on it. -m On Jan 30, 2012, at 3:05 PM, Randy Smith wrote: All, I want to use App Builder to prototype a search app, then mod the code to do additional things. The problem I'm having is that when I

Re: [MarkLogic Dev General] search:parse/unparse not reversible?

2012-01-04 Thread Micah Dubinko
to a different dev host. - J.J. Micah Dubinko wrote: J.J., Your understanding of the relationship between parse and unparse is correct. Which version of the server are you running? This looks like a bug that was recently fixed in 4.2-8 and 4.1-12. -m On Jan 3, 2012, at 10:22 AM, J.J. Larrea

Re: [MarkLogic Dev General] search:parse/unparse not reversible?

2012-01-03 Thread Micah Dubinko
J.J., Your understanding of the relationship between parse and unparse is correct. Which version of the server are you running? This looks like a bug that was recently fixed in 4.2-8 and 4.1-12. -m On Jan 3, 2012, at 10:22 AM, J.J. Larrea wrote: Please correct any misunderstanding I may

Re: [MarkLogic Dev General] How to get different facet counts for different searchable-expression in Search API

2011-10-18 Thread Micah Dubinko
Hi Will, Everything you want to search exists in document fragments (not properties) right? What would happen if you switched in a different searchable-expression via operator and state? The combined query is taken into account by faceting, but the searchable-expression is not. -m On Oct

Re: [MarkLogic Dev General] Question about search:search api and constraints

2011-10-14 Thread Micah Dubinko
Hi Darin, In 4.2 you'd need to either stack constraints (or write a custom constraint). Stacking as in: constraint name=prop properties/ /constraint constraint name=aggregation value element ns=http://prismstandard.org/namespaces/basic/2.0/; name=aggregationType/

Re: [MarkLogic Dev General] Read only access to Admin interface.....

2011-09-08 Thread Micah Dubinko
Abhishek, I don't know what your timeline looks like, but if you can hold out for MarkLogic 5.0, a RO admin interface comes out of the box. -m On Sep 8, 2011, at 4:57 AM, Abhishek53 S wrote: Hi Folks I am trying to have read only access to admin console (8001) of ML server...User with this

Re: [MarkLogic Dev General] Querying across multiple documets loaded into a collection

2011-08-18 Thread Micah Dubinko
Try this instead: for $test in collection(TESTDOCS)/* If it yields results, look at what element it returns. If it doesn't yield results, then for some reason your documents don't have any elements, and may not be getting loaded as XML. Does everything look good from the explore view? -m On

Re: [MarkLogic Dev General] Search API schema

2011-08-12 Thread Micah Dubinko
Shannon, The @apply attribute anywhere in Search API indicates that you can point it at any desired function (with corresponding @ns and @at) to produce whatever query you want for the empty case. The value of @apply can be any function local-name, but a few built-in ones are special. W3C XML

Re: [MarkLogic Dev General] Timezone specific today with computed buckets in search:search

2011-07-25 Thread Micah Dubinko
I could be completely misremembering this, but you should try a custom anchor. (off the top of my head) anchor name=mycustom-anchor apply=fname ns=http://namespace; at=path/to/module.xqy/ The function will get the datatype as a string, and should return a value of that datatype with whatever

Re: [MarkLogic Dev General] Is INFO magic in search:search ? bad performance

2011-07-11 Thread Micah Dubinko
Another thing you should do is include return-plantrue/return-plan in the options node, which will give a full readout of the query plan in the response. Also debugtrue/debug will provide some more details, including the actual XQuery that implements the query. I'm guessing the word info

Re: [MarkLogic Dev General] Getting odd results from Search API

2011-04-11 Thread Micah Dubinko
Will, What version of MarkLogic are you running on your local box and on the others? Since the value that ends up in @total comes comes from a high-speed estimate (cts:remainder actually) it can vary, but I also recall a bug that was filed and fixed regarding very similar behavior, though I

Re: [MarkLogic Dev General] Question about node()

2010-12-01 Thread Micah Dubinko
See below On Dec 1, 2010, at 3:28 PM, seme...@hotmail.com wrote: In the XPath spec, it says that A node test node() is true for any node of any type whatsoever. (http://www.w3.org/TR/xpath/#node-tests). So how come the attribute is not included in the following code: let $example := bob

Re: [MarkLogic Dev General] Inserting node to xml before it is loaded in Marklogic

2010-10-26 Thread Micah Dubinko
I believe this could help you: http://github.com/marklogic/commons/tree/master/memupdate/ Thanks, -m On Oct 26, 2010, at 2:57 AM, Geert Josten wrote: Hi Pragya, It sounds like you are looking for 'in-memory' updating of the XML. There was a small library module on XQzone that

Re: [MarkLogic Dev General] cts:similar-query

2010-10-25 Thread Micah Dubinko
Hi Shannon, I believe that options are the 3rd arg on cts:similar-query. The 2nd, $weight as xs:double is optional. See inline below. Thanks! -m On Oct 24, 2010, at 10:42 PM, Shannon wrote: I'm afraid I can't spot what's wrong here…. Thanks. let $options := options

Re: [MarkLogic Dev General] question about search

2010-08-26 Thread Micah Dubinko
Helen, You are exactly on the right track. (though the default joiner is OR in uppercase, not or) Search API doesn't (yet!) have an out-of-the-box way to combine these, and thus avoid the OR in your query. -m On Aug 26, 2010, at 6:49 AM, helen chen wrote: Hello there, we have different

Re: [MarkLogic Dev General] Totally odd search:search behavior

2010-08-11 Thread Micah Dubinko
Shannon, Include the option debugtrue/debug, and you will get some additional output, including the full flwor that gets used to run the search. Then you can determine 1) Does the flwor (including cts:search) look correct? 2) Does the flowr return the expected results when run in CQ or a

Re: [MarkLogic Dev General] Search API: supply a default search:search constraint?

2010-06-23 Thread Micah Dubinko
Hey Shannon, Would the additional-query option meet your need here? Effectively, it gets AND-ed with the rest of the query. Or if you are looking to constrain only bare terms, you might override the term function with term apply=myfunction... -m On Jun 23, 2010, at 3:31 PM, Shannon wrote:

Re: [MarkLogic Dev General] Unexpected behavior

2010-04-02 Thread Micah Dubinko
Try turning off function mapping with this declration at the top (after any module imports) declare option xdmp:mapping false; Does that at least allow the function to get called (or cause a coercion error involving ())? -m On Apr 2, 2010, at 2:01 PM, spig wrote: The point is that the

Re: [MarkLogic Dev General] Unexpected behavior

2010-04-02 Thread Micah Dubinko
Close. :-) On Apr 2, 2010, at 4:15 PM, spig wrote: So, let me make sure I understand. When I declare a function with any number of parameters, if one of those parameters requires a singleton, and I pass in an empty sequence, the function will not likely be called if function mapping is

Re: [MarkLogic Dev General] xdmp:http-get with auto-follow redirect

2010-03-04 Thread Micah Dubinko
It may be a good idea to count how many redirect cycles you've followed and give up at some point. :-) -m On Mar 4, 2010, at 12:40 PM, Geert Josten wrote: Hi Steve, You will have to follow the redirect yourself, but wrapping the function in a function of your own shouldn't be difficult.

Re: [MarkLogic Dev General] Search:search() with fragmentation

2010-02-24 Thread Micah Dubinko
In general, Search API is designed to work better without fragmentation in play. The @total which is estimated (cts:remainder actually) will be more accurate that way. -m On Feb 24, 2010, at 5:57 AM, mano m wrote: Hi To implement pagination in search application, we need the total number

Re: [MarkLogic Dev General] facet based on collection

2010-02-19 Thread Micah Dubinko
Hi, In the Search API, add a constraint like this to your options node: constraint name=Collection-facet collection facet=true facet-optionlimit=20/facet-option /collection /constraint -m On Feb 19, 2010, at 3:27 AM, mano m wrote: Hi , I have conetent

Re: [MarkLogic Dev General] element nodes cannot have binary node children in range/

2010-02-18 Thread Micah Dubinko
to apply=no-snippet in these options and let me know if it gives an error or not. Also add an option debugtrue/debug and let me know if any new messages show up in the response output. Thanks! -m On Wed, Feb 17, 2010 at 11:20 PM, Micah Dubinko micah.dubi...@marklogic.com wrote: Hi

Re: [MarkLogic Dev General] element nodes cannot have binary node children in range/

2010-02-17 Thread Micah Dubinko
Hi, Just a guess, this might be caused by binary documents in your database that are getting returned as search results. (thought it seems a little strange that a binary document would get picked up by that search) As a test, if you change it to transform-results apply=empty-snippet the

Re: [MarkLogic Dev General] Distinct Nodes/Value Functions

2010-02-16 Thread Micah Dubinko
Tony, You might try the functx functions functx:distinct-deep or functx:distinct-nodes. The functx library ships with Mark Logic server 4.1+ in two flavors, either with comments (easier to read) or without (slightly faster). We don't support it (it's open source) but it does have lots of

Re: [MarkLogic Dev General] How to use XPath in Search:search() function.

2010-02-15 Thread Micah Dubinko
Nalini, For your first issue, you are better off getting your data in shape to really be string-comparable or int-comparable. This is how the indexes work, and trying to work around bad data in your application will only lead to excess complexity and trouble. For your second question, if you

Re: [MarkLogic Dev General] context item within function calls

2010-02-04 Thread Micah Dubinko
Since the / operator sets the context node for the expression to the right of it, it is possible to set it to an arbitrary context node like this: $context/xdmp:value(.) You can replace . with any expression, which will have $context as the context node. -m On Feb 4, 2010, at 4:24 PM, Mark

Re: [MarkLogic Dev General] Oscars Sample Application Deployment Failed

2010-01-07 Thread Micah Dubinko
Ajay, To diagnose the issue, we will need to see the error logs. Also it will be helpful to know which platform you are on (Windows? Linux?) and which specific version of the software you are using, and any other relevant details. For example on Linux the file should be at

Re: [MarkLogic Dev General] Towards a more modular app architecture ...

2009-12-15 Thread Micah Dubinko
In terms of app architecture XQMVC is definitely worth a look: http://code.google.com/p/xqmvc/ And then there's my take... http://dubinko.info/blog/2009/11/29/model-endpoint-template/ -m On Dec 15, 2009, at 8:54 AM, Florent Georges wrote: Lee, David wrote: Hi David, Any other

[MarkLogic Dev General] Pre EA1 walkthrough notes

2009-12-04 Thread Micah Dubinko
Todos: * JM to provide Application Services graphic * change title and graphic on entry page * s/Projects/Applications/ on entry page * explanatory paragraph, JM to provide * Make Help link on entry page point to existing appbuilder/help.xqy * on the run collector overlay, use the right label for

Re: [MarkLogic Dev General] Pre EA1 walkthrough notes

2009-12-04 Thread Micah Dubinko
Autocomplete strikes again. Please ignore. Thanks and apologies, -m On Dec 4, 2009, at 1:55 PM, Micah Dubinko wrote: Todos: ... ___ General mailing list General@developer.marklogic.com http://xqzone.com/mailman/listinfo/general

Re: [MarkLogic Dev General] Optimize exact match searches on attributes

2009-11-10 Thread Micah Dubinko
David, I'm guessing the optimizer already does this, but just in case, try using the atomic comparison operator eq instead of =. (The value in $code will never be a sequence, right?) $root/tree/item[ @code eq $code ] Even though it goes against conventional wisdom, also try $root//item [

Re: [MarkLogic Dev General] Validating an XML document in MarkLogicthat references a DTD as part of a precommit trigger

2009-10-30 Thread Micah Dubinko
On Oct 30, 2009, at 8:17 AM, Mary Holstege wrote: It will work with no-namespaced documents too. The process of locating the schema is essentially the same, except it is looking for a schema with no target namespace. True, though loading a no-namespace Schema into the database can

Re: [MarkLogic Dev General] how xdmp:node-replace works

2009-10-12 Thread Micah Dubinko
Rahul, Based on the error message, it seems like the error is coming from the call to xdmp:node-uri. It looks like your cts:search is returning empty, which isn't allowed as an input to xdmp:node-uri. -m On Oct 12, 2009, at 6:38 PM, Rahul Saluja wrote: Hi danny, if you could spare some

Re: [MarkLogic Dev General] Need help to create word constraint

2009-09-18 Thread Micah Dubinko
Hi Anil, I am able to reproduce this behavior. I filed it as a bug in our tracking system. As a workaround, in the element/attribute picker, just below the not found message, choose the Other radio button then manually enter an element localname of LINE. Thanks for catching this, -m On

Re: [MarkLogic Dev General] using thesaurus with the new search:search API

2009-08-04 Thread Micah Dubinko
Not at present, but it is filed as an RFE (7798). -m On Aug 4, 2009, at 7:41 PM, Surajit Bhattacharjee wrote: Does the new search:search API support an option for pointing to a thesaurus and expanding the search? Surajit ATT1.txt ___ General

Re: [MarkLogic Dev General] functx library usage with ML

2009-07-13 Thread Micah Dubinko
There is: import module namespace functx = http://www.functx.com; at / MarkLogic/functx/functx-1.0-nodoc-2007-01.xqy; or a tiny bit slower but with lots of documentation comments: import module namespace functx = http://www.functx.com; at / MarkLogic/functx/functx-1.0-doc-2007-01.xqy; But I

Re: [MarkLogic Dev General] functx library usage with ML

2009-07-13 Thread Micah Dubinko
functx is used internally by Application Services, and first shipped with 4.1. Officially it's considered unsupported, which is why it has a lower profile in the documentation. That said, it has a ton of useful functions and good documentation at http://www.xqueryfunctions.com/xq/ -m On

Re: [MarkLogic Dev General] functx library usage with ML

2009-07-11 Thread Micah Dubinko
Jakob, Is this in the functx library that ships with MarkLogic, or from a separate download? -m On Jul 11, 2009, at 2:33 PM, Jakob Fix wrote: hi, here's a late night question: I'm trying to use the functx xquery library in my ML application. Firstly, I had to add declare default

Re: [MarkLogic Dev General] render:custom Documentation

2009-07-09 Thread Micah Dubinko
Hey Betty, There is not. The render:* stuff is fairly internal (and likely to change in future releases). Thanks, -m On Jul 9, 2009, at 10:55 AM, Betty Harvey wrote: Is there any documentation for the render:custom element? I have searched the MarkLogic site and archives and can't find