[MarkLogic Dev General] MarkLogic Upgrade from 6 to 8

2016-01-27 Thread Khan, Kashif
Hello Everyone,

We just upgraded our MarkLogic server from version 6 to latest version 8. Now 
when we try to restart the MarkLogic server we are getting the following error. 
Does anyone know what is happening here.

Starting MarkLogic: /opt/MarkLogic/bin/MarkLogic: error while loading shared 
libraries: libsasl2.so.3: cannot open shared object file: No such file or 
directory


Best Regards,
Kashif Khan
___
General mailing list
General@developer.marklogic.com
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] ML 4.2 backup restore to ML 7.x

2014-03-28 Thread Khan, Kashif
I would suggest upgrading Marlogic to version 5 then 6 and then 7. I think 
that’s what MarkLogic recommends in the Installation document as well. Its a 
big jump directly going from Version 4 to Version 7.


Kashif Khan


From: Wayne Feick wayne.fe...@marklogic.commailto:wayne.fe...@marklogic.com
Reply-To: MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Date: Friday, March 28, 2014 at 5:30 PM
To: general@developer.marklogic.commailto:general@developer.marklogic.com 
general@developer.marklogic.commailto:general@developer.marklogic.com
Subject: Re: [MarkLogic Dev General] ML 4.2 backup restore to ML 7.x

Hi Gene,

The missing journal file warning won't stop the restore. I'd recommend filing 
a support case and working things through that channel.

Wayne.



On 03/28/2014 02:21 PM, Danny Sokolsky wrote:
Was this done from a MarkLogic database backup (that is what my assumption 
was)?  Is it just that forest that is having trouble mounting?  How big is this 
backup (size and number of forests)?  Are you restoring into the exact same 
topology as you backed up from (that is what restore expects)?

-Danny

From: Gene Thomas [mailto:thomg...@att.net]
Sent: Friday, March 28, 2014 2:16 PM
To: Danny Sokolsky; MarkLogic Developer Discussion
Subject: Re: [MarkLogic Dev General] ML 4.2 backup restore to ML 7.x

Thank you Danny,

That is what I am trying to do.

Here is the text of an email I sent internally about it.

We have an NAS mount connected to both clusters.  On the ML 4.2 side it is 
read/write.
On the ML 7.x side it is mounted read only.

I have not been able to complete a restore from that location either by 
database restore or forest restore.
The access to the /Marklogic_temp/ mount may need to be read write.  When the 
actual restore process gets to 00:00:00 estimated time left, it just sits there 
with the forest state saying “recovering”

I see this message in the logs at that point:
Mar 28 16:01:02  MarkLogic: Missing journal file 
/mldata02/RestoredForests/dodge-daily-forest01/Journals/Journal1-1970010100-0-0-0

I have waited 30 minutes past the time it said it had finished copying data and 
still no completion of the restore.

Any help would be appreciated as we are supposed to perform the actual process 
from ML 4.2 QA to ML 7.x QA over the weekend.

Gene


From: Danny Sokolsky 
danny.sokol...@marklogic.commailto:danny.sokol...@marklogic.com
To: Gene Thomas thomg...@att.netmailto:thomg...@att.net; MarkLogic 
Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Sent: Friday, March 28, 2014 2:02 PM
Subject: RE: [MarkLogic Dev General] ML 4.2 backup restore to ML 7.x

I can’t say that I have done this, but I would expect it to work.  I would 
expect that, as soon as it mounted the db in 7, that it would start reindexing 
(if reindexing is enabled).

I would test it first, but I think it will work.

-Danny

From: 
general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com
 [mailto:general-boun...@developer.marklogic.com] On Behalf Of Gene Thomas
Sent: Friday, March 28, 2014 1:59 PM
To: general@developer.marklogic.commailto:general@developer.marklogic.com
Subject: [MarkLogic Dev General] ML 4.2 backup restore to ML 7.x

Has anyone successfully backed up a database on ML 4.2-7 and restored it in a 
new environment with a fresh ML 7.0-2.1 install?

Gene




___
General mailing list
General@developer.marklogic.commailto:General@developer.marklogic.comhttp://developer.marklogic.com/mailman/listinfo/general


--
Wayne Feick
Principal Engineer
MarkLogic Corporation
wayne.fe...@marklogic.commailto:wayne.fe...@marklogic.com
Phone: +1 650 655 2378
www.marklogic.comhttp://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.___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] One node CPU utilization maxed out but others not in a 5 node cluster once load increases

2013-10-12 Thread Khan, Kashif
It looks good now Thanks. You can close the ticket.


Kashif Khan, PMI-ACP
Sr. Solution Architect
Publishing Technology

Houghton Mifflin Harcourt
9400 South Park Center Loop
Orlando, FL 32819
Office: 407.345.3420
Mobile: 407.949.4697
hmhco.com

From: indar verma send2i...@yahoo.co.inmailto:send2i...@yahoo.co.in
Reply-To: indar verma send2i...@yahoo.co.inmailto:send2i...@yahoo.co.in, 
MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Date: Monday, September 30, 2013 8:35 AM
To: Michael Blakeley m...@blakeley.commailto:m...@blakeley.com, MarkLogic 
Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Cc: 
general-requ...@developer.marklogic.commailto:general-requ...@developer.marklogic.com
 
general-requ...@developer.marklogic.commailto:general-requ...@developer.marklogic.com
Subject: Re: [MarkLogic Dev General] One node CPU utilization maxed out but 
others not in a 5 node cluster once load increases

Hi Michael,

Thanks a lot for your suggestions and explaining me the problem in detail.

There are 4 forests in each node,

-- 2 masters and 2 replicas

Total 20 forests (10 masters + 10 replicas)

I am attaching some screenshots of the DB

I started looking into the xqy and trying to reduce response time.

I will follow your other instructions too to see the other factors.

Actually problem is, I have to give some justifications of maximum use of CPU 
in ML4 node only even it is data node and all the data is not present in that 
node only. so I am struggling to get a concrete reason. every time, my customer 
is asking why Ml4 node only going for maximum.

Thanks  Regards,
JJ


From: Michael Blakeley m...@blakeley.commailto:m...@blakeley.com
To: indar verma send2i...@yahoo.co.inmailto:send2i...@yahoo.co.in; 
MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Cc: 
general-requ...@developer.marklogic.commailto:general-requ...@developer.marklogic.com
 
general-requ...@developer.marklogic.commailto:general-requ...@developer.marklogic.com
Sent: Monday, 30 September 2013 1:44 AM
Subject: Re: [MarkLogic Dev General] One node CPU utilization maxed out but 
others not in a 5 node cluster once load increases

Does zenoss mean Xen virtualization? PVM or HVM?

How many forests are on each host?

You could simply try upgrading from 6.0-3.2 to the latest release, 6.0-4, and 
see if that helps. But if it were me I would want to know which query or 
queries caused the problem.

Even though you aren't sending queries directly to that busy host, it's 
resolving index lookups as requested by the eval hosts. So it's still important 
to look at long-running queries, as these are the ones likely driving the load 
on your busy host. You also want to have a reproducible test case, and the best 
way to build that is to isolate a query that recreates the high load.

At the same time, dig into how utilization is measured and exactly what the 
numbers are. It's not enough to say that a host is maxed out: you need to 
understand which subsystem is the bottleneck. It's quite difficult to drive a 
16-core or 32-core host to 0% idle, especially if the workload is mixed between 
network, disk, and CPU activity. You really want to know how much of each is 
involved, to better understand what maxed out really means. For example 
'iostat -mxz 15' is a good way to monitor current activity, or if sysstat is 
collecting data then sar can display it. Just to illustrate the point, here are 
some low-utilization numbers from a system I happen to have handy.

12:00:01 AMCPU%user%nice  %system  %iowait%steal%idle
12:05:01 AMall  6.24  0.30  0.50  0.24  0.0992.64
12:15:01 AMall  2.79  0.00  0.12  0.09  0.0596.95
12:25:01 AMall  3.39  0.00  0.16  0.10  0.0796.27
12:35:01 AMall  2.80  0.00  0.13  0.06  0.0696.96

If this host were maxed out, that could appear as high %user, or %nice, or 
%system, or %iowait, or %steal - or any mix of those. That, in turn, would tell 
you something about why the host is busy.

If it turns out to be high %system or %iowait, take a look at the 
:8001/host-status.xqy page for the host in question. At the bottom you'll see a 
table of rates and loads, which will tell you something about where the host is 
spending its time.

-- Mike

On 29 Sep 2013, at 11:57 , indar verma 
send2i...@yahoo.co.inmailto:send2i...@yahoo.co.in wrote:

 One more thing to add,

 We are sending requests to Ml1 to Ml3 in round robin fashion from the 
 application end. so Ml4  Ml5 are not accepting any direct request from the 
 front end app.

 we are ingesting data through these two ml4 Ml5 newly added nodes.

 Thanks,
 JJ

 From: indar verma send2i...@yahoo.co.inmailto:send2i...@yahoo.co.in
 To: 

Re: [MarkLogic Dev General] One node CPU utilization maxed out but others not in a 5 node cluster once load increases

2013-10-12 Thread Khan, Kashif
I apologize. I replied to the wrong email chain.


Kashif Khan, PMI-ACP


From: Khan, Kashif Khan kashif.k...@hmhco.commailto:kashif.k...@hmhco.com
Reply-To: MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Date: Saturday, October 12, 2013 1:47 PM
To: indar verma send2i...@yahoo.co.inmailto:send2i...@yahoo.co.in, 
MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com, 
Michael Blakeley m...@blakeley.commailto:m...@blakeley.com
Cc: 
general-requ...@developer.marklogic.commailto:general-requ...@developer.marklogic.com
 
general-requ...@developer.marklogic.commailto:general-requ...@developer.marklogic.com
Subject: Re: [MarkLogic Dev General] One node CPU utilization maxed out but 
others not in a 5 node cluster once load increases

It looks good now Thanks. You can close the ticket.


Kashif Khan, PMI-ACP
Sr. Solution Architect
Publishing Technology

Houghton Mifflin Harcourt
9400 South Park Center Loop
Orlando, FL 32819
Office: 407.345.3420
Mobile: 407.949.4697
hmhco.com

From: indar verma send2i...@yahoo.co.inmailto:send2i...@yahoo.co.in
Reply-To: indar verma send2i...@yahoo.co.inmailto:send2i...@yahoo.co.in, 
MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Date: Monday, September 30, 2013 8:35 AM
To: Michael Blakeley m...@blakeley.commailto:m...@blakeley.com, MarkLogic 
Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Cc: 
general-requ...@developer.marklogic.commailto:general-requ...@developer.marklogic.com
 
general-requ...@developer.marklogic.commailto:general-requ...@developer.marklogic.com
Subject: Re: [MarkLogic Dev General] One node CPU utilization maxed out but 
others not in a 5 node cluster once load increases

Hi Michael,

Thanks a lot for your suggestions and explaining me the problem in detail.

There are 4 forests in each node,

-- 2 masters and 2 replicas

Total 20 forests (10 masters + 10 replicas)

I am attaching some screenshots of the DB

I started looking into the xqy and trying to reduce response time.

I will follow your other instructions too to see the other factors.

Actually problem is, I have to give some justifications of maximum use of CPU 
in ML4 node only even it is data node and all the data is not present in that 
node only. so I am struggling to get a concrete reason. every time, my customer 
is asking why Ml4 node only going for maximum.

Thanks  Regards,
JJ


From: Michael Blakeley m...@blakeley.commailto:m...@blakeley.com
To: indar verma send2i...@yahoo.co.inmailto:send2i...@yahoo.co.in; 
MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Cc: 
general-requ...@developer.marklogic.commailto:general-requ...@developer.marklogic.com
 
general-requ...@developer.marklogic.commailto:general-requ...@developer.marklogic.com
Sent: Monday, 30 September 2013 1:44 AM
Subject: Re: [MarkLogic Dev General] One node CPU utilization maxed out but 
others not in a 5 node cluster once load increases

Does zenoss mean Xen virtualization? PVM or HVM?

How many forests are on each host?

You could simply try upgrading from 6.0-3.2 to the latest release, 6.0-4, and 
see if that helps. But if it were me I would want to know which query or 
queries caused the problem.

Even though you aren't sending queries directly to that busy host, it's 
resolving index lookups as requested by the eval hosts. So it's still important 
to look at long-running queries, as these are the ones likely driving the load 
on your busy host. You also want to have a reproducible test case, and the best 
way to build that is to isolate a query that recreates the high load.

At the same time, dig into how utilization is measured and exactly what the 
numbers are. It's not enough to say that a host is maxed out: you need to 
understand which subsystem is the bottleneck. It's quite difficult to drive a 
16-core or 32-core host to 0% idle, especially if the workload is mixed between 
network, disk, and CPU activity. You really want to know how much of each is 
involved, to better understand what maxed out really means. For example 
'iostat -mxz 15' is a good way to monitor current activity, or if sysstat is 
collecting data then sar can display it. Just to illustrate the point, here are 
some low-utilization numbers from a system I happen to have handy.

12:00:01 AMCPU%user%nice  %system  %iowait%steal%idle
12:05:01 AMall  6.24  0.30  0.50  0.24  0.0992.64
12:15:01 AMall  2.79  0.00  0.12  0.09  0.0596.95
12:25:01 AMall  3.39  0.00  0.16  0.10  0.0796.27
12:35:01 AMall  2.80  0.00  0.13  0.06  0.0696.96

If this host were maxed out, that could appear as high %user, or %nice, or 
%system

Re: [MarkLogic Dev General] xdmp:http-get using digest authentication

2013-09-12 Thread Khan, Kashif
Vijay, It might be a firewall issue. Are you able to telnet Apache Server from 
your Marklogic server?


Kashif Khan, PMI-ACP
Sr. Solution Architect
Publishing Technology

Houghton Mifflin Harcourt
9400 South Park Center Loop
Orlando, FL 32819
Office: 407.345.3420
Mobile: 407.949.4697
hmhco.com

From: Vijayasekar Padmanaban 
vijayaseka...@infosys.commailto:vijayaseka...@infosys.com
Reply-To: MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Date: Thursday, September 12, 2013 1:04 AM
To: MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Subject: Re: [MarkLogic Dev General] xdmp:http-get using digest authentication

Hi Danny,

Thank you for your response. Yes I have tried connecting from some other 
clients like “poster” in Firefox. There I am able to connect using the same 
credentials. And I am sure that it is set up to use digest auth.

Regards,
Vijay

From: 
general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com
 [mailto:general-boun...@developer.marklogic.com] On Behalf Of Danny Sokolsky
Sent: Wednesday, September 11, 2013 11:09 PM
To: MarkLogic Developer Discussion
Subject: Re: [MarkLogic Dev General] xdmp:http-get using digest authentication

Have you tried connecting to the Apache server from another client (like curl 
for example)?  Are you sure it is set up to use digest auth?

-Danny

From:general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com
 [mailto:general-boun...@developer.marklogic.com] On Behalf Of Vijayasekar 
Padmanaban
Sent: Wednesday, September 11, 2013 2:45 AM
To: general@developer.marklogic.commailto:general@developer.marklogic.com
Subject: [MarkLogic Dev General] xdmp:http-get using digest authentication

Hi,
We are trying to connect to Apache server from MarkLogic using digest 
authentication. However, we are getting 401 unauthorized error while trying to 
connect. Below is the MarkLogic API we are using:
xdmp:http-get(http://localhost:port/a/b/c;,
options xmlns=xdmp:http
   authentication method=digest
 usernameabc/username
 passwordabc123/password
   /authentication
  /options)
And the response we are getting is below. Could you tell me what could be the 
issue here?
response
code401/code
messageUnauthorized/message
headers
  serverApache-Coyote/1.1/server
  www-authenticateDigest realm=ABCRealm, qop=auth,  
nonce=MTM3ODg4ODk3MjY5NTplMGFiYWI1YmZiNmM4YzU0OWJmMWM2ZWU5ZTYwODcxOQ==/www-authenticate
  content-typetext/html;charset=utf-8/content-type
  content-length1041/content-length
  dateWed, 11 Sep 2013 08:37:52 IST/date
  cache-controlproxy-revalidate/cache-control
  connectionclose/connection
/headers
/response
HTTP Status 401 - Nonce should have yielded two tokens but was
Regards, Vijay


 CAUTION - Disclaimer *

This e-mail contains PRIVILEGED AND CONFIDENTIAL INFORMATION intended solely

for the use of the addressee(s). If you are not the intended recipient, please

notify the sender by e-mail and delete the original message. Further, you are 
not

to copy, disclose, or distribute this e-mail or its contents to any other 
person and

any such actions are unlawful. This e-mail may contain viruses. Infosys has 
taken

every reasonable precaution to minimize this risk, but is not liable for any 
damage

you may sustain as a result of any virus in this e-mail. You should carry out 
your

own virus checks before opening the e-mail or attachment. Infosys reserves the

right to monitor and review the content of all messages sent to or from this 
e-mail

address. Messages sent to or from this e-mail address may be stored on the

Infosys e-mail system.

***INFOSYS End of Disclaimer INFOSYS***

___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] Application Testing w/ Marklogic

2013-08-21 Thread Khan, Kashif
Here is one Xquery-unit  https://developer.marklogic.com/code/xquery-unit


Kashif Khan, PMI-ACP


