Hi David, Is there now a class that provides these ranges ?
Regards, Danny On Tue, May 8, 2012 at 10:16 AM, David Lee <[email protected]> wrote: > Quite an interesting question that I'm supprised I've never heard ask > before.**** > > ** ** > > I found this **** > > ** ** > > > http://publib.boulder.ibm.com/infocenter/db2luw/v9/index.jsp?topic=%2Fcom.ibm.db2.xquery.doc%2Fdoc%2Fxqrnumrng.htm > **** > > ** ** > > But that's DB2 specific.**** > > ** ** > > I couldn't find anything in XQuery that supplies these magic numbers, and > the specs are intentionally vague about the range of int and integer etc.* > *** > > Even tried**** > > ** ** > > -1 cast as xs:unsignedInteger**** > > ** ** > > but no go ( Damn typed languages )**** > > ** ** > > I think we should support a class that provides these ranges ... **** > > but in the mean time pick something "really big" :)**** > > ** ** > > > ----------------------------------------------------------------------------- > **** > > David Lee > Lead Engineer > MarkLogic Corporation > [email protected] > Phone: +1 650-287-2531 > Cell: +1 812-630-7622 > www.marklogic.com > > This e-mail and any accompanying attachments are confidential. The > information is intended solely for the use of the individual to whom it is > addressed. Any review, disclosure, copying, distribution, or use of this > e-mail communication by others is strictly prohibited. If you are not the > intended recipient, please notify us immediately by returning this message > to the sender and delete all copies. Thank you for your cooperation.**** > > ** ** > > *From:* [email protected] [mailto: > [email protected]] *On Behalf Of *Danny Sinang > *Sent:* Tuesday, May 08, 2012 10:10 AM > *To:* MarkLogic Developer Discussion > *Subject:* Re: [MarkLogic Dev General] How to get max value in ML**** > > ** ** > > Hi Geert,**** > > ** ** > > Thanks.**** > > ** ** > > Yes, you have a good point there. Returning all those results will be > inefficient.**** > > ** ** > > But I'll be forcing the users to limit the results by date instead and > we'll be imposing a maximum date range.**** > > ** ** > > I just need to make sure search:search() returns all the results because > I'm feeding the entire result set to a function that computes for some > aggregate values.**** > > ** ** > > Regards, > Danny**** > > On Tue, May 8, 2012 at 10:04 AM, Geert Josten <[email protected]> > wrote:**** > > Hi Danny,**** > > **** > > There is no pre-declared constant as far as I know if that is what you > mean. But I’m sure it follows the specs of the XML Schema standard.**** > > **** > > Are you sure you want search:search to return so many results in one call? > It is memory in-efficient, and showing so many results in for instance in a > browser is likely to choke the browser. If you’d use a crawler that > supports parallel threads, you’d see that a page size of something like 100 > to 500 would work much better..**** > > **** > > Kind regards,**** > > Geert**** > > **** > > *Van:* [email protected] [mailto: > [email protected]] *Namens *Danny Sinang > *Verzonden:* dinsdag 8 mei 2012 15:58 > *Aan:* MarkLogic Developer Discussion > *Onderwerp:* Re: [MarkLogic Dev General] How to get max value in ML**** > > **** > > Hi Geert,**** > > **** > > I'm trying to get the maximum unsigned long value to tell seach:search() > to return all results.**** > > **** > > I was hoping there would be an ML function out there that would tell me > the max unsigned long value.**** > > **** > > Regards,**** > > Danny**** > > On Tue, May 8, 2012 at 9:54 AM, Geert Josten <[email protected]> > wrote:**** > > Hi Danny,**** > > **** > > Can you elaborate on what you exactly mean? Given a sequence, you can just > use fn:max() to get the highest value. If you want to determine the highest > value that occurs anywhere in the database, you can use cts:values with a > descending order and limit of 1. The first and single result is the > highest..**** > > **** > > Kind regards,**** > > Geert**** > > **** > > *Van:* [email protected] [mailto: > [email protected]] *Namens *Danny Sinang > *Verzonden:* dinsdag 8 mei 2012 15:49 > *Aan:* general > *Onderwerp:* [MarkLogic Dev General] How to get max value in ML**** > > **** > > Hi,**** > > **** > > Is there a function in ML that returns the maximum values for integer and > unsigned long ?**** > > **** > > Regards, > Danny**** > > > _______________________________________________ > General mailing list > [email protected] > http://developer.marklogic.com/mailman/listinfo/general**** > > **** > > > _______________________________________________ > General mailing list > [email protected] > http://developer.marklogic.com/mailman/listinfo/general**** > > ** ** > > _______________________________________________ > General mailing list > [email protected] > http://developer.marklogic.com/mailman/listinfo/general > >
_______________________________________________ General mailing list [email protected] http://developer.marklogic.com/mailman/listinfo/general