From: Capewell, Margarete 
margarete.capew...@ptsem.edumailto:margarete.capew...@ptsem.edu
Reply-To: MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Date: Wednesday, August 21, 2013 12:09 PM
To: general@developer.marklogic.commailto:general@developer.marklogic.com 
general@developer.marklogic.commailto:general@developer.marklogic.com
Subject: [MarkLogic Dev General] Application Testing w/ Marklogic

Hi Folks,

I'm wondering if anyone has any software recommendations for testing 
Xquery/Marklogic applications? I've been looking into Watir, Cucumber, and 
Saucelabs. Does anyone have pros/cons for each?

Many thanks!
-Maggie___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] Applying XSLT on XML file using xdmp:xslt-invoke

2013-07-19 Thread Khan, Kashif
Erik, you mentioned in your previous email about assigning a prefix to the
name space. But it does not explain why it is working for me when I do the
same operation using query console. Here is what I am doing in query
console.

let $x := xdmp:xslt-invoke(/pipelines/HTML.xsl,
doc(/ancillary/20130626114719392MXENM08AAS2X_SE_080_03.xml))
xdmp:document-insert('/ancillary/html/transformaed2.xhtml', $x,
xdmp:default-permissions(), () )







Kashif Khan, PMI-ACP






On 7/15/13 4:58 PM, Khan, Kashif kashif.k...@hmhco.com wrote:

Its interesting when I insert the transformed output into a file e.g.
transformed.html using  query console everything is looking good. I get a
properly formatted html file.

BUT When I do it using CPF the same operation take away all the html tags.
All I get is the extracted text in the transformed.html


Kashif Khan, PMI-ACP
Sr. Solution Architect
Publishing Technology
 
Houghton Mifflin Harcourt
9400 South Park Center Loop
Orlando, FL 32819 
Office: 407.345.3420
Mobile: 407.949.4697
hmhco.com






On 7/15/13 4:52 PM, Khan, Kashif kashif.k...@hmhco.com wrote:

Erik, still the same issue. Applying xdmp:quote gives me the correct
transformation by as soon as I insert it into a file all the tags are
gone.

Here is my XSLT

?xml version=1.0 encoding=UTF-8?
xsl:stylesheet xmlns:xsl=http://www.w3.org/1999/XSL/Transform;
xmlns:xs=http://www.w3.org/2001/XMLSchema;
xmlns:xd=http://www.oxygenxml.com/ns/doc/xsl;
xmlns:xh=http://www.w3.org/1999/xhtml;
xpath-default-namespace=http://www.imsglobal.org/xsd/imsqti_v2p1;
exclude-result-prefixes=xs xd
version=2.0
xsl:template match=assessmentItem xh:html
xmlns='http://www.w3.org/1999/xhtml'
  xh:head/
  xh:titleHTML Transformation/xh:title
  xh:body
  xsl:apply-templates select=itemBody/
  xsl:apply-templates 
 select=itemBody/choiceInteraction/
  /xh:body
  /xh:html
/xsl:template

xsl:template match=itemBody
  xh:p
  xh:img src={choiceInteraction/prompt/img/@src}
alt={choiceInteraction/prompt/img/@alt}/
  xsl:copy-of select=choiceInteraction/prompt/p /
  /xh:p
/xsl:template
xsl:template match=itemBody/choiceInteraction

  xsl:for-each select=simpleChoice
  xh:input type=radio value={@identifier}
  xsl:value-of select=./xh:br/
  /xh:input
  /xsl:for-each
  xh:input type=submit name=submit /
  /xsl:template
/xsl:stylesheet

Here is the output after applying xdmp:quote on the output

html xmlns:xh=http://www.w3.org/1999/xhtml;
xmlns=http://www.w3.org/1999/xhtml;
  head
meta http-equiv=Content-Type content=text/html; charset=UTF-8 /
  /head
  titleHTML Transformation/title
  bodypimg src=images/MNMTPG2_SE_062_3T_V1_ANS.jpg alt= /p
xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
xmlns:math=http://www.w3.org/1998/Math/MathML;
xmlns=http://www.imsglobal.org/xsd/imsqti_v2p1;
span xmlns=http://www.harcourt.com/HSP;
math:math
math:munder accentunder=true
math:mn5/math:mn
math:mo stretchy=true_/math:mo
/math:munder
math:mn9/math:mn
/math:math
/span
/pp xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
xmlns:math=http://www.w3.org/1998/Math/MathML;
xmlns=http://www.imsglobal.org/xsd/imsqti_v2p1;What is the value of the
underlined digit?/p/pinput type=radio value=a /5br /input
type=radio value=b /30br /input type=radio value=c /50br
/input type=radio value=d /900br /input type=submit
name=submit //body
/html




Kashif Khan, PMI-ACP
Sr. Solution Architect
Publishing Technology
 
Houghton Mifflin Harcourt
9400 South Park Center Loop
Orlando, FL 32819
Office: 407.345.3420
Mobile: 407.949.4697
hmhco.com






On 7/12/13 8:43 AM, Erik Hennum erik.hen...@marklogic.com wrote:

Hi, Kashif:

If you look carefully at the namespaces, most of the p, span, input and
other elements are not in the XHTML namespace.  So, even though the
local
name is right, the browser won't recognize them as XHTML.

Try modifying the namespace of those elements in your XSLT transform and
see if the browser renders them.


Erik Hennum


From: general-boun...@developer.marklogic.com
[general-boun...@developer.marklogic.com] on behalf of Khan, Kashif
[kashif.k...@hmhco.com]
Sent: Thursday, July 11, 2013 2:51 PM
To: MarkLogic Developer Discussion
Subject: Re: [MarkLogic Dev General] Applying XSLT on XML file using
xdmp:xslt-invoke

Mary this is what I get

?xml version=1.0 encoding=UTF-8?
html xmlns=http://www.w3.org/1999/xhtml;
  titleHTML Transformation/title
  p xmlns=
img src=images/MNMTPG2_SE_062_3T_V1_ANS.jpg alt=/
p

Re: [MarkLogic Dev General] Applying XSLT on XML file using xdmp:xslt-invoke

2013-07-15 Thread Khan, Kashif
Erik, still the same issue. Applying xdmp:quote gives me the correct
transformation by as soon as I insert it into a file all the tags are gone.

Here is my XSLT

?xml version=1.0 encoding=UTF-8?
xsl:stylesheet xmlns:xsl=http://www.w3.org/1999/XSL/Transform;
xmlns:xs=http://www.w3.org/2001/XMLSchema;
xmlns:xd=http://www.oxygenxml.com/ns/doc/xsl;
xmlns:xh=http://www.w3.org/1999/xhtml;
xpath-default-namespace=http://www.imsglobal.org/xsd/imsqti_v2p1;
exclude-result-prefixes=xs xd
version=2.0
xsl:template match=assessmentItem   xh:html
xmlns='http://www.w3.org/1999/xhtml'
xh:head/
xh:titleHTML Transformation/xh:title
xh:body
xsl:apply-templates select=itemBody/
xsl:apply-templates 
select=itemBody/choiceInteraction/
/xh:body
/xh:html
/xsl:template

xsl:template match=itemBody
xh:p
xh:img src={choiceInteraction/prompt/img/@src}
alt={choiceInteraction/prompt/img/@alt}/
xsl:copy-of select=choiceInteraction/prompt/p /
/xh:p
/xsl:template
xsl:template match=itemBody/choiceInteraction

xsl:for-each select=simpleChoice
xh:input type=radio value={@identifier}
xsl:value-of select=./xh:br/
/xh:input  
/xsl:for-each
xh:input type=submit name=submit /
/xsl:template
/xsl:stylesheet

Here is the output after applying xdmp:quote on the output

html xmlns:xh=http://www.w3.org/1999/xhtml;
xmlns=http://www.w3.org/1999/xhtml;
  head
meta http-equiv=Content-Type content=text/html; charset=UTF-8 /
  /head
  titleHTML Transformation/title
  bodypimg src=images/MNMTPG2_SE_062_3T_V1_ANS.jpg alt= /p
xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
xmlns:math=http://www.w3.org/1998/Math/MathML;
xmlns=http://www.imsglobal.org/xsd/imsqti_v2p1;
span xmlns=http://www.harcourt.com/HSP;
math:math
math:munder accentunder=true
math:mn5/math:mn
math:mo stretchy=true_/math:mo
/math:munder
math:mn9/math:mn
/math:math
/span
/pp xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
xmlns:math=http://www.w3.org/1998/Math/MathML;
xmlns=http://www.imsglobal.org/xsd/imsqti_v2p1;What is the value of the
underlined digit?/p/pinput type=radio value=a /5br /input
type=radio value=b /30br /input type=radio value=c /50br
/input type=radio value=d /900br /input type=submit
name=submit //body
/html




Kashif Khan, PMI-ACP
Sr. Solution Architect
Publishing Technology
 
Houghton Mifflin Harcourt
9400 South Park Center Loop
Orlando, FL 32819 
Office: 407.345.3420
Mobile: 407.949.4697
hmhco.com






On 7/12/13 8:43 AM, Erik Hennum erik.hen...@marklogic.com wrote:

Hi, Kashif:

If you look carefully at the namespaces, most of the p, span, input and
other elements are not in the XHTML namespace.  So, even though the local
name is right, the browser won't recognize them as XHTML.

Try modifying the namespace of those elements in your XSLT transform and
see if the browser renders them.


Erik Hennum


From: general-boun...@developer.marklogic.com
[general-boun...@developer.marklogic.com] on behalf of Khan, Kashif
[kashif.k...@hmhco.com]
Sent: Thursday, July 11, 2013 2:51 PM
To: MarkLogic Developer Discussion
Subject: Re: [MarkLogic Dev General] Applying XSLT on XML file using
xdmp:xslt-invoke

Mary this is what I get

?xml version=1.0 encoding=UTF-8?
html xmlns=http://www.w3.org/1999/xhtml;
  titleHTML Transformation/title
  p xmlns=
img src=images/MNMTPG2_SE_062_3T_V1_ANS.jpg alt=/
p xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
xmlns:math=http://www.w3.org/1998/Math/MathML;
xmlns=http://www.imsglobal.org/xsd/imsqti_v2p1;
span xmlns=http://www.harcourt.com/HSP;
math:math
math:munder accentunder=true
math:mn5/math:mn
math:mo stretchy=true_/math:mo
/math:munder
math:mn9/math:mn
/math:math
/span
/p
p xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
xmlns:math=http://www.w3.org/1998/Math/MathML;
xmlns=http://www.imsglobal.org/xsd/imsqti_v2p1;What is the value of the
underlined digit?/p
  /p
  input type=radio value=a xmlns=5br//input
  input type=radio value=b xmlns=30br//input
  input type=radio value=c xmlns=50br//input
  input type=radio value=d xmlns=900br//input
  input type=submit name=submit xmlns=/
/html




Kashif Khan, PMI-ACP
Sr. Solution Architect
Publishing Technology

Houghton Mifflin Harcourt
9400 South Park Center

Re: [MarkLogic Dev General] Applying XSLT on XML file using xdmp:xslt-invoke

2013-07-15 Thread Khan, Kashif
Its interesting when I insert the transformed output into a file e.g.
transformed.html using  query console everything is looking good. I get a
properly formatted html file.

BUT When I do it using CPF the same operation take away all the html tags.
All I get is the extracted text in the transformed.html


Kashif Khan, PMI-ACP
Sr. Solution Architect
Publishing Technology
 
Houghton Mifflin Harcourt
9400 South Park Center Loop
Orlando, FL 32819 
Office: 407.345.3420
Mobile: 407.949.4697
hmhco.com






On 7/15/13 4:52 PM, Khan, Kashif kashif.k...@hmhco.com wrote:

Erik, still the same issue. Applying xdmp:quote gives me the correct
transformation by as soon as I insert it into a file all the tags are
gone.

Here is my XSLT

?xml version=1.0 encoding=UTF-8?
xsl:stylesheet xmlns:xsl=http://www.w3.org/1999/XSL/Transform;
xmlns:xs=http://www.w3.org/2001/XMLSchema;
xmlns:xd=http://www.oxygenxml.com/ns/doc/xsl;
xmlns:xh=http://www.w3.org/1999/xhtml;
xpath-default-namespace=http://www.imsglobal.org/xsd/imsqti_v2p1;
exclude-result-prefixes=xs xd
version=2.0
xsl:template match=assessmentItem  xh:html
xmlns='http://www.w3.org/1999/xhtml'
   xh:head/
   xh:titleHTML Transformation/xh:title
   xh:body
   xsl:apply-templates select=itemBody/
   xsl:apply-templates 
 select=itemBody/choiceInteraction/
   /xh:body
   /xh:html
/xsl:template

xsl:template match=itemBody
   xh:p
   xh:img src={choiceInteraction/prompt/img/@src}
alt={choiceInteraction/prompt/img/@alt}/
   xsl:copy-of select=choiceInteraction/prompt/p /
   /xh:p
/xsl:template
xsl:template match=itemBody/choiceInteraction

   xsl:for-each select=simpleChoice
   xh:input type=radio value={@identifier}
   xsl:value-of select=./xh:br/
   /xh:input 
   /xsl:for-each
   xh:input type=submit name=submit /
   /xsl:template
/xsl:stylesheet

Here is the output after applying xdmp:quote on the output

html xmlns:xh=http://www.w3.org/1999/xhtml;
xmlns=http://www.w3.org/1999/xhtml;
  head
meta http-equiv=Content-Type content=text/html; charset=UTF-8 /
  /head
  titleHTML Transformation/title
  bodypimg src=images/MNMTPG2_SE_062_3T_V1_ANS.jpg alt= /p
xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
xmlns:math=http://www.w3.org/1998/Math/MathML;
xmlns=http://www.imsglobal.org/xsd/imsqti_v2p1;
span xmlns=http://www.harcourt.com/HSP;
math:math
math:munder accentunder=true
math:mn5/math:mn
math:mo stretchy=true_/math:mo
/math:munder
math:mn9/math:mn
/math:math
/span
/pp xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
xmlns:math=http://www.w3.org/1998/Math/MathML;
xmlns=http://www.imsglobal.org/xsd/imsqti_v2p1;What is the value of the
underlined digit?/p/pinput type=radio value=a /5br /input
type=radio value=b /30br /input type=radio value=c /50br
/input type=radio value=d /900br /input type=submit
name=submit //body
/html




Kashif Khan, PMI-ACP
Sr. Solution Architect
Publishing Technology
 
Houghton Mifflin Harcourt
9400 South Park Center Loop
Orlando, FL 32819 
Office: 407.345.3420
Mobile: 407.949.4697
hmhco.com






On 7/12/13 8:43 AM, Erik Hennum erik.hen...@marklogic.com wrote:

Hi, Kashif:

If you look carefully at the namespaces, most of the p, span, input and
other elements are not in the XHTML namespace.  So, even though the local
name is right, the browser won't recognize them as XHTML.

Try modifying the namespace of those elements in your XSLT transform and
see if the browser renders them.


Erik Hennum


From: general-boun...@developer.marklogic.com
[general-boun...@developer.marklogic.com] on behalf of Khan, Kashif
[kashif.k...@hmhco.com]
Sent: Thursday, July 11, 2013 2:51 PM
To: MarkLogic Developer Discussion
Subject: Re: [MarkLogic Dev General] Applying XSLT on XML file using
xdmp:xslt-invoke

Mary this is what I get

?xml version=1.0 encoding=UTF-8?
html xmlns=http://www.w3.org/1999/xhtml;
  titleHTML Transformation/title
  p xmlns=
img src=images/MNMTPG2_SE_062_3T_V1_ANS.jpg alt=/
p xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
xmlns:math=http://www.w3.org/1998/Math/MathML;
xmlns=http://www.imsglobal.org/xsd/imsqti_v2p1;
span xmlns=http://www.harcourt.com/HSP;
math:math
math:munder accentunder=true
math:mn5/math:mn
math:mo stretchy=true_/math:mo
/math:munder
math:mn9/math:mn
/math:math
/span

Re: [MarkLogic Dev General] Applying XSLT on XML file using xdmp:xslt-invoke

2013-07-11 Thread Khan, Kashif
Thanks Greet I have made some head way after seeing your response. I just save 
the file as transformaed.xhtml INSTEAD of transformed.html and it started 
working. Below is the code that is now working in query console

let $x := xdmp:xslt-invoke(/pipelines/HTML.xsl, 
doc(/ancillary/20130626114719392MXENM08AAS2X_SE_080_03.xml))
return xdmp:document-insert('/ancillary/html/transformaed.xhtml', $x, 
xdmp:default-permissions(), () )

Now when I am integrating this approach in CPF I am back to the same problem 
where all the html tags are getting stripped out. Below is the action file for 
my pipeline. I have tried using xsl:output and it does not seem to help. When I 
use xdmp:quote it starts throwing error.


import module namespace cpf = http://marklogic.com/cpf; at 
/MarkLogic/cpf/cpf.xqy;

import module namespace ingest = http://hmhpub.com/ingest; at 
/common/hmh-ingest.xqy;

declare variable $cpf:document-uri as xs:string external;
declare variable $cpf:transition as node() external;

if (cpf:check-transition($cpf:document-uri, $cpf:transition)) then
  try {
xdmp:log(fn:concat('try1', doc($cpf:document-uri))),
let $transform := xdmp:quote(xdmp:xslt-invoke(/pipelines/HTML.xsl, 
doc($cpf:document-uri)))
return
   xdmp:document-insert( '/ancillary/html/transformaed.xhtml', $transform, 
xdmp:default-permissions(), () ),
cpf:success($cpf:document-uri, $cpf:transition, ())
  }
  catch ($e) {
xdmp:log($e),
cpf:failure($cpf:document-uri, $cpf:transition, $e, ())
  }
else (
 xdmp:log('Nothing')
)


Kashif Khan, PMI-ACP
Sr. Solution Architect
Publishing Technology

Houghton Mifflin Harcourt
9400 South Park Center Loop
Orlando, FL 32819
Office: 407.345.3420
Mobile: 407.949.4697
hmhco.com

From: Geert Josten geert.jos...@dayon.nlmailto:geert.jos...@dayon.nl
Reply-To: MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Date: Thursday, July 11, 2013 1:00 AM
To: MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Subject: Re: [MarkLogic Dev General] Applying XSLT on XML file using 
xdmp:xslt-invoke

Hi Kashif,

My first guess would be that your stylesheet returns the output as element 
nodes rather than a serialized string, and document-insert assumes .html files 
should be stored as text files (which is the default), and therefore flattens 
the output from xml to text, effectively stripping all tags.

Depending on what you actually want to do with the stored documents, you can 
try to use xsl:output to set the output method to ‘html’. That should force the 
xslt to serialize the output, but xsl:output could be ignored altogether, not 
sure. If that doesn’t help you can use xdmp:quote to force serialization 
yourself. If you actually prefer to keep the xml structure, just pick an 
extension who’s mime-type is tied to the xml format, for instance .xhtml..

Kind regards,
Geert

Van:general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com
 
[mailto:general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com]
 Namens Khan, Kashif
Verzonden: woensdag 10 juli 2013 21:11
Aan: MarkLogic Developer Discussion
Onderwerp: [MarkLogic Dev General] Applying XSLT on XML file using 
xdmp:xslt-invoke

Hello everyone, I am having problem understanding the following issue. Any help 
will be greatly appreciated

When I use the following code in query console the XSL gets applied and I get 
the proper results

let $x := xdmp:xslt-invoke(/pipelines/HTML.xsl, 
doc(/ancillary/20130626114719392MXENM08AAS2X_SE_080_03.xml))
return $x

OUTPUT
html xmlns=http://www.w3.org/1999/xhtml;
  titleHTML Transformation/title
  p xmlns=
img src=images/MNMTPG2_SE_062_3T_V1_ANS.jpg alt=/
p xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance; 
xmlns:math=http://www.w3.org/1998/Math/MathML; 
xmlns=http://www.imsglobal.org/xsd/imsqti_v2p1;
span xmlns=http://www.harcourt.com/HSP;
math:math
math:munder accentunder=true
math:mn5/math:mn
math:mo stretchy=true_/math:mo
/math:munder
math:mn9/math:mn
/math:math
/span
/p
p xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance; 
xmlns:math=http://www.w3.org/1998/Math/MathML; 
xmlns=http://www.imsglobal.org/xsd/imsqti_v2p1;What is the value of the 
underlined digit?/p
  /p
  input type=radio value=a xmlns=5br//input
  input type=radio value=b xmlns=30br//input
  input type=radio value=c xmlns=50br//input
  input type=radio value=d xmlns=900br//input
  input type=submit name=submit xmlns=/
/html


But when I try to insert the output into a document I am NOT getting the 
expected results

let $x := xdmp:xslt-invoke(/pipelines/HTML.xsl, 
doc(/ancillary/20130626114719392MXENM08AAS2X_SE_080_03.xml))
return

Re: [MarkLogic Dev General] Applying XSLT on XML file using xdmp:xslt-invoke

2013-07-11 Thread Khan, Kashif
I apologize the action file below uses the xdmp:quote and throws error. Here is 
the correct version



import module namespace cpf = http://marklogic.com/cpf; at 
/MarkLogic/cpf/cpf.xqy;

import module namespace ingest = http://hmhpub.com/ingest; at 
/common/hmh-ingest.xqy;

declare variable $cpf:document-uri as xs:string external;
declare variable $cpf:transition as node() external;

if (cpf:check-transition($cpf:document-uri, $cpf:transition)) then
  try {
(:ingest:ingest-lesson-frame($cpf:document-uri),:)
xdmp:log(fn:concat('try1', doc($cpf:document-uri))),
let $transform := xdmp:xslt-invoke(/pipelines/HTML.xsl, 
doc($cpf:document-uri))
return
   xdmp:document-insert( '/ancillary/html/transformaed.xhtml', $transform, 
xdmp:default-permissions(), () ),
cpf:success($cpf:document-uri, $cpf:transition, ())

  }
  catch ($e) {
xdmp:log($e),
cpf:failure($cpf:document-uri, $cpf:transition, $e, ())
  }
else (
 xdmp:log('else Transformation')
)

Kashif Khan, PMI-ACP
Sr. Solution Architect
Publishing Technology

Houghton Mifflin Harcourt
9400 South Park Center Loop
Orlando, FL 32819
Office: 407.345.3420
Mobile: 407.949.4697
hmhco.com

From: Khan, Kashif Khan kashif.k...@hmhco.commailto:kashif.k...@hmhco.com
Reply-To: MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Date: Thursday, July 11, 2013 5:10 PM
To: MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Subject: Re: [MarkLogic Dev General] Applying XSLT on XML file using 
xdmp:xslt-invoke

Thanks Greet I have made some head way after seeing your response. I just save 
the file as transformaed.xhtml INSTEAD of transformed.html and it started 
working. Below is the code that is now working in query console

let $x := xdmp:xslt-invoke(/pipelines/HTML.xsl, 
doc(/ancillary/20130626114719392MXENM08AAS2X_SE_080_03.xml))
return xdmp:document-insert('/ancillary/html/transformaed.xhtml', $x, 
xdmp:default-permissions(), () )

Now when I am integrating this approach in CPF I am back to the same problem 
where all the html tags are getting stripped out. Below is the action file for 
my pipeline. I have tried using xsl:output and it does not seem to help. When I 
use xdmp:quote it starts throwing error.


import module namespace cpf = http://marklogic.com/cpf; at 
/MarkLogic/cpf/cpf.xqy;

import module namespace ingest = http://hmhpub.com/ingest; at 
/common/hmh-ingest.xqy;

declare variable $cpf:document-uri as xs:string external;
declare variable $cpf:transition as node() external;

if (cpf:check-transition($cpf:document-uri, $cpf:transition)) then
  try {
xdmp:log(fn:concat('try1', doc($cpf:document-uri))),
let $transform :=xdmp:quote(xdmp:xslt-invoke(/pipelines/HTML.xsl, 
doc($cpf:document-uri)))
return
   xdmp:document-insert( '/ancillary/html/transformaed.xhtml', $transform, 
xdmp:default-permissions(), () ),
cpf:success($cpf:document-uri, $cpf:transition, ())
  }
  catch ($e) {
xdmp:log($e),
cpf:failure($cpf:document-uri, $cpf:transition, $e, ())
  }
else (
 xdmp:log('Nothing')
)


Kashif Khan, PMI-ACP
Sr. Solution Architect
Publishing Technology

Houghton Mifflin Harcourt
9400 South Park Center Loop
Orlando, FL 32819
Office: 407.345.3420
Mobile: 407.949.4697
hmhco.com

From: Geert Josten geert.jos...@dayon.nlmailto:geert.jos...@dayon.nl
Reply-To: MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Date: Thursday, July 11, 2013 1:00 AM
To: MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Subject: Re: [MarkLogic Dev General] Applying XSLT on XML file using 
xdmp:xslt-invoke

Hi Kashif,

My first guess would be that your stylesheet returns the output as element 
nodes rather than a serialized string, and document-insert assumes .html files 
should be stored as text files (which is the default), and therefore flattens 
the output from xml to text, effectively stripping all tags.

Depending on what you actually want to do with the stored documents, you can 
try to use xsl:output to set the output method to ‘html’. That should force the 
xslt to serialize the output, but xsl:output could be ignored altogether, not 
sure. If that doesn’t help you can use xdmp:quote to force serialization 
yourself. If you actually prefer to keep the xml structure, just pick an 
extension who’s mime-type is tied to the xml format, for instance .xhtml..

Kind regards,
Geert

Van:general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com
 
[mailto:general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com]
 Namens Khan, Kashif
Verzonden: woensdag 10 juli 2013 21:11
Aan: MarkLogic Developer Discussion
Onderwerp: [MarkLogic Dev General] Applying XSLT on XML file using 
xdmp:xslt-invoke

Hello everyone, I am having problem understanding

Re: [MarkLogic Dev General] Applying XSLT on XML file using xdmp:xslt-invoke

2013-07-11 Thread Khan, Kashif
Mary this is what I get

?xml version=1.0 encoding=UTF-8?
html xmlns=http://www.w3.org/1999/xhtml;
  titleHTML Transformation/title
  p xmlns=
img src=images/MNMTPG2_SE_062_3T_V1_ANS.jpg alt=/
p xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
xmlns:math=http://www.w3.org/1998/Math/MathML;
xmlns=http://www.imsglobal.org/xsd/imsqti_v2p1;
span xmlns=http://www.harcourt.com/HSP;
math:math
math:munder accentunder=true
math:mn5/math:mn
math:mo stretchy=true_/math:mo
/math:munder
math:mn9/math:mn
/math:math
/span
/p
p xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
xmlns:math=http://www.w3.org/1998/Math/MathML;
xmlns=http://www.imsglobal.org/xsd/imsqti_v2p1;What is the value of the
underlined digit?/p
  /p
  input type=radio value=a xmlns=5br//input
  input type=radio value=b xmlns=30br//input
  input type=radio value=c xmlns=50br//input
  input type=radio value=d xmlns=900br//input
  input type=submit name=submit xmlns=/
/html




Kashif Khan, PMI-ACP
Sr. Solution Architect
Publishing Technology
 
Houghton Mifflin Harcourt
9400 South Park Center Loop
Orlando, FL 32819 
Office: 407.345.3420
Mobile: 407.949.4697
hmhco.com






On 7/11/13 5:36 PM, Mary Holstege mary.holst...@marklogic.com wrote:

On Thu, 11 Jul 2013 14:10:02 -0700, Khan, Kashif kashif.k...@hmhco.com
wrote:

 Thanks Greet I have made some head way after seeing your response. I
just save the file as transformaed.xhtml INSTEAD of transformed.html and
it started working. Below is the code that is now working in query
console

 let $x := xdmp:xslt-invoke(/pipelines/HTML.xsl,
doc(/ancillary/20130626114719392MXENM08AAS2X_SE_080_03.xml))
 return xdmp:document-insert('/ancillary/html/transformaed.xhtml', $x,
xdmp:default-permissions(), () )

 Now when I am integrating this approach in CPF I am back to the same
problem where all the html tags are getting stripped out. Below is the
action file for my pipeline. I have tried using xsl:output and it does
not seem to help. When I use xdmp:quote it starts throwing error.

The format of a document stored via xdmp:document-insert
is not determined by its URI, only by the content.
So if you give it XML, it is saved as XML; if you
give it text, it is saved as text.

What is your stylesheet producing? What output
method.

So I would back up and verify that it isn't getting
saved correctly, because I suspect the issue is
how the content is being displayed. What you
describe looks like what a browser does when it
is given XML that it doesn't recognize as HTML.
QConsole has a lot of layers of interpretation
between you and the actual results, so it can
mislead you sometimes.

What does the raw text output show you?
What does xdmp:quote(doc(/ancillary/html/transformed.html))
show you?

//Mary
___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general



___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general


[MarkLogic Dev General] Applying XSLT on XML file using xdmp:xslt-invoke

2013-07-10 Thread Khan, Kashif
Hello everyone, I am having problem understanding the following issue. Any help 
will be greatly appreciated

When I use the following code in query console the XSL gets applied and I get 
the proper results

let $x := xdmp:xslt-invoke(/pipelines/HTML.xsl, 
doc(/ancillary/20130626114719392MXENM08AAS2X_SE_080_03.xml))
return $x

OUTPUT
html xmlns=http://www.w3.org/1999/xhtml;
  titleHTML Transformation/title
  p xmlns=
img src=images/MNMTPG2_SE_062_3T_V1_ANS.jpg alt=/
p xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance; 
xmlns:math=http://www.w3.org/1998/Math/MathML; 
xmlns=http://www.imsglobal.org/xsd/imsqti_v2p1;
span xmlns=http://www.harcourt.com/HSP;
math:math
math:munder accentunder=true
math:mn5/math:mn
math:mo stretchy=true_/math:mo
/math:munder
math:mn9/math:mn
/math:math
/span
/p
p xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance; 
xmlns:math=http://www.w3.org/1998/Math/MathML; 
xmlns=http://www.imsglobal.org/xsd/imsqti_v2p1;What is the value of the 
underlined digit?/p
  /p
  input type=radio value=a xmlns=5br//input
  input type=radio value=b xmlns=30br//input
  input type=radio value=c xmlns=50br//input
  input type=radio value=d xmlns=900br//input
  input type=submit name=submit xmlns=/
/html


But when I try to insert the output into a document I am NOT getting the 
expected results

let $x := xdmp:xslt-invoke(/pipelines/HTML.xsl, 
doc(/ancillary/20130626114719392MXENM08AAS2X_SE_080_03.xml))
return xdmp:document-insert( '/ancillary/html/transformaed.html', $x, 
xdmp:default-permissions(), () )

OUTPUT:
Here is what I find  when I look at the source of transformed.html file. There 
are no tags just see extracted text below.


HTML Transformation 5 _ 9 What is the value of the underlined digit?53050900



Kashif Khan, PMI-ACP
___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general


[MarkLogic Dev General] Applying XSLT using CPF

2013-06-27 Thread Khan, Kashif
Hello everyone, I am getting following error when I upload an XML document into 
Marklogic for XSLT transformation. I have configured a CPF domain and pipeline 
and it does not seem to be working.

I have verified using xdmp:xslt-eval in DQ that the XSLT is converting the xml 
document properly. So I am guessing that I am doing something wrong with CPF 
configuration. Below are the details. Any help will be greatly appreciated. I 
hope this information is enough for debugging the problem.

Here is the error that I am getting: Warning: TaskServer: pce: on-state-enter 
/ancillary/test.xml condition failed

Here is how I am configuring the pipeline.


pipeline xmlns=http://marklogic.com/cpf/pipelines;
pipeline-nameTransform Ancillary to QTI on load/pipeline-name
pipeline-descriptionXSLT transformation applied to new and update XML 
documents/pipeline-description
success-action
module/MarkLogic/cpf/actions/success-action.xqy/module
/success-action
failure-action
module/MarkLogic/cpf/actions/failure-action.xqy/module
/failure-action
state-transition
annotation
When a document is FIRST INSERTED, apply the XSLT.
/annotation
statehttp://marklogic.com/states/initial/state
on-successhttp://marklogic.com/states/done/on-success
on-failurehttp://marklogic.com/states/error/on-failure
execute
!-- Only apply XSLT against XML documents --
condition
module /MarkLogic/cpf/actions/node-type-condition.xqy/module
options xmlns=/MarkLogic/cpf/actions/node-type-condition.xqy
formatxml/format
/options
/condition
!-- Apply this XSLT --
action
module/pipelines/QTI2.xsl/module
/action
/execute
/state-transition
state-transition
annotation
When a document is UPDATED, apply the XSLT.
/annotation
statehttp://marklogic.com/states/updated/state
on-successhttp://marklogic.com/states/done/on-success
on-failurehttp://marklogic.com/states/error/on-failure
execute
!-- Only apply XSLT against XML documents --
condition
module /MarkLogic/cpf/actions/node-type-condition.xqy/module
options xmlns=/MarkLogic/cpf/actions/node-type-condition.xqy
formatxml/format
/options
/condition
!-- Apply this XSLT --
action
module/pipelines/QTI2.xsl/module
/action
/execute
/state-transition
/pipeline



Kashif Khan, PMI-ACP
Sr. Solution Architect
Publishing Technology

Houghton Mifflin Harcourt
9400 South Park Center Loop
Orlando, FL 32819
Office: 407.345.3420
Mobile: 407.949.4697
hmhco.com___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] Applying XSLT using CPF

2013-06-27 Thread Khan, Kashif
Danny I do not see any error. Here is what I get. I had to add the try catch 
statement in the XSLT to get the error in the error ErrorLog.log file.


prop:properties xmlns:prop=http://marklogic.com/xdmp/property;
  cpf:processing-status 
xmlns:cpf=http://marklogic.com/cpf;done/cpf:processing-status
  cpf:property-hash 
xmlns:cpf=http://marklogic.com/cpf;d41d8cd98f00b204e9800998ecf8427e/cpf:property-hash
  cpf:last-updated 
xmlns:cpf=http://marklogic.com/cpf;2013-06-27T15:23:02.794876-04:00/cpf:last-updated
  cpf:state 
xmlns:cpf=http://marklogic.com/cpf;http://marklogic.com/states/done/cpf:state
  prop:last-modified2013-06-27T15:23:02-04:00/prop:last-modified
/prop:properties


Kashif Khan, PMI-ACP
Sr. Solution Architect
Publishing Technology

Houghton Mifflin Harcourt
9400 South Park Center Loop
Orlando, FL 32819
Office: 407.345.3420
Mobile: 407.949.4697
hmhco.com

From: Danny Sokolsky 
danny.sokol...@marklogic.commailto:danny.sokol...@marklogic.com
Reply-To: MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Date: Thursday, June 27, 2013 4:20 PM
To: MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Subject: Re: [MarkLogic Dev General] Applying XSLT using CPF

Did you look at the properties for the document?  It should contain any errors 
that occurred.  For example:

xdmp:document-properties(“/ancillary/test.xml”)

-Danny

From: 
general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com
 [mailto:general-boun...@developer.marklogic.com] On Behalf Of Khan, Kashif
Sent: Thursday, June 27, 2013 1:06 PM
To: MarkLogic Developer Discussion
Subject: [MarkLogic Dev General] Applying XSLT using CPF

Hello everyone, I am getting following error when I upload an XML document into 
Marklogic for XSLT transformation. I have configured a CPF domain and pipeline 
and it does not seem to be working.

I have verified using xdmp:xslt-eval in DQ that the XSLT is converting the xml 
document properly. So I am guessing that I am doing something wrong with CPF 
configuration. Below are the details. Any help will be greatly appreciated. I 
hope this information is enough for debugging the problem.

Here is the error that I am getting: Warning: TaskServer: pce: on-state-enter 
/ancillary/test.xml condition failed

Here is how I am configuring the pipeline.


pipeline xmlns=http://marklogic.com/cpf/pipelines;
pipeline-nameTransform Ancillary to QTI on load/pipeline-name
pipeline-descriptionXSLT transformation applied to new and update XML 
documents/pipeline-description
success-action
module/MarkLogic/cpf/actions/success-action.xqy/module
/success-action
failure-action
module/MarkLogic/cpf/actions/failure-action.xqy/module
/failure-action
state-transition
annotation
When a document is FIRST INSERTED, apply the XSLT.
/annotation

statehttp://marklogic.com/states/initial/statehttp://marklogic.com/states/initial%3c/state

on-successhttp://marklogic.com/states/done/on-successhttp://marklogic.com/states/done%3c/on-success

on-failurehttp://marklogic.com/states/error/on-failurehttp://marklogic.com/states/error%3c/on-failure
execute
!-- Only apply XSLT against XML documents --
condition
module/MarkLogic/cpf/actions/node-type-condition.xqy/module
options xmlns=/MarkLogic/cpf/actions/node-type-condition.xqy
formatxml/format
/options
/condition
!-- Apply this XSLT --
action
module/pipelines/QTI2.xsl/module
/action
/execute
/state-transition
state-transition
annotation
When a document is UPDATED, apply the XSLT.
/annotation

statehttp://marklogic.com/states/updated/statehttp://marklogic.com/states/updated%3c/state

on-successhttp://marklogic.com/states/done/on-successhttp://marklogic.com/states/done%3c/on-success

on-failurehttp://marklogic.com/states/error/on-failurehttp://marklogic.com/states/error%3c/on-failure
execute
!-- Only apply XSLT against XML documents --
condition
module/MarkLogic/cpf/actions/node-type-condition.xqy/module
options xmlns=/MarkLogic/cpf/actions/node-type-condition.xqy
formatxml/format
/options
/condition
!-- Apply this XSLT --
action
module/pipelines/QTI2.xsl/module
/action
/execute
/state-transition
/pipeline



Kashif Khan, PMI-ACP
Sr. Solution Architect
Publishing Technology

Houghton Mifflin Harcourt
9400 South Park Center Loop
Orlando, FL 32819
Office: 407.345.3420
Mobile: 407.949.4697
hmhco.com___
General mailing list

Re: [MarkLogic Dev General] Applying XSLT using CPF

2013-06-27 Thread Khan, Kashif
/MXENM08AAS2X_SE_080_03.xml
2013-06-27 16:26:37.126 Fine: TaskServer: pce: on-any-property skipping
/ancillary/MXENM08AAS2X_SE_080_03.xml
2013-06-27 16:26:37.127 Fine: pce 8540783117038693864 1 fragment replaced 1
2013-06-27 16:26:37.127 Fine: TaskServer: pce: on-status-enter skipping
/ancillary/MXENM08AAS2X_SE_080_03.xml





Kashif Khan, PMI-ACP
Sr. Solution Architect
Publishing Technology
 
Houghton Mifflin Harcourt
9400 South Park Center Loop
Orlando, FL 32819 
Office: 407.345.3420
Mobile: 407.949.4697
hmhco.com






On 6/27/13 4:14 PM, Mary Holstege mary.holst...@marklogic.com wrote:

On Thu, 27 Jun 2013 13:05:30 -0700, Khan, Kashif kashif.k...@hmhco.com
wrote:

 Hello everyone, I am getting following error when I upload an XML
document into Marklogic for XSLT transformation. I have configured a CPF
domain and pipeline and it does not seem to be working.

 I have verified using xdmp:xslt-eval in DQ that the XSLT is converting
the xml document properly. So I am guessing that I am doing something
wrong with CPF configuration. Below are the details. Any help will be
greatly appreciated. I hope this information is enough for debugging the
problem.

 Here is the error that I am getting: Warning: TaskServer: pce:
on-state-enter /ancillary/test.xml condition failed


This warning means that your condition module threw an error for some
reason when
If you enable logging to the fine level, you will get the full stack
trace of the error,
which might give you some clues as to what is going wrong.

//Mary
___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general



___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] Applying XSLT using CPF

2013-06-27 Thread Khan, Kashif
I am running Marklogic 4 so it was not there. I have copied this file from
Marklogic 5 to Marklogic 4 but I am still getting the same error.


Kashif Khan, PMI-ACP
Sr. Solution Architect
Publishing Technology
 
Houghton Mifflin Harcourt
9400 South Park Center Loop
Orlando, FL 32819 
Office: 407.345.3420
Mobile: 407.949.4697
hmhco.com






On 6/27/13 4:49 PM, Mary Holstege mary.holst...@marklogic.com wrote:

On Thu, 27 Jun 2013 13:30:50 -0700, Khan, Kashif kashif.k...@hmhco.com
wrote:

 Thanks Mary, I changed the logging to fine and here is what I get. It
 seems like its not able to find Module
 /MarkLogic/cpf/actions/node-type-condition.xqy. But I am not sure why.


Hmm... That is a standard file that should be there under the Modules
subdirectory.

Do you have the 'root' parameter of your domain set to something strange?
Try setting it to / if it isn't already.

//Mary

___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general



___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] Unable to get the value of Element Š.

2013-05-28 Thread Khan, Kashif
Thanks but here is the answer to my question. First off I should have posted 
this question here as this is a pure xQuery question.

This answer was provided by David Lee on t...@x-query.com. This solution work 
for me.

In pure XQuery what  you are attempting will not work ... xpath cannot have an 
accessor element which is dynamic ...
but you can do something similar.

Note: The following is hand typed by memory , might have typos.  Also this 
assumes your document is in no namespace.
Changes need to be made to accomidate namespaces.

First off you want to return a QName not an element for getHierarchyElements



declare function oxy:getHierarchyElements() as xs:QName {


let $TagName := Chapter Title


(:removing the space between Chapter and Title:)
  let $tokenizedString := fn:tokenize(($TagName), '\s')
let $concatString :=  fn:concat($tokenizedString[1], 
$tokenizedString[2])
 return
fn:QName(,$concatString() )
};


Then you need to change your xpath to use node-name



declare function oxy:getLevel($document as xs:string){
let $file := doc($document)
let $hierarchy := oxy:getHierarchyElements()
return
$file/report/body/row/*[ node-name(.) eq $hierarchy ]
};


Kashif Khan, PMI-ACP
Sr. Solution Architect
Publishing Technology

Houghton Mifflin Harcourt
9400 South Park Center Loop
Orlando, FL 32819
Office: 407.345.3420
Mobile: 407.949.4697
hmhco.com

From: Damon Feldman 
damon.feld...@marklogic.commailto:damon.feld...@marklogic.com
Reply-To: MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Date: Tuesday, May 28, 2013 2:27 PM
To: MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Subject: Re: [MarkLogic Dev General] Unable to get the value of Element Š.


Kashif,

You need to get XML into the system to use XQuery – XQuery does not work on 
strings that happen to have XML in them, but on XML documents. MarkLogic adds 
“unquote,” “document-insert” etc. because there is now method in the XQuery 
spec to add XML.

You must use implementation-specific methods to get the XML into the system in 
the first place because XQuery as a spec does not define add/insert functions.

Yours,
Damon

From: 
general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com
 [mailto:general-boun...@developer.marklogic.com] On Behalf Of Khan, Kashif
Sent: Friday, May 24, 2013 6:39 PM
To: MarkLogic Developer Discussion
Cc: MarkLogic Developer Discussion
Subject: Re: [MarkLogic Dev General] Unable to get the value of Element Š.

Yes I looked into that but the problem is that I can not use any MarkLogic 
functions.
Best Regards,
Kashif Khan

Sent from my iPhone

On May 24, 2013, at 6:36 PM, Danny Sokolsky 
danny.sokol...@marklogic.commailto:danny.sokol...@marklogic.com wrote:
Hi Kashif,

In that case, you can use xdmp:unquote, which parses a string as XML.  
Something like:

let $document :=
report
body
row
ChapterTitleFront Matter/ChapterTitle
/row
/body
/report
let $document2 := xdmp:unquote($document)
return $document2//ChapterTitle

From:general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com
 [mailto:general-boun...@developer.marklogic.com] On Behalf Of Khan, Kashif
Sent: Friday, May 24, 2013 3:31 PM
To: MarkLogic Developer Discussion
Cc: MarkLogic Developer Discussion
Subject: Re: [MarkLogic Dev General] Unable to get the value of Element Š.

Danny I am trying to resolve a problem where I have to convert text string into 
the tag name and then use that to extract the value from the XML.
Best Regards,
Kashif Khan

Sent from my iPhone

On May 24, 2013, at 5:47 PM, Danny Sokolsky 
danny.sokol...@marklogic.commailto:danny.sokol...@marklogic.com wrote:
Hi Kashif,

Why not treat your XML as XML instead of a string.  Then you can just use 
XPath.  Something like:

let $document :=
report
body
row
ChapterTitleFront Matter/ChapterTitle
/row
/body
/report
return $document//ChapterTitle
=
ChapterTitleFront Matter/ChapterTitle

-Danny

From:general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com
 [mailto:general-boun...@developer.marklogic.com] On Behalf Of Khan, Kashif
Sent: Friday, May 24, 2013 2:38 PM
To: MarkLogic Developer Discussion
Subject: [MarkLogic Dev General] Unable to get the value of Element Š.

Hello Everyone, I am having a problem extracting value from an element
Here is the XML on which I am trying to run my query


Let $document := report
body
row
ChapterTitleFront Matter/ChapterTitle
/row

/body

/report



These are the functions that I have written to extract the value of the 
ChapterTitle Tag



declare functionoxy:getHierarchyElements() {


let$TagName := Chapter Title


(:removing the space between Chapter and Title:)

let$tokenizedString := fn:tokenize

Re: [MarkLogic Dev General] Unable to get the value of Element Š.

2013-05-28 Thread Khan, Kashif
I meant to say I should not have posted this question on this forum.


Kashif Khan, PMI-ACP
Sr. Solution Architect
Publishing Technology

Houghton Mifflin Harcourt
9400 South Park Center Loop
Orlando, FL 32819
Office: 407.345.3420
Mobile: 407.949.4697
hmhco.com

From: Khan, Kashif Khan kashif.k...@hmhco.commailto:kashif.k...@hmhco.com
Reply-To: MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Date: Tuesday, May 28, 2013 2:32 PM
To: MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Subject: Re: [MarkLogic Dev General] Unable to get the value of Element Š.

Thanks but here is the answer to my question. First off I should have posted 
this question here as this is a pure xQuery question.

This answer was provided by David Lee on 
t...@x-query.commailto:t...@x-query.com. This solution work for me.

In pure XQuery what  you are attempting will not work ... xpath cannot have an 
accessor element which is dynamic ...
but you can do something similar.

Note: The following is hand typed by memory , might have typos.  Also this 
assumes your document is in no namespace.
Changes need to be made to accomidate namespaces.

First off you want to return a QName not an element for getHierarchyElements



declare function oxy:getHierarchyElements() as xs:QName {


let $TagName := Chapter Title


(:removing the space between Chapter and Title:)
  let $tokenizedString := fn:tokenize(($TagName), '\s')
let $concatString :=  fn:concat($tokenizedString[1], 
$tokenizedString[2])
 return
fn:QName(,$concatString() )
};


Then you need to change your xpath to use node-name



declare function oxy:getLevel($document as xs:string){
let $file := doc($document)
let $hierarchy := oxy:getHierarchyElements()
return
$file/report/body/row/*[ node-name(.) eq $hierarchy ]
};


Kashif Khan, PMI-ACP
Sr. Solution Architect
Publishing Technology

Houghton Mifflin Harcourt
9400 South Park Center Loop
Orlando, FL 32819
Office: 407.345.3420
Mobile: 407.949.4697
hmhco.com

From: Damon Feldman 
damon.feld...@marklogic.commailto:damon.feld...@marklogic.com
Reply-To: MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Date: Tuesday, May 28, 2013 2:27 PM
To: MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Subject: Re: [MarkLogic Dev General] Unable to get the value of Element Š.


Kashif,

You need to get XML into the system to use XQuery – XQuery does not work on 
strings that happen to have XML in them, but on XML documents. MarkLogic adds 
“unquote,” “document-insert” etc. because there is now method in the XQuery 
spec to add XML.

You must use implementation-specific methods to get the XML into the system in 
the first place because XQuery as a spec does not define add/insert functions.

Yours,
Damon

From:general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com
 [mailto:general-boun...@developer.marklogic.com] On Behalf Of Khan, Kashif
Sent: Friday, May 24, 2013 6:39 PM
To: MarkLogic Developer Discussion
Cc: MarkLogic Developer Discussion
Subject: Re: [MarkLogic Dev General] Unable to get the value of Element Š.

Yes I looked into that but the problem is that I can not use any MarkLogic 
functions.
Best Regards,
Kashif Khan

Sent from my iPhone

On May 24, 2013, at 6:36 PM, Danny Sokolsky 
danny.sokol...@marklogic.commailto:danny.sokol...@marklogic.com wrote:
Hi Kashif,

In that case, you can use xdmp:unquote, which parses a string as XML.  
Something like:

let $document :=
report
body
row
ChapterTitleFront Matter/ChapterTitle
/row
/body
/report
let $document2 := xdmp:unquote($document)
return $document2//ChapterTitle

From:general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com
 [mailto:general-boun...@developer.marklogic.com] On Behalf Of Khan, Kashif
Sent: Friday, May 24, 2013 3:31 PM
To: MarkLogic Developer Discussion
Cc: MarkLogic Developer Discussion
Subject: Re: [MarkLogic Dev General] Unable to get the value of Element Š.

Danny I am trying to resolve a problem where I have to convert text string into 
the tag name and then use that to extract the value from the XML.
Best Regards,
Kashif Khan

Sent from my iPhone

On May 24, 2013, at 5:47 PM, Danny Sokolsky 
danny.sokol...@marklogic.commailto:danny.sokol...@marklogic.com wrote:
Hi Kashif,

Why not treat your XML as XML instead of a string.  Then you can just use 
XPath.  Something like:

let $document :=
report
body
row
ChapterTitleFront Matter/ChapterTitle
/row
/body
/report
return $document//ChapterTitle
=
ChapterTitleFront Matter/ChapterTitle

-Danny

From:general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com
 [mailto:general-boun

[MarkLogic Dev General] Unable to get the value of Element Š.

2013-05-24 Thread Khan, Kashif
Hello Everyone, I am having a problem extracting value from an element
Here is the XML on which I am trying to run my query


Let $document := report
body
row
ChapterTitleFront Matter/ChapterTitle
/row

/body

/report


These are the functions that I have written to extract the value of the 
ChapterTitle Tag


declare function oxy:getHierarchyElements() {
let $TagName := Chapter Title


(:removing the space between Chapter and Title:)

let $tokenizedString := fn:tokenize(($TagName), '\s')
let $concatString :=  fn:concat($tokenizedString[1], 
$tokenizedString[2])
 return
element {$concatString} {''}

};

declare function oxy:getLevel($document as xs:string){
let $file := doc($document)
let $hierarchy := oxy:getHierarchyElements()
return
$file/report/body/row/$hierarchy
};


When I call oxy:getLevel($oxy:document) I get ChapterTitle/  instead of 
Front Matter from the XML file.


If I replace   $file/report/body/row/$hierarchy with  
$file/report/body/row/ChapterTitle I get the correct value.


Thanks for your help in advance


Kashif Khan
___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] Unable to get the value of Element Š.

2013-05-24 Thread Khan, Kashif
Danny I am trying to resolve a problem where I have to convert text string into 
the tag name and then use that to extract the value from the XML.

Best Regards,
Kashif Khan

Sent from my iPhone

On May 24, 2013, at 5:47 PM, Danny Sokolsky 
danny.sokol...@marklogic.commailto:danny.sokol...@marklogic.com wrote:

Hi Kashif,

Why not treat your XML as XML instead of a string.  Then you can just use 
XPath.  Something like:

let $document :=
report
body
row
ChapterTitleFront Matter/ChapterTitle
/row
/body
/report
return $document//ChapterTitle
=
ChapterTitleFront Matter/ChapterTitle

-Danny

From: 
general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com
 [mailto:general-boun...@developer.marklogic.com] On Behalf Of Khan, Kashif
Sent: Friday, May 24, 2013 2:38 PM
To: MarkLogic Developer Discussion
Subject: [MarkLogic Dev General] Unable to get the value of Element Š.

Hello Everyone, I am having a problem extracting value from an element
Here is the XML on which I am trying to run my query


Let $document := report
body
row
ChapterTitleFront Matter/ChapterTitle
/row

/body

/report



These are the functions that I have written to extract the value of the 
ChapterTitle Tag



declare function oxy:getHierarchyElements() {


let $TagName := Chapter Title


(:removing the space between Chapter and Title:)

let $tokenizedString := fn:tokenize(($TagName), '\s')
let $concatString :=  fn:concat($tokenizedString[1], 
$tokenizedString[2])
 return
element {$concatString} {''}

};

declare function oxy:getLevel($document as xs:string){
let $file := doc($document)
let $hierarchy := oxy:getHierarchyElements()
return
$file/report/body/row/$hierarchy
};



When I call oxy:getLevel($oxy:document) I get ChapterTitle/  instead of 
Front Matter from the XML file.



If I replace   $file/report/body/row/$hierarchy with  
$file/report/body/row/ChapterTitle I get the correct value.



Thanks for your help in advance



Kashif Khan
___
General mailing list
General@developer.marklogic.commailto:General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] Unable to get the value of Element Š.

2013-05-24 Thread Khan, Kashif
Thanks for the suggestion.

Best Regards,
Kashif Khan

Sent from my iPhone

On May 24, 2013, at 6:42 PM, David Lee 
david@marklogic.commailto:david@marklogic.com wrote:

 Yes I looked into that but the problem is that I can not use any MarkLogic 
 functions.

Maybe this is a dumb question,  but if you cant use any marklogic functions why 
are you asking the question on a marklogic mailing list ?
If you want a pure XQuery answer I suggest the xquery-talk mailing list   
t...@x-query.commailto:t...@x-query.com





From: 
general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com
 [mailto:general-boun...@developer.marklogic.com] On Behalf Of Khan, Kashif
Sent: Friday, May 24, 2013 6:39 PM
To: MarkLogic Developer Discussion
Cc: MarkLogic Developer Discussion
Subject: Re: [MarkLogic Dev General] Unable to get the value of Element Š.

Yes I looked into that but the problem is that I can not use any MarkLogic 
functions.
Best Regards,
Kashif Khan

Sent from my iPhone

On May 24, 2013, at 6:36 PM, Danny Sokolsky 
danny.sokol...@marklogic.commailto:danny.sokol...@marklogic.com wrote:
Hi Kashif,

In that case, you can use xdmp:unquote, which parses a string as XML.  
Something like:

let $document :=
report
body
row
ChapterTitleFront Matter/ChapterTitle
/row
/body
/report
let $document2 := xdmp:unquote($document)
return $document2//ChapterTitle

From: 
general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com
 [mailto:general-boun...@developer.marklogic.com] On Behalf Of Khan, Kashif
Sent: Friday, May 24, 2013 3:31 PM
To: MarkLogic Developer Discussion
Cc: MarkLogic Developer Discussion
Subject: Re: [MarkLogic Dev General] Unable to get the value of Element Š.

Danny I am trying to resolve a problem where I have to convert text string into 
the tag name and then use that to extract the value from the XML.
Best Regards,
Kashif Khan

Sent from my iPhone

On May 24, 2013, at 5:47 PM, Danny Sokolsky 
danny.sokol...@marklogic.commailto:danny.sokol...@marklogic.com wrote:
Hi Kashif,

Why not treat your XML as XML instead of a string.  Then you can just use 
XPath.  Something like:

let $document :=
report
body
row
ChapterTitleFront Matter/ChapterTitle
/row
/body
/report
return $document//ChapterTitle
=
ChapterTitleFront Matter/ChapterTitle

-Danny

From: 
general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com
 [mailto:general-boun...@developer.marklogic.com] On Behalf Of Khan, Kashif
Sent: Friday, May 24, 2013 2:38 PM
To: MarkLogic Developer Discussion
Subject: [MarkLogic Dev General] Unable to get the value of Element Š.

Hello Everyone, I am having a problem extracting value from an element
Here is the XML on which I am trying to run my query


Let $document := report
body
row
ChapterTitleFront Matter/ChapterTitle
/row

/body

/report



These are the functions that I have written to extract the value of the 
ChapterTitle Tag



declare function oxy:getHierarchyElements() {


let $TagName := Chapter Title


(:removing the space between Chapter and Title:)

let $tokenizedString := fn:tokenize(($TagName), '\s')
let $concatString :=  fn:concat($tokenizedString[1], 
$tokenizedString[2])
 return
element {$concatString} {''}

};

declare function oxy:getLevel($document as xs:string){
let $file := doc($document)
let $hierarchy := oxy:getHierarchyElements()
return
$file/report/body/row/$hierarchy
};



When I call oxy:getLevel($oxy:document) I get ChapterTitle/  instead of 
Front Matter from the XML file.



If I replace   $file/report/body/row/$hierarchy with  
$file/report/body/row/ChapterTitle I get the correct value.



Thanks for your help in advance



Kashif Khan
___
General mailing list
General@developer.marklogic.commailto:General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general
___
General mailing list
General@developer.marklogic.commailto:General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general
___
General mailing list
General@developer.marklogic.commailto:General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general


[MarkLogic Dev General] CLass Diagram for xQuery files

2013-05-22 Thread Khan, Kashif
Hello Everyone, Has anyone used a tool to create class diagrams for the xQuery 
files begin create in a project? Any info will be greatly appreciated.


Kashif Khan, PMI-ACP
___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general


[MarkLogic Dev General] Accessing WebDav as Non Admin User

2013-04-02 Thread Khan, Kashif
Hello Everyone, I ran the following Query and changed the permission on
the documents in side the app directory. I can see that the changes have
been made but I can not access the directory app with WebDav using the
user that is part of the AHD-Access-Role. Any help will be appreciated.

for $x in xdmp:directory(/app/, 1)
return
xdmp:document-add-permissions(
fn:document-uri($x),
(xdmp:permission(AHD-Access-Role,read)))



Note: I followed the instructions suggested in the following discussion
thread: 
http://www.mail-archive.com/general@developer.marklogic.com/msg07029.html


Kashif Khan, PMI-ACP





On 4/1/13 5:17 PM, Michael Blakeley m...@blakeley.com wrote:

Take a look at the function signature at
http://docs.marklogic.com/xdmp:document-set-permissions

xdmp:document-set-permissions(
  $uri as xs:string,
  $permissions as element(sec:permission)*
) as empty-sequence()

You're supplying an arg2 as xs:string+, when it has to be
element(sec:permission)*. Use http://docs.marklogic.com/xdmp:permission
to construct a permission element, as in the docs example:

xdmp:document-set-permissions(
/example.xml,
(xdmp:permission(development, update),
 xdmp:permission(qa, read)))

-- Mike

On 1 Apr 2013, at 13:58 , Khan, Kashif kashif.k...@hmhco.com wrote:

 I am running the following query to give Access-Role read permission
but
 I get the error  [1.0-ml] XDMP-NOTANODE: (err:XPTY0019)
 xdmp:document-set-permissions(fn:document-uri($x),
(Access-Role,read))
 -- AHD-Access-Role is not a node
 
 for $x in xdmp:directory(/app/, 1)
 return
 xdmp:document-set-permissions(fn:document-uri($x),
(Access-Role,read))
 
 
 Any help in understanding this issue will be greatly appreciated.
 
 
 Kashif Khan
 
 
 ___
 General mailing list
 General@developer.marklogic.com
 http://developer.marklogic.com/mailman/listinfo/general
 

___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general


___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] Accessing WebDav as Non Admin User

2013-04-02 Thread Khan, Kashif
Thanks Worked like a charm. Thanks Danny.

One more thing that I wanted to ask was how can I apply permissions to all
the directories and files inside a parent directory in one go. Right now I
am applying permissions to all the files using script 1 and then applying
the permission on directory one by one by using script 2. I appreciate
your help



Script 1
==
for $x in xdmp:directory(/app/, infinity) (: with infinity option it
takes too much time to execute this script :)
return
xdmp:document-add-permissions(
fn:document-uri($x),
(xdmp:permission(AHD-Access-Role,read)))




Script 2
==
xdmp:document-add-permissions(
/app/,
(xdmp:permission(AHD-Access-Role,read)))




Kashif Khan, PMI-ACP







On 4/2/13 4:48 PM, Danny Sokolsky danny.sokol...@marklogic.com wrote:

You may also need to add that permission to the directory.  Something
like:

xdmp:document-add-permissions(
/app/,
(xdmp:permission(AHD-Access-Role,read)))

-Original Message-
From: general-boun...@developer.marklogic.com
[mailto:general-boun...@developer.marklogic.com] On Behalf Of Khan, Kashif
Sent: Tuesday, April 02, 2013 1:07 PM
To: MarkLogic Developer Discussion
Subject: [MarkLogic Dev General] Accessing WebDav as Non Admin User

Hello Everyone, I ran the following Query and changed the permission on
the documents in side the app directory. I can see that the changes have
been made but I can not access the directory app with WebDav using the
user that is part of the AHD-Access-Role. Any help will be appreciated.

for $x in xdmp:directory(/app/, 1)
return
xdmp:document-add-permissions(
fn:document-uri($x),
(xdmp:permission(AHD-Access-Role,read)))



Note: I followed the instructions suggested in the following discussion
thread: 
http://www.mail-archive.com/general@developer.marklogic.com/msg07029.html


Kashif Khan, PMI-ACP





On 4/1/13 5:17 PM, Michael Blakeley m...@blakeley.com wrote:

Take a look at the function signature at
http://docs.marklogic.com/xdmp:document-set-permissions

xdmp:document-set-permissions(
  $uri as xs:string,
  $permissions as element(sec:permission)*
) as empty-sequence()

You're supplying an arg2 as xs:string+, when it has to be
element(sec:permission)*. Use http://docs.marklogic.com/xdmp:permission
to construct a permission element, as in the docs example:

xdmp:document-set-permissions(
/example.xml,
(xdmp:permission(development, update),
 xdmp:permission(qa, read)))

-- Mike

On 1 Apr 2013, at 13:58 , Khan, Kashif kashif.k...@hmhco.com wrote:

 I am running the following query to give Access-Role read
permission but  I get the error  [1.0-ml] XDMP-NOTANODE:
(err:XPTY0019)  xdmp:document-set-permissions(fn:document-uri($x),
(Access-Role,read))
 -- AHD-Access-Role is not a node
 
 for $x in xdmp:directory(/app/, 1)  return
xdmp:document-set-permissions(fn:document-uri($x),
(Access-Role,read))
 
 
 Any help in understanding this issue will be greatly appreciated.
 
 
 Kashif Khan
 
 
 ___
 General mailing list
 General@developer.marklogic.com
 http://developer.marklogic.com/mailman/listinfo/general
 

___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general


___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general
___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general

___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general


[MarkLogic Dev General] Setting Permission Issue

2013-04-01 Thread Khan, Kashif
I am running the following query to give Access-Role read permission but
I get the error  [1.0-ml] XDMP-NOTANODE: (err:XPTY0019)
xdmp:document-set-permissions(fn:document-uri($x), (Access-Role,read))
-- AHD-Access-Role is not a node

for $x in xdmp:directory(/app/, 1)
return
xdmp:document-set-permissions(fn:document-uri($x), (Access-Role,read))


Any help in understanding this issue will be greatly appreciated.


Kashif Khan


___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] Asyncronous Status Updates

2013-02-23 Thread Khan, Kashif
Have you looked into versioning functionality in Marklogic.

Best Regards,
Kashif Khan

Sent from my iPhone

On Feb 23, 2013, at 3:15 PM, Tim t...@aaom.netmailto:t...@aaom.net wrote:

Hi Folks,

I have a question about best practices for maintaining the state of a document. 
 In a SQL world, I track document statuses using a control table.  I find it 
useful to likewise track status separately from documents via a status record 
in MarkLogic so that for example, I don’t need to update a document when 
performing quality control.  In addition, I can maintain a set of records to 
track the history of a document and refer to saved instances of the document at 
each touch point in a workflow where I really do want to retain a copy of the 
document whenever a change has taken place as referenced by the current state 
and document URI as well as other important information such as ownership, 
date/time stamp, etc.

However, there are some asynchronous back-end processing actions that can be 
taken on the document which can be spawned concurrently with updates made to 
the status table when each completes.  I want to make sure that I understand 
the concurrency issues related to updates top the status record.  I think I can 
assume that there really won’t be any need for a locking mechanism, that is 
that each response will update the status table atomically.   I plan to have 
separate statuses for each of the asynchronous events as the completion of all 
such statues will indicate that the record is ready for the next stage.

Thanks for any suggestions and insight into this!

Tim

___
General mailing list
General@developer.marklogic.commailto:General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] Marklogic Cluster Setup (Khan, Kashif)

2013-02-12 Thread Khan, Kashif
).
Performance aside, I would not use a NAS as part of a failover solution. The 
whole point of failover is high availability, and relying on a NAS simply 
introduces another system that can fail. Using a NAS also implies shared 
filesystems, which are cantankerous and require their own fencing mechanisms. 
This pulls in yet more systems that can fail, and probably will.
I prefer to use local storage, with local replication of forests. This also 
avoids the strong probability that the I/O demands of the cluster will swamp 
the network link to the NAS, or the NAS controller.
So I would size the number of forests needed, then the storage capacity and I/O 
performance needed, and finally specify local disk and network to meet those 
needs.
-- Mike


On 8 Feb 2013, at 14:26 , Khan, Kashif 
kashif.k...@hmhco.commailto:kashif.k...@hmhco.com wrote:
Hello Everyone, We are creating a Marklogic Cluster for failover. I have a 
couple of questions.
? We are planning to use NAS for data storage. Is there any performance hit 
if we use NAS over SAN?
? We do not have GFS setup.
? It is possible to attach One NAS file store to all 3 MarkLogic 
Servers in the cluster?
? OR do we have to attach an Independent NAS with each Marklogic 
Instance and set up a cloning job to transfer data to each of the other 2 NAS 
instances.
From the documentation it seems like we can not attach one NAS file store to 
all three MArkLogic servers unless we have GFS. Any info will be greatly 
appreciated.

Kashif Khan
___
General mailing list
General@developer.marklogic.commailto:General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] Fwd: Fwd: Abstract of Marklogic project and related difficulties

2013-02-05 Thread Khan, Kashif
Here are some that I can think of HTML, Flash/FLEX, .NET


Kashif Khan

From: SanaIffat Khan sanacse2...@gmail.commailto:sanacse2...@gmail.com
Reply-To: MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Date: Tuesday, February 5, 2013 3:13 AM
To: MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Subject: [MarkLogic Dev General] Fwd: Fwd: Abstract of Marklogic project and 
related difficulties




Sir,
As mentioned in our ABSTRACT , our project basically deals with the 3D model of 
a mall in X3D for which we are using MARKLOGIC as our backend.
We are facing the following difficulties:
1. Which language is suitable for front end webpages so that the backend still 
remains MARKLOGIC?
2. If we use JSP  servlets for front end, for implementing the shopping logic, 
how to use MARKLOGIC as dynamic database for updating the information entered 
by user?
Thanking You !


___
General mailing list
General@developer.marklogic.commailto:General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general

___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] XDMP:FORESTERR SVC-MAPINI can't merge forest

2012-10-16 Thread Khan, Kashif
We got similar error and apparently the permission on the storage space mounted 
on the Marklogic server had  changed to Read only. We had to reboot the 
physical server to resolve this issue.

Best Regards,
Kashif Khan
Sr. Solutions Architect
Houghton Mifflin Harcourt, Orlando, FL
Office: (407) 345-3420
Cell: (407) 949-4697

The water you touch in the river is the last of that which has passed and the 
first of that which is coming --Leonardo da Vinci

From: Nelson Wells 
nelson.we...@icainformatics.commailto:nelson.we...@icainformatics.com
Reply-To: MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Date: Tuesday, October 16, 2012 2:47 PM
To: general@developer.marklogic.commailto:general@developer.marklogic.com 
general@developer.marklogic.commailto:general@developer.marklogic.com
Subject: [MarkLogic Dev General] XDMP:FORESTERR SVC-MAPINI can't merge forest

Hi all,

I'm having an issue with a MarkLogic instance that hosts several app servers 
and databases.   I've had trouble tracking the issue down since I can't 
reproduce the problem, but I do have a suspicion as to why it is happening.  
Before I go any further, here is the text of the message pulled from the ML 
error log.

XDMP-FORESTNOT: xdmp:eval(xquery version quot;1.0-mlquot;;#10;  
   ..., (fn:QName(, collections), endpoints, fn:QName(, 
content), ...), options 
xmlns=xdmp:evaldatabase14426517848108531411/database/options) -- 
Forest logs-1 not available: XDMP-FORESTERR: Error in merge of forest logs-1: 
SVC-MAPINI: Mapped file initialization error: CreateFile 'C:\Program 
Files\MarkLogic\Data\Forests\logs-1\3e57\Timestamps': The process cannot 
access the file because it is being used by another process.

Currently, there are 10 app servers running different instances of the same 
app.  There is also a logs database that is not bound to any app server.  
However, each application writes to that same logs database via an eval 
statement.  Well, when any request is made to any of the 10 app servers, a log 
is written to the logs database.  I suspect that it is possible that, because 
10 different app servers are writing to the same database constantly, it is 
possible that the MarkLogic process itself doesn't let go of the files 
necessary to perform the merge long enough to actually do the merge, but this 
is just speculation.

Is this a plausible explanation?  If not, has anyone had any experience with 
this particular error message and a possible fix?  The only resource I've found 
that references SVC-MAPINI doesn't seem to be the same issue: 
http://stackoverflow.com/questions/11843916/the-realm-in-the-security-database-got-changed-accidently-in-marklogic-now-cann
Also, for all of the databases, including the logs database, transaction 
locking and journaling are set to “fast.”  Could these settings, or any others, 
be responsible or at least alleviate the problem?

Thanks all,

Nelson Wells
Application Developer
nelson.we...@icainformatics.commailto:nelson.we...@icainformatics.com

[cid:image001.jpg@01CDABA4.C77BAD90]

1801 West End, Suite 1000
Nashville, TN 37203
www.icainformatics.comhttp://www.icainformatics.com/

[cid:image002.jpg@01CDABA4.C77BAD90]http://twitter.com/icainformatics



NOTICE OF CONFIDENTIALITY: This electronic message, including attachments, is 
for the sole use of the named recipient and may contain confidential or 
privileged information protected by State of Tennessee and Federal regulations. 
Any unauthorized review, use, disclosure, copying or distribution is strictly 
prohibited. If you are not the intended recipient or have received this 
communication in error please contact the sender or email 
i...@icainformatics.commailto:i...@icainformatics.com and destroy all copies 
of the original message. Thank you.attachment: image001.jpgattachment: image002.jpg___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general


[MarkLogic Dev General] Marklogic applications slowness Issue

2012-05-18 Thread Khan, Kashif
Hello everyone, I am having an issue where when I restore the Production Backup 
into the QA environment it makes the QA environments very slow. Now my QA 
environment is not even responding.

The only difference between the Prod and QA is that RAM in Prod environment Is 
64G where as the RAM in QA is 8G. The version of Marklogic is 5.0-3 on both 
Prod and QA. Are there and config changes that I need to do after the restore 
of production database into QA?

Any help will be appreciated.

Best Regards,
Kashif Khan


___
General mailing list
General@developer.marklogic.com
http://community.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] Marklogic applications slowness Issue

2012-05-18 Thread Khan, Kashif
Thanks. Two things I forgot to mention are

1- Now I can not access the admin console and
2- The QA environment worked just fine for at least 2 weeks.

Best Regards,
Kashif Khan
Sr. Solutions Architect
Houghton Mifflin Harcourt, Orlando, FL
Office: (407) 345-3420
Cell: (407) 949-4697

The water you touch in the river is the last of that which has passed and the 
first of that which is coming --Leonardo da Vinci

From: Damon Feldman 
damon.feld...@marklogic.commailto:damon.feld...@marklogic.com
Reply-To: MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
To: MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Subject: Re: [MarkLogic Dev General] Marklogic applications slowness Issue

Kashif,

If RAM is the primary difference there’s a good chance your system is swapping. 
Both Windows and Linux have tools to monitor swap activity. Within MarkLogic 
(in Production, which you say is still responsive), look at the database status 
page, click “show forests” and total up the “in memory size” column near the 
bottom. If it is high relative to your machine’s RAM, and/or the OS and other 
applications on the machine take up a lot of RAM, then you’ll drive the system 
into swap.

Yours,
Damon

From: 
general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com
 [mailto:general-boun...@developer.marklogic.com] On Behalf Of Khan, Kashif
Sent: Friday, May 18, 2012 9:24 AM
To: MarkLogic Developer Discussion
Subject: [MarkLogic Dev General] Marklogic applications slowness Issue

Hello everyone, I am having an issue where when I restore the Production Backup 
into the QA environment it makes the QA environments very slow. Now my QA 
environment is not even responding.

The only difference between the Prod and QA is that RAM in Prod environment Is 
64G where as the RAM in QA is 8G. The version of Marklogic is 5.0-3 on both 
Prod and QA. Are there and config changes that I need to do after the restore 
of production database into QA?

Any help will be appreciated.

Best Regards,
Kashif Khan


___
General mailing list
General@developer.marklogic.com
http://community.marklogic.com/mailman/listinfo/general


[MarkLogic Dev General] Internal Server Error

2012-03-26 Thread Khan, Kashif
We just upgraded to Marklogic server 5.0-3 and now I am getting this error for 
my application. Did anyone face this issue with their application?
500 Internal Server Error

XDMP-UNEXPECTED: (err:XPST0003) Unexpected token syntax error, unexpected 
QName_, expecting EmptyTagClose_ or StartTagClose_
in /application/views/footer.xqy, at 16:31,
in xdmp:invoke(/application/views/footer.xqy, (fn:QName(, data), 
map:map()), options 
xmlns=xdmp:evalisolationdifferent-transaction/isolationprevent-deadlockst.../options)
 [1.0-ml]
in /system/xqmvc.xqy, at 105:4,
in _view(/application/views/footer.xqy, ()) [1.0-ml]
$view-file = /application/views/footer.xqy
$pairs = ()
in /system/xqmvc.xqy, at 119:8,
in xqmvc:view(footer, ()) [1.0-ml]
$view = footer
$pairs = ()
$view-file = /application/views/footer.xqy
in /application/controllers/word.xqy, at 216:12,
in word-controller:error() [1.0-ml]
in /system/error.xqy, at 9:7 [1.0-ml]
$set-var = ()
Old Error

lt;error:error
xsi:schemaLocation=http://marklogic.com/xdmp/error error.xsd
xmlns:error=http://marklogic.com/xdmp/error;
xmlns:xsi=http://www.w3.org/2001/XMLSchema-instancegt;
  lt;error:codegt;XDMP-UNEXPECTEDlt;/error:codegt;
  lt;error:namegt;err:XPST0003lt;/error:namegt;
  lt;error:xquery-versiongt;1.0-mllt;/error:xquery-versiongt;
  lt;error:messagegt;Unexpected tokenlt;/error:messagegt;
  lt;error:format-stringgt;XDMP-UNEXPECTED: (err:XPST0003) Unexpected
token syntax error, unexpected QName_, expecting EmptyTagClose_ or
StartTagClose_lt;/error:format-stringgt;
  lt;error:retryablegt;falselt;/error:retryablegt;
  lt;error:exprgt; lt;/error:exprgt;
  lt;error:datagt;
lt;error:datumgt;syntax error, unexpected QName_, expecting
EmptyTagClose_ or StartTagClose_lt;/error:datumgt;
lt;error:datum/gt;
  lt;/error:datagt;
  lt;error:stackgt;
lt;error:framegt;
  lt;error:urigt;/application/views/footer.xqylt;/error:urigt;
  lt;error:linegt;16lt;/error:linegt;
  lt;error:columngt;31lt;/error:columngt;

lt;error:operationgt;xdmp:invoke(/application/views/footer.xqy,
(fn:QName(, data), map:map()), amp;lt;options
xmlns=xdmp:evalamp;gt;amp;lt;isolationamp;gt;different-transactionamp;lt;/isolationamp;gt;amp;lt;prevent-deadlocksamp;gt;t...amp;lt;/optionsamp;gt;)lt;/error:operationgt;

  lt;error:xquery-versiongt;1.0-mllt;/error:xquery-versiongt;
lt;/error:framegt;
lt;error:framegt;
  lt;error:urigt;/system/xqmvc.xqylt;/error:urigt;
  lt;error:linegt;105lt;/error:linegt;
  lt;error:columngt;4lt;/error:columngt;
  lt;error:operationgt;_view(/application/views/footer.xqy,
())lt;/error:operationgt;
  lt;error:variablesgt;
lt;error:variablegt;
  lt;error:name
xmlns=http://scholarsportal.info/xqmvc/coregt;view-filelt;/error:namegt;


lt;error:valuegt;/application/views/footer.xqylt;/error:valuegt;
lt;/error:variablegt;
lt;error:variablegt;
  lt;error:name
xmlns=http://scholarsportal.info/xqmvc/coregt;pairslt;/error:namegt;

  lt;error:valuegt;()lt;/error:valuegt;
lt;/error:variablegt;
  lt;/error:variablesgt;
  lt;error:xquery-versiongt;1.0-mllt;/error:xquery-versiongt;
lt;/error:framegt;
lt;error:framegt;
  lt;error:urigt;/system/xqmvc.xqylt;/error:urigt;
  lt;error:linegt;119lt;/error:linegt;
  lt;error:columngt;8lt;/error:columngt;
  lt;error:operationgt;xqmvc:view(footer,
())lt;/error:operationgt;
  lt;error:variablesgt;
lt;error:variablegt;
  lt;error:name
xmlns=http://scholarsportal.info/xqmvc/coregt;viewlt;/error:namegt;
  lt;error:valuegt;footerlt;/error:valuegt;
lt;/error:variablegt;
lt;error:variablegt;
  lt;error:name
xmlns=http://scholarsportal.info/xqmvc/coregt;pairslt;/error:namegt;

  lt;error:valuegt;()lt;/error:valuegt;
lt;/error:variablegt;
lt;error:variablegt;
  lt;error:name
xmlns=http://scholarsportal.info/xqmvc/coregt;view-filelt;/error:namegt;


lt;error:valuegt;/application/views/footer.xqylt;/error:valuegt;
lt;/error:variablegt;
  lt;/error:variablesgt;
  lt;error:xquery-versiongt;1.0-mllt;/error:xquery-versiongt;
lt;/error:framegt;
lt;error:framegt;

lt;error:urigt;/application/controllers/word.xqylt;/error:urigt;
  lt;error:linegt;121lt;/error:linegt;
  lt;error:columngt;18lt;/error:columngt;
  lt;error:operationgt;search()lt;/error:operationgt;
  lt;error:variablesgt;
lt;error:variablegt;
  lt;error:name
xmlns=http://scholarsportal.info/xqmvc/controllergt;id-querylt;/error:namegt;

  lt;error:valuegt;()lt;/error:valuegt;
lt;/error:variablegt;
lt;error:variablegt;
  lt;error:name
xmlns=http://scholarsportal.info/xqmvc/controllergt;word-querylt;/error:namegt;

  lt;error:valuegt;()lt;/error:valuegt;
lt;/error:variablegt;
lt;error:variablegt;
  lt;error:name

Re: [MarkLogic Dev General] Internal Server Error

2012-03-26 Thread Khan, Kashif
Here is what is in the footer.xqy file

xquery version 1.0-ml;
import module namespace xqmvc = http://scholarsportal.info/xqmvc/core; at
../../system/xqmvc.xqy;
declare variable $data as map:map external;


div class=container
div id=primary_nav
ul
lia href=http://www.houghtonmifflinbooks.com; 
Home/a/li
lia href=http://www.houghtonmifflinbooks.com/faq/;|
FAQs/a/li
lia 
href=http://www.houghtonmifflinbooks.com/site_map/;|
Sitemap/a/li
/ul
/div

img class=harcourt-logosrc={ $xqmvc:resource-dir
}/images/harcourt-logo.png alt=harcourt-logo width=101 height=39 /

div id=legal_nav
ul
lia href=http://www.hmhco.com/privacy-policy.html;Privacy
Policy  /a/li
lia href=http://www.houghtonmifflinbooks.com/trademark/;|
Trademark Information/a/li
lia href=http://www.hmhco.com/terms-and-conditions.html;| 
Terms
amp; Conditions of Use/a/li
/ul
br/
pfont color=blackFor licensing inquiries, please contact
Damian Dale, /fonta href=mailto:damian.d...@hmhpub.com;font
color=blackdamian.d...@hmhpub.com/font/a/p
pCopyright {(:copy; :)} 2011 Houghton Mifflin Harcourt 
Publishing
Company. All rights reserved./p

/div
   
   /div




Best Regards,
Kashif Khan




On 3/26/12 12:40 PM, John Snelson john.snel...@marklogic.com wrote:

What does the code in footer.xqy look like?

One bug fix that was made in 5.0-1 was to require quotes around
attribute values in direct element constructor expressions - maybe you
have unquoted attribute values in your program?

John

On 26/03/12 17:22, Khan, Kashif wrote:

   We just upgraded to Marklogic server 5.0-3 and now I am getting this
   error for my application. Did anyone face this issue with their
   application?


   500 Internal Server Error

 XDMP-UNEXPECTED: (err:XPST0003) Unexpected token syntax error,
 unexpected QName_, expecting EmptyTagClose_ or StartTagClose_
 in /application/views/footer.xqy, at 16:31,
 in xdmp:invoke(/application/views/footer.xqy, (fn:QName(, data),
 map:map()), options
 
xmlns=xdmp:evalisolationdifferent-transaction/isolationprevent-de
adlockst.../options)
 [1.0-ml]
 in /system/xqmvc.xqy, at 105:4,
 in _view(/application/views/footer.xqy, ()) [1.0-ml]
 $view-file = /application/views/footer.xqy
 $pairs = ()
 in /system/xqmvc.xqy, at 119:8,
 in xqmvc:view(footer, ()) [1.0-ml]
 $view = footer
 $pairs = ()
 $view-file = /application/views/footer.xqy
 in /application/controllers/word.xqy, at 216:12,
 in word-controller:error() [1.0-ml]
 in /system/error.xqy, at 9:7 [1.0-ml]
 $set-var = ()
 Old Error
 lt;error:error xsi:schemaLocation=http://marklogic.com/xdmp/error
 error.xsd xmlns:error=http://marklogic.com/xdmp/error;
 xmlns:xsi=http://www.w3.org/2001/XMLSchema-instancegt;
 lt;error:codegt;XDMP-UNEXPECTEDlt;/error:codegt;
 lt;error:namegt;err:XPST0003lt;/error:namegt;
 lt;error:xquery-versiongt;1.0-mllt;/error:xquery-versiongt;
 lt;error:messagegt;Unexpected tokenlt;/error:messagegt;
 lt;error:format-stringgt;XDMP-UNEXPECTED: (err:XPST0003)
 Unexpected token syntax error, unexpected QName_, expecting
 EmptyTagClose_ or StartTagClose_lt;/error:format-stringgt;
 lt;error:retryablegt;falselt;/error:retryablegt;
 lt;error:exprgt; lt;/error:exprgt; lt;error:datagt;
 lt;error:datumgt;syntax error, unexpected QName_, expecting
 EmptyTagClose_ or StartTagClose_lt;/error:datumgt;
 lt;error:datum/gt; lt;/error:datagt; lt;error:stackgt;
 lt;error:framegt;
 lt;error:urigt;/application/views/footer.xqylt;/error:urigt;
 lt;error:linegt;16lt;/error:linegt;
 lt;error:columngt;31lt;/error:columngt;
 lt;error:operationgt;xdmp:invoke(/application/views/footer.xqy,
 (fn:QName(, data), map:map()), amp;lt;options
 
xmlns=xdmp:evalamp;gt;amp;lt;isolationamp;gt;different-transactiona
mp;lt;/isolationamp;gt;amp;lt;prevent-deadlocksamp;gt;t...amp;lt;/opt
ionsamp;gt;)lt;/error:operationgt;
 lt;error:xquery-versiongt;1.0-mllt;/error:xquery-versiongt;
 lt;/error:framegt; lt;error:framegt;
 lt;error:urigt;/system/xqmvc.xqylt;/error:urigt;
 lt;error:linegt;105lt;/error:linegt;
 lt;error:columngt;4lt;/error:columngt;
 lt;error:operationgt;_view(/application/views/footer.xqy,
 ())lt;/error:operationgt; lt;error:variablesgt;
 lt;error:variablegt; lt;error:name
 
xmlns=http://scholarsportal.info/xqmvc/coregt;view-filelt;/error:name
gt;
 
lt;error:valuegt;/application/views/footer.xqylt;/error:valuegt;
 lt;/error:variablegt; lt;error:variablegt; lt;error:name
 
xmlns=http://scholarsportal.info/xqmvc/coregt;pairslt;/error:namegt;
 lt;error:valuegt;()lt;/error:valuegt; lt;/error:variablegt;
 lt;/error:variablesgt;
 lt;error:xquery-versiongt

Re: [MarkLogic Dev General] Internal Server Error

2012-03-26 Thread Khan, Kashif
I will try this but one more thing that I noticed is that CQ has also
stopped working.


Best Regards,
Kashif Khan




On 3/26/12 1:11 PM, Michael Blakeley m...@blakeley.com wrote:

Try adding some whitespace before the src attribute, as required by
http://www.w3.org/TR/xquery/#prod-xquery-DirAttributeList - whitespace is
optional around the '=' but required before each QName.

If it worked before, I believe that was a bug. If so, the fix was
probably part of the unquoted attribute value fix.

-- Mike

On 26 Mar 2012, at 09:56 , Khan, Kashif wrote:

  img class=harcourt-logosrc={ $xqmvc:resource-dir

___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general

___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general


[MarkLogic Dev General] Marklogic Rollback from V5 to V4.2

2012-01-31 Thread Khan, Kashif
Does anyone know the steps to rollback from a Marklogic Server upgrade. I
am planning to upgrade to Marklogic 5 from V4.2-3.2. Before proceeding I
wanted to hash out my rollback plan. I am thinking about following these
steps

1- uninstall Marklogic server 5 and reinstall the older version 4.2-3.2 in
my case
2- restore the Database that was taken before the upgrade to Marklogic 5

Are these steps enough for a rollback? I am not sure if restoring the
database will rollback the changes to Security database and other
databases that are upgraded as part of the Marklogic 5 upgrade.


Best Regards,
Kashif Khan

___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] searchable-expression

2012-01-25 Thread Khan, Kashif
Geert, The version of Marklogic is 4.2-3.2

Best Regards,
Kashif Khan
Sr. Solutions Architect
Houghton Mifflin Harcourt, Orlando, FL
Office: (407) 345-3420
Cell: (407) 949-4697

The water you touch in the river is the last of that which has passed and the 
first of that which is coming --Leonardo da Vinci



From: Geert Josten geert.jos...@dayon.nlmailto:geert.jos...@dayon.nl
Reply-To: General MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Date: Wed, 25 Jan 2012 02:15:35 -0500
To: General MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Subject: Re: [MarkLogic Dev General] searchable-expression

Hi Kashif,

Which version of MarkLogic are you running? Your code seems to run just fine in 
5.0-2.

Kind regards,
Geert

Van: 
general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com
 
[mailto:general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com]
 Namens Khan, Kashif
Verzonden: dinsdag 24 januari 2012 23:30
Aan: General MarkLogic Developer Discussion
Onderwerp: [MarkLogic Dev General] searchable-expression

I am getting an error when I try to run the following query. Any help will be 
appreciated to resolve this issue.

search:search('Title:(power) Show:productsets special:title',
options  xmlns=http://marklogic.com/appservices/search;


operator name=special
   state name=title

   searchable-expression xmlns:pce=http://pcenamespace;

xmlns:dc=http://purl.org/dc/elements/1.1/;/pce:productSet/dc:title

  /searchable-expression

   /state
/operator

   /options
)


Error:

query evaluated in pce at pce-modules:/ as 1.0-ml (cq v4.0-1.1)

[1.0-ml] XDMP-ARGTYPE: (err:XPTY0004) 
fn:in-scope-prefixes((searchable-expression 
xmlns:dc=http://purl.org/dc/elements/1.1/; xmlns:pce=http://pcenamespace; 
xmlns=http://marklogic.com/appservices/search;/pce:productSet/dc:title#10; 
#10; /searchable-expression, searchable-expression 
xmlns:dc=http://purl.org/dc/elements/1.1/; xmlns:pce=http://pcenamespace; 
xmlns=http://marklogic.com/appservices/search;/pce:productSet/dc:title#10; 
#10; /searchable-expression)) -- arg1 is not of type element()

Stack trace:
in /MarkLogic/appservices/search/search-impl.xqy line 2047:
impl:build-ns-bindings(options 
xmlns=http://marklogic.com/appservices/search;searchable-expression 
xmlns:dc=http://purl.org/dc/elements/1.1.../options)

$options := options 
xmlns=http://purl.org/dc/elements/1.1...%3c/options%3e)%0b%0b$options%20:=%20%3coptions%20xmlns=http://marklogic.com/appservices/search;searchable-expression
 xmlns:dc=http://purl.org/dc/elements/1.1.../options
$map := map:map()
$opt-ns := ()
in /MarkLogic/appservices/search/search-impl.xqy line 1354:
impl:build-order-by(options 
xmlns=http://marklogic.com/appservices/search;searchable-expression 
xmlns:dc=http://purl.org/dc/elements/1.1.../options)

$options := options 
xmlns=http://purl.org/dc/elements/1.1...%3c/options%3e)%0b%0b$options%20:=%20%3coptions%20xmlns=http://marklogic.com/appservices/search;searchable-expression
 xmlns:dc=http://purl.org/dc/elements/1.1.../options
in /MarkLogic/appservices/search/search-impl.xqy line 1339:
impl:build-flwor(options 
xmlns=http://marklogic.com/appservices/search;searchable-expression 
xmlns:dc=http://purl.org/dc/elements/1.1.../options, cts:and-query 
strength=http://purl.org/dc/elements/1.1...%3c/options%3e,%20%3ccts:and-query%20strength=20
 qtextjoin= xmlns:cts=http://marklogic.com/cts;cts:word-query 
qtextref=cts:textcts:textTitle:power/cts:t.../cts:and-query, 
xs:unsignedLong(1), 10, quality-weight 
xmlns=http://marklogic.com/appservices/search;1.0/quality-weight, ())

$options := options 
xmlns=http://marklogic.com/appservices/search;searchable-expression 
xmlns:dc=http://purl.org/dc/elements/1.1.../options
$cts := cts:and-query 
strength=http://purl.org/dc/elements/1.1...%3c/options%3e%0b$cts%20:=%20%3ccts:and-query%20strength=20
 qtextjoin= xmlns:cts=http://marklogic.com/cts;cts:word-query 
qtextref=cts:textcts:textTitle:power/cts:t.../cts:and-query
$start := xs:unsignedLong(1)
$end := 10
$quality-weight := xs:double(1)
$forests := ()
$scope := searchable-expression xmlns:dc=http://purl.org/dc/elements/1.1/; 
xmlns:pce=http://pcenamespace; 
xmlns=http://marklogic.com/appservices/search;/pce:productSet/dc:title#10; 
#10; /searchable-expression
in /MarkLogic/appservices/search/search-impl.xqy line 1189:
impl:do-query(Title:(power) Show:productsets special:title, options 
xmlns=http://marklogic.com/appservices/search;operator name=specialstate 
name=titlesearchable-express.../options, (), 1, (), fn:false())

$qtext := Title:(power) Show:productsets special:title
$deltaoptions := options 
xmlns=http://marklogic.com/appservices/search;operator name=specialstate 
name=titlesearchable-express.../options
$ctsquery := ()
$start := xs:unsignedLong(1)
$page-length := ()
$raw-results := fn:false()
$t-minus-0

[MarkLogic Dev General] searchable-expression

2012-01-24 Thread Khan, Kashif
I am getting an error when I try to run the following query. Any help will be 
appreciated to resolve this issue.

search:search('Title:(power) Show:productsets special:title',
options  xmlns=http://marklogic.com/appservices/search;


operator name=special
   state name=title

   searchable-expression xmlns:pce=http://pcenamespace;
xmlns:dc=http://purl.org/dc/elements/1.1/;/pce:productSet/dc:title

  /searchable-expression

   /state
/operator

   /options
)


Error:

query evaluated in pce at pce-modules:/ as 1.0-ml (cq v4.0-1.1)

[1.0-ml] XDMP-ARGTYPE: (err:XPTY0004) 
fn:in-scope-prefixes((searchable-expression 
xmlns:dc=http://purl.org/dc/elements/1.1/; xmlns:pce=http://pcenamespace; 
xmlns=http://marklogic.com/appservices/search;/pce:productSet/dc:title#10; 
#10; /searchable-expression, searchable-expression 
xmlns:dc=http://purl.org/dc/elements/1.1/; xmlns:pce=http://pcenamespace; 
xmlns=http://marklogic.com/appservices/search;/pce:productSet/dc:title#10; 
#10; /searchable-expression)) -- arg1 is not of type element()

Stack trace:

in /MarkLogic/appservices/search/search-impl.xqy line 2047:
impl:build-ns-bindings(options 
xmlns=http://marklogic.com/appservices/search;searchable-expression 
xmlns:dc=http://purl.org/dc/elements/1.1.../options)

$options := options 
xmlns=http://marklogic.com/appservices/search;searchable-expression 
xmlns:dc=http://purl.org/dc/elements/1.1.../options
$map := map:map()
$opt-ns := ()

in /MarkLogic/appservices/search/search-impl.xqy line 1354:
impl:build-order-by(options 
xmlns=http://marklogic.com/appservices/search;searchable-expression 
xmlns:dc=http://purl.org/dc/elements/1.1.../options)

$options := options 
xmlns=http://marklogic.com/appservices/search;searchable-expression 
xmlns:dc=http://purl.org/dc/elements/1.1.../options

in /MarkLogic/appservices/search/search-impl.xqy line 1339:
impl:build-flwor(options 
xmlns=http://marklogic.com/appservices/search;searchable-expression 
xmlns:dc=http://purl.org/dc/elements/1.1.../options, cts:and-query 
strength=20 qtextjoin= xmlns:cts=http://marklogic.com/cts;cts:word-query 
qtextref=cts:textcts:textTitle:power/cts:t.../cts:and-query, 
xs:unsignedLong(1), 10, quality-weight 
xmlns=http://marklogic.com/appservices/search;1.0/quality-weight, ())

$options := options 
xmlns=http://marklogic.com/appservices/search;searchable-expression 
xmlns:dc=http://purl.org/dc/elements/1.1.../options
$cts := cts:and-query strength=20 qtextjoin= 
xmlns:cts=http://marklogic.com/cts;cts:word-query 
qtextref=cts:textcts:textTitle:power/cts:t.../cts:and-query
$start := xs:unsignedLong(1)
$end := 10
$quality-weight := xs:double(1)
$forests := ()
$scope := searchable-expression xmlns:dc=http://purl.org/dc/elements/1.1/; 
xmlns:pce=http://pcenamespace; 
xmlns=http://marklogic.com/appservices/search;/pce:productSet/dc:title#10; 
#10; /searchable-expression

in /MarkLogic/appservices/search/search-impl.xqy line 1189:
impl:do-query(Title:(power) Show:productsets special:title, options 
xmlns=http://marklogic.com/appservices/search;operator name=specialstate 
name=titlesearchable-express.../options, (), 1, (), fn:false())

$qtext := Title:(power) Show:productsets special:title
$deltaoptions := options 
xmlns=http://marklogic.com/appservices/search;operator name=specialstate 
name=titlesearchable-express.../options
$ctsquery := ()
$start := xs:unsignedLong(1)
$page-length := ()
$raw-results := fn:false()
$t-minus-0 := xs:dayTimeDuration(PT0.001371S)
$init-options := options 
xmlns=http://marklogic.com/appservices/search;operator name=specialstate 
name=titlesearchable-express.../options
$parsed-query := cts:and-query strength=20 qtextjoin= 
xmlns:cts=http://marklogic.com/cts;cts:word-query 
qtextref=cts:textcts:textTitle:power/cts:t.../cts:and-query
$options := options 
xmlns=http://marklogic.com/appservices/search;searchable-expression 
xmlns:dc=http://purl.org/dc/elements/1.1.../options
$return-results := fn:true()
$return-metrics := fn:true()
$return-facets := fn:true()
$return-plan := ()
$return-qtext := fn:true()
$return-query := fn:false()
$return-constraints := fn:false()
$return-similar := fn:false()
$format-fname := attribute{fn:QName(, apply)}{snippet}
$extra-cts := ()
$quality-weight := quality-weight 
xmlns=http://marklogic.com/appservices/search;1.0/quality-weight
$forests := ()
$page-length := 10
$page-length := 10
$debug-mode := fn:false()
$options-validate := ()
$start := xs:unsignedLong(1)
$start := xs:unsignedLong(1)
$end := 10
$log := ()
$combined-query := cts:and-query strength=20 qtextjoin= 
xmlns:cts=http://marklogic.com/cts;cts:word-query 
qtextref=cts:textcts:textTitle:power/cts:t.../cts:and-query
$warnings := ()

in /MarkLogic/appservices/search/search.xqy line 31:
search:search(Title:(power) Show:productsets special:title, options 
xmlns=http://marklogic.com/appservices/search;operator name=specialstate 
name=titlesearchable-express.../options)

$qtext := Title:(power) Show:productsets special:title
$options 

[MarkLogic Dev General] Parallel Task Servers

2011-08-22 Thread Khan, Kashif
Hello Everyone, I wanted to ask if it is possible to create multiple task 
servers to handle the load. So we can process the tasks on multiple task 
servers at a time.

Best Regards,
Kashif Khan

___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] Parallel Task Servers

2011-08-22 Thread Khan, Kashif
Thanks. I was looking into doing this as sometimes there are too many tasks and 
the Taskserver is backed up with thousands of tasks. I am Just looking at ways 
to load balance the tasks to make it go fast.

Best Regards,
Kashif Khan
Sr. Solutions Architect
Houghton Mifflin Harcourt, Orlando, FL
Office: (407) 345-3420
Cell: (407) 949-4697

The water you touch in the river is the last of that which has passed and the 
first of that which is coming --Leonardo da Vinci



From: Danny Sokolsky 
danny.sokol...@marklogic.commailto:danny.sokol...@marklogic.com
Reply-To: General MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Date: Mon, 22 Aug 2011 16:54:45 -0400
To: General MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Subject: Re: [MarkLogic Dev General] Parallel Task Servers

You would need to create a cluster.  Then direct your load at multiple hosts in 
that cluster.  This book:

http://docs.marklogic.com/4.2doc/docapp.xqy#display.xqy?fname=http://pubs/4.2doc/xml/cluster/title.xml

talks about some of that (as well as failover).

For example, if you had a cluster with host1, host2, and host3, then you can 
direct part of your load to host1, part to host2, and part to host3.

Now to step back a minute, why do you really need to do this?  The task server 
runs multi-threaded, so if you have extra horsepower on your host, you should 
be able to take advantage of that.

-Danny

From: 
general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com
 [mailto:general-boun...@developer.marklogic.com] On Behalf Of Khan, Kashif
Sent: Monday, August 22, 2011 1:26 PM
To: General MarkLogic Developer Discussion
Subject: Re: [MarkLogic Dev General] Parallel Task Servers

Is there somewhere I can read on creating parallel Hosts and dividing the load?

Best Regards,
Kashif Khan
Sr. Solutions Architect
Houghton Mifflin Harcourt, Orlando, FL
Office: (407) 345-3420
Cell: (407) 949-4697

The water you touch in the river is the last of that which has passed and the 
first of that which is coming --Leonardo da Vinci



From: Danny Sokolsky 
danny.sokol...@marklogic.commailto:danny.sokol...@marklogic.com
Reply-To: General MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Date: Mon, 22 Aug 2011 16:19:57 -0400
To: General MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Subject: Re: [MarkLogic Dev General] Parallel Task Servers

The way you do this is to parallelize the load across multiple hosts.  Each 
host has 1 task server.

-Danny

From: 
general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com
 [mailto:general-boun...@developer.marklogic.com] On Behalf Of Khan, Kashif
Sent: Monday, August 22, 2011 12:43 PM
To: MarkLogic Developer Discussion
Subject: [MarkLogic Dev General] Parallel Task Servers

Hello Everyone, I wanted to ask if it is possible to create multiple task 
servers to handle the load. So we can process the tasks on multiple task 
servers at a time.

Best Regards,
Kashif Khan

___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] Parallel Task Servers

2011-08-22 Thread Khan, Kashif
Is there a limit to the number of threads? I have set it to 10.

Best Regards,
Kashif Khan
Sr. Solutions Architect
Houghton Mifflin Harcourt, Orlando, FL
Office: (407) 345-3420
Cell: (407) 949-4697

The water you touch in the river is the last of that which has passed and the 
first of that which is coming --Leonardo da Vinci



From: Danny Sokolsky 
danny.sokol...@marklogic.commailto:danny.sokol...@marklogic.com
Reply-To: General MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Date: Mon, 22 Aug 2011 16:54:45 -0400
To: General MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Subject: Re: [MarkLogic Dev General] Parallel Task Servers

You would need to create a cluster.  Then direct your load at multiple hosts in 
that cluster.  This book:

http://docs.marklogic.com/4.2doc/docapp.xqy#display.xqy?fname=http://pubs/4.2doc/xml/cluster/title.xml

talks about some of that (as well as failover).

For example, if you had a cluster with host1, host2, and host3, then you can 
direct part of your load to host1, part to host2, and part to host3.

Now to step back a minute, why do you really need to do this?  The task server 
runs multi-threaded, so if you have extra horsepower on your host, you should 
be able to take advantage of that.

-Danny

From: 
general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com
 [mailto:general-boun...@developer.marklogic.com] On Behalf Of Khan, Kashif
Sent: Monday, August 22, 2011 1:26 PM
To: General MarkLogic Developer Discussion
Subject: Re: [MarkLogic Dev General] Parallel Task Servers

Is there somewhere I can read on creating parallel Hosts and dividing the load?

Best Regards,
Kashif Khan
Sr. Solutions Architect
Houghton Mifflin Harcourt, Orlando, FL
Office: (407) 345-3420
Cell: (407) 949-4697

The water you touch in the river is the last of that which has passed and the 
first of that which is coming --Leonardo da Vinci



From: Danny Sokolsky 
danny.sokol...@marklogic.commailto:danny.sokol...@marklogic.com
Reply-To: General MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Date: Mon, 22 Aug 2011 16:19:57 -0400
To: General MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Subject: Re: [MarkLogic Dev General] Parallel Task Servers

The way you do this is to parallelize the load across multiple hosts.  Each 
host has 1 task server.

-Danny

From: 
general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com
 [mailto:general-boun...@developer.marklogic.com] On Behalf Of Khan, Kashif
Sent: Monday, August 22, 2011 12:43 PM
To: MarkLogic Developer Discussion
Subject: [MarkLogic Dev General] Parallel Task Servers

Hello Everyone, I wanted to ask if it is possible to create multiple task 
servers to handle the load. So we can process the tasks on multiple task 
servers at a time.

Best Regards,
Kashif Khan

___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] Parallel Task Servers

2011-08-22 Thread Khan, Kashif
Thanks for all the information. I really appreciate it.


Best Regards,
Kashif Khan
Sr. Solutions Architect
Houghton Mifflin Harcourt, Orlando, FL
Office: (407) 345-3420
Cell: (407) 949-4697

The water you touch in the river is the last of that which has passed and the 
first of that which is coming --Leonardo da Vinci

From: Wayne Feick wayne.fe...@marklogic.commailto:wayne.fe...@marklogic.com
Reply-To: General MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Date: Mon, 22 Aug 2011 17:52:53 -0400
To: general@developer.marklogic.commailto:general@developer.marklogic.com 
general@developer.marklogic.commailto:general@developer.marklogic.com
Subject: Re: [MarkLogic Dev General] Parallel Task Servers

The limit is 256, but it has more to do with the number of CPU cores you have 
on the host balanced with how CPU intensive your application is (both tasks and 
application server activity).

For example, if you're doing lots of xdmp:http-get() operations from the task 
queue, a larger number of threads might be appropriate for parallelism. Tasks 
that tend to wait on disk I/O might also benefit from a larger number of 
threads.

On the other hand, if your tasks are CPU bound instead of I/O bound you won't 
want more than the number of cores on the host.

You should also keep in mind that a large number of task queue threads could 
negatively impact your application server performance since they'll be 
competing with each other for CPU and I/O resources.

Wayne.


On 08/22/2011 02:22 PM, Khan, Kashif wrote:
Is there a limit to the number of threads? I have set it to 10.

Best Regards,
Kashif Khan
Sr. Solutions Architect
Houghton Mifflin Harcourt, Orlando, FL
Office: (407) 345-3420
Cell: (407) 949-4697

The water you touch in the river is the last of that which has passed and the 
first of that which is coming --Leonardo da Vinci



From: Danny Sokolsky 
danny.sokol...@marklogic.commailto:danny.sokol...@marklogic.com
Reply-To: General MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Date: Mon, 22 Aug 2011 16:54:45 -0400
To: General MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Subject: Re: [MarkLogic Dev General] Parallel Task Servers

You would need to create a cluster.  Then direct your load at multiple hosts in 
that cluster.  This book:

http://docs.marklogic.com/4.2doc/docapp.xqy#display.xqy?fname=http://pubs/4.2doc/xml/cluster/title.xml

talks about some of that (as well as failover).

For example, if you had a cluster with host1, host2, and host3, then you can 
direct part of your load to host1, part to host2, and part to host3.

Now to step back a minute, why do you really need to do this?  The task server 
runs multi-threaded, so if you have extra horsepower on your host, you should 
be able to take advantage of that.

-Danny

From: 
general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com
 [mailto:general-boun...@developer.marklogic.com] On Behalf Of Khan, Kashif
Sent: Monday, August 22, 2011 1:26 PM
To: General MarkLogic Developer Discussion
Subject: Re: [MarkLogic Dev General] Parallel Task Servers

Is there somewhere I can read on creating parallel Hosts and dividing the load?

Best Regards,
Kashif Khan
Sr. Solutions Architect
Houghton Mifflin Harcourt, Orlando, FL
Office: (407) 345-3420
Cell: (407) 949-4697

The water you touch in the river is the last of that which has passed and the 
first of that which is coming --Leonardo da Vinci



From: Danny Sokolsky 
danny.sokol...@marklogic.commailto:danny.sokol...@marklogic.com
Reply-To: General MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Date: Mon, 22 Aug 2011 16:19:57 -0400
To: General MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Subject: Re: [MarkLogic Dev General] Parallel Task Servers

The way you do this is to parallelize the load across multiple hosts.  Each 
host has 1 task server.

-Danny

From: 
general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com
 [mailto:general-boun...@developer.marklogic.com] On Behalf Of Khan, Kashif
Sent: Monday, August 22, 2011 12:43 PM
To: MarkLogic Developer Discussion
Subject: [MarkLogic Dev General] Parallel Task Servers

Hello Everyone, I wanted to ask if it is possible to create multiple task 
servers to handle the load. So we can process the tasks on multiple task 
servers at a time.

Best Regards,
Kashif Khan



--
Wayne Feick
Principal Engineer
MarkLogic Corporation
wayne.fe...@marklogic.commailto:wayne.fe...@marklogic.com
Phone: +1 650 655 2378
www.marklogic.comhttp://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

Re: [MarkLogic Dev General] Clarification on MarkLogic

2011-07-20 Thread Khan, Kashif
When you take a backup of a database all the settings you mentioned are
also backed up. So when you restore the database all the settings will be
restored.


Best Regards,
Kashif Khan



On 7/20/11 9:22 AM, Aiswarya aiswarya.venkatachalapa...@laserwords.com
wrote:

Hi Kashif Khan,

Thanks for your quick reply. I can take the backup of the content and
restore it back. But, Is there any way to get a full report on the
available
databases configuration such as searches enabled, created range Indexes
(with their scalar type, namespace, collation, localname), created
lexicons,
enabled  created pipelines and so on. I will need all these to manually
recreate the databases. Could you please help me out!!

Thanks
Aiswarya V

-Original Message-
From: general-boun...@developer.marklogic.com
[mailto:general-boun...@developer.marklogic.com] On Behalf Of
general-requ...@developer.marklogic.com
Sent: Wednesday, July 20, 2011 6:02 PM
To: general@developer.marklogic.com
Subject: General Digest, Vol 85, Issue 68

Send General mailing list submissions to
   general@developer.marklogic.com

To subscribe or unsubscribe via the World Wide Web, visit
   http://developer.marklogic.com/mailman/listinfo/general
or, via email, send a message with subject or body 'help' to
   general-requ...@developer.marklogic.com

You can reach the person managing the list at
   general-ow...@developer.marklogic.com

When replying, please edit your Subject line so it is more specific
than Re: Contents of General digest...


Today's Topics:

   1. Reg: Wildcarded search doesn't returnfitness (ambika arumugam)
   2. Re: Clarification on MarkLogic (Khan, Kashif)


--

Message: 1
Date: Wed, 20 Jul 2011 16:40:27 +0530
From: ambika arumugam ambikaarumuga...@gmail.com
Subject: [MarkLogic Dev General] Reg: Wildcarded search doesn't return
   fitness
To: General MarkLogic Developer Discussion
   general@developer.marklogic.com
Message-ID:
   CAESiW4HcttaTF=Pvky=fqvrmcb7oecfy4z-oqmd3xazbsoc...@mail.gmail.com
Content-Type: text/plain; charset=iso-8859-1

Hi all,

I am performing a search to return results with its fitness value

let $options := options xmlns=http://marklogic.com/appservices/search;
term
  term-optionwildcarded/term-option
/term
/options

return search:search(the,$options)//search:result/@fitness
this returns me the results with its fitness

but when i perform wildcarded search

 search:search(the*,$options)//search:result/@fitness

it gives me the result but the values of fitness, score and confidence are
zero.

Am i missing something?

I would like to get the relevance fitness values for all results while i
do
the wildcarded search.

Regards
Ambika
-- next part --
An HTML attachment was scrubbed...
URL:
http://developer.marklogic.com/pipermail/general/attachments/20110720/c209
40
0f/attachment-0001.html

--

Message: 2
Date: Wed, 20 Jul 2011 08:28:27 -0400
From: Khan, Kashif kashif.k...@hmhpub.com
Subject: Re: [MarkLogic Dev General] Clarification on MarkLogic
To: General MarkLogic Developer Discussion
   general@developer.marklogic.com
Message-ID: ca4c4095.699e%kashif.k...@hmhpub.com
Content-Type: text/plain; charset=windows-1252

This should work for you unless someone else disagrees

 1.  Just take a backup of the the databases that you need. Store this on
an
external drive.
 2.  Restore your machine.
 3.  Manually recreate the databases. I think you will have to keep the
same
name as before. At this point you will not have any content in the
databases
 4.  Restore the daatabase that you created in step 1 from the backup.
Best Regards,
Kashif Khan
Sr. Solutions Architect
Houghton Mifflin Harcourt, Orlando, FL
Office: (407) 345-3420
Cell: (407) 949-4697

The water you touch in the river is the last of that which has passed and
the first of that which is coming --Leonardo da Vinci



From: Aiswarya
aiswarya.venkatachalapa...@laserwords.commailto:aiswarya.venkatachalapat
hy
@laserwords.com
Reply-To: General MarkLogic Developer Discussion
general@developer.marklogic.commailto:general@developer.marklogic.com
Date: Wed, 20 Jul 2011 04:00:00 -0400
To:
general@developer.marklogic.commailto:general@developer.marklogic.com
general@developer.marklogic.commailto:general@developer.marklogic.com
Subject: [MarkLogic Dev General] Clarification on MarkLogic


Hi Guys,



I desperately need your help.



I need to format my machine but I don?t want to lose any of the content or
configuration of MarkLogic(such as database, forest, pipelines
configuration
etc.,)of my machine. Is there something that I can take a back up of whole
Mark Logic installed in my machine and roll back after formatting the
machine. Please help me out.



Thanks

Aiswarya V


-- next part --
An HTML attachment was scrubbed...
URL:
http://developer.marklogic.com/pipermail/general

Re: [MarkLogic Dev General] Clarification on MarkLogic

2011-07-20 Thread Khan, Kashif
One thing I forgot to mention is that when you recreate the database in
step 3 you do not have to configure it. Just give it the same name as
before and do the basic settings. It will inherit al the indexes and
search configurations etc once you restore the database from the backup.

I am sure you know this but just an FYI. When you take a backup of
batabase all the content is also backed up. So restoring the database will
also restore the content.


Best Regards,
Kashif Khan



On 7/20/11 9:09 AM, Khan, Kashif kashif.k...@hmhpub.com wrote:

When you take a backup of a database all the settings you mentioned are
also backed up. So when you restore the database all the settings will be
restored.


Best Regards,
Kashif Khan



On 7/20/11 9:22 AM, Aiswarya aiswarya.venkatachalapa...@laserwords.com
wrote:

Hi Kashif Khan,

Thanks for your quick reply. I can take the backup of the content and
restore it back. But, Is there any way to get a full report on the
available
databases configuration such as searches enabled, created range Indexes
(with their scalar type, namespace, collation, localname), created
lexicons,
enabled  created pipelines and so on. I will need all these to manually
recreate the databases. Could you please help me out!!

Thanks
Aiswarya V

-Original Message-
From: general-boun...@developer.marklogic.com
[mailto:general-boun...@developer.marklogic.com] On Behalf Of
general-requ...@developer.marklogic.com
Sent: Wednesday, July 20, 2011 6:02 PM
To: general@developer.marklogic.com
Subject: General Digest, Vol 85, Issue 68

Send General mailing list submissions to
  general@developer.marklogic.com

To subscribe or unsubscribe via the World Wide Web, visit
  http://developer.marklogic.com/mailman/listinfo/general
or, via email, send a message with subject or body 'help' to
  general-requ...@developer.marklogic.com

You can reach the person managing the list at
  general-ow...@developer.marklogic.com

When replying, please edit your Subject line so it is more specific
than Re: Contents of General digest...


Today's Topics:

   1. Reg: Wildcarded search doesn't return   fitness (ambika arumugam)
   2. Re: Clarification on MarkLogic (Khan, Kashif)


--

Message: 1
Date: Wed, 20 Jul 2011 16:40:27 +0530
From: ambika arumugam ambikaarumuga...@gmail.com
Subject: [MarkLogic Dev General] Reg: Wildcarded search doesn't return
  fitness
To: General MarkLogic Developer Discussion
  general@developer.marklogic.com
Message-ID:
  CAESiW4HcttaTF=Pvky=fqvrmcb7oecfy4z-oqmd3xazbsoc...@mail.gmail.com
Content-Type: text/plain; charset=iso-8859-1

Hi all,

I am performing a search to return results with its fitness value

let $options := options xmlns=http://marklogic.com/appservices/search;
term
  term-optionwildcarded/term-option
/term
/options

return search:search(the,$options)//search:result/@fitness
this returns me the results with its fitness

but when i perform wildcarded search

 search:search(the*,$options)//search:result/@fitness

it gives me the result but the values of fitness, score and confidence
are
zero.

Am i missing something?

I would like to get the relevance fitness values for all results while i
do
the wildcarded search.

Regards
Ambika
-- next part --
An HTML attachment was scrubbed...
URL:
http://developer.marklogic.com/pipermail/general/attachments/20110720/c20
9
40
0f/attachment-0001.html

--

Message: 2
Date: Wed, 20 Jul 2011 08:28:27 -0400
From: Khan, Kashif kashif.k...@hmhpub.com
Subject: Re: [MarkLogic Dev General] Clarification on MarkLogic
To: General MarkLogic Developer Discussion
  general@developer.marklogic.com
Message-ID: ca4c4095.699e%kashif.k...@hmhpub.com
Content-Type: text/plain; charset=windows-1252

This should work for you unless someone else disagrees

 1.  Just take a backup of the the databases that you need. Store this on
an
external drive.
 2.  Restore your machine.
 3.  Manually recreate the databases. I think you will have to keep the
same
name as before. At this point you will not have any content in the
databases
 4.  Restore the daatabase that you created in step 1 from the backup.
Best Regards,
Kashif Khan
Sr. Solutions Architect
Houghton Mifflin Harcourt, Orlando, FL
Office: (407) 345-3420
Cell: (407) 949-4697

The water you touch in the river is the last of that which has passed
and
the first of that which is coming --Leonardo da Vinci



From: Aiswarya
aiswarya.venkatachalapa...@laserwords.commailto:aiswarya.venkatachalapa
t
hy
@laserwords.com
Reply-To: General MarkLogic Developer Discussion
general@developer.marklogic.commailto:general@developer.marklogic.com
Date: Wed, 20 Jul 2011 04:00:00 -0400
To:
general@developer.marklogic.commailto:general@developer.marklogic.com
general@developer.marklogic.commailto:general@developer.marklogic.com
Subject: [MarkLogic Dev General] Clarification

[MarkLogic Dev General] Issue with running a query

2011-07-19 Thread Khan, Kashif
I am having issue running the following query

/pce:productSet[pce:bodymatter/pce:sequences/pce:sequence/pce:sequence-type = 
unit]

But if I change the query to use unit with a capital U it works fine. So 
the query below work fine

/pce:productSet[pce:bodymatter/pce:sequences/pce:sequence/pce:sequence-type = 
Unit]


Here is the error that I get.
=
[1.0-ml] XDMP-LEXVAL: pce:(unit) -- Invalid lexical value unit

Stack trace:

line 5:
3: declare namespace pce = http://pcenamespace;;
4:
5: /pce:productSet[pce:bodymatter/pce:sequences/pce:sequence/pce:sequence-type 
= unit]

xdmp:eval(xquery version quot;1.0-mlquot;;#13;#10;import module 
namesp..., (), options 
xmlns=xdmp:evaldatabase6048470272743008717/databasemodules297543754947072.../options)

in /eval.xqy line 93:





Best Regards,
Kashif Khan

The water you touch in the river is the last of that which has passed and the 
first of that which is coming --Leonardo da Vinci


___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] Issue with running a query

2011-07-19 Thread Khan, Kashif
Thank you so much. Yes it was in the Schema. My issue is now resolved.

Best Regards,
Kashif Khan
Sr. Solutions Architect
Houghton Mifflin Harcourt, Orlando, FL
Office: (407) 345-3420
Cell: (407) 949-4697

The water you touch in the river is the last of that which has passed and the 
first of that which is coming --Leonardo da Vinci



From: Danny Sokolsky 
danny.sokol...@marklogic.commailto:danny.sokol...@marklogic.com
Reply-To: General MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Date: Tue, 19 Jul 2011 17:42:35 -0400
To: General MarkLogic Developer Discussion 
general@developer.marklogic.commailto:general@developer.marklogic.com
Subject: Re: [MarkLogic Dev General] Issue with running a query

Is there an in-scope schema for pce:sequence-type?  Maybe “Unit” is a valid 
value according to that schema and “unit” is not?

-Danny

From: 
general-boun...@developer.marklogic.commailto:general-boun...@developer.marklogic.com
 [mailto:general-boun...@developer.marklogic.com] On Behalf Of Khan, Kashif
Sent: Tuesday, July 19, 2011 2:17 PM
To: general@developer.marklogic.commailto:general@developer.marklogic.com
Subject: [MarkLogic Dev General] Issue with running a query

I am having issue running the following query

/pce:productSet[pce:bodymatter/pce:sequences/pce:sequence/pce:sequence-type = 
unit]

But if I change the query to use unit with a capital U it works fine. So 
the query below work fine

/pce:productSet[pce:bodymatter/pce:sequences/pce:sequence/pce:sequence-type = 
Unit]


Here is the error that I get.
=
[1.0-ml] XDMP-LEXVAL: pce:(unit) -- Invalid lexical value unit

Stack trace:
line 5:
3: declare namespace pce = http://pcenamespace;;
4:
5: /pce:productSet[pce:bodymatter/pce:sequences/pce:sequence/pce:sequence-type 
= unit]

xdmp:eval(xquery version quot;1.0-mlquot;;#13;#10;import module 
namesp..., (), options 
xmlns=xdmp:evaldatabase6048470272743008717/databasemodules297543754947072.../options)

in /eval.xqy line 93:





Best Regards,
Kashif Khan

The water you touch in the river is the last of that which has passed and the 
first of that which is coming --Leonardo da Vinci


___
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general