[MarkLogic Dev General] Model Employee-Department relationship into marklogic, Running Join queries. #CGO#

2016-08-16 Thread Jain, Abhishek
Hi Forks,

I am a newbie to marklogic, I just want to migrate all my RDBMS data into 
marklogic.
If anyone can just share with me the idea how to model simple 
Employee-Department
Relationship in Marklogic and run join query . Do we need triples to achieve 
this ? If yes a simple example will do.
Thanks in advance.

Thanks and Regards,
[Email_CBE.gif]Abhishek Jain
Associate Consultant
People matter, results count.

This message contains information that may be privileged or confidential and is 
the property of the Capgemini Group. It is intended only for the person to whom 
it is addressed. If you are not the intended recipient, you are not authorized 
to read, print, retain, copy, disseminate, distribute, or use this message or 
any part thereof. If you receive this message in error, please notify the 
sender immediately and delete all copies of this message.
___
General mailing list
General@developer.marklogic.com
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] How to merge two json document in to another document in MarkLogic

2016-08-16 Thread Siva Viswabrahmana - Contractor
Hi,
I thought about the “id” as it duplicates. Lets have a slight different scenario

/1.json:
{“id”:”1”, “fname”:”Scott”}

/2.json:
{“lname”:”McNelay”}
Expected result:

/12.json
{
“id”:””,
“fname”:”Scott”,
“lname”:”McNelay”
}


Regards
Siva.
From: 
>
 on behalf of Justin Makeig 
>
Reply-To: MarkLogic Developer Discussion 
>
Date: Tuesday, August 16, 2016 at 4:39 PM
To: MarkLogic Developer Discussion 
>
Subject: Re: [MarkLogic Dev General] How to merge two json document in to 
another document in MarkLogic

What does is the merged document supposed to look like? What is the logic when 
key names collide? Last wins?

Justin

On Aug 16, 2016, at 1:34 PM, Siva Viswabrahmana - Contractor 
> wrote:

Hi,

/1.json:
{“id”:”1”, “fname”:”Scott”}

/2.json:
{“id”:”2”, “lname”:”McNelay”}

Hope this works.

—Siva.

From: 
>
 on behalf of Justin Makeig 
>
Reply-To: MarkLogic Developer Discussion 
>
Date: Tuesday, August 16, 2016 at 4:31 PM
To: MarkLogic Developer Discussion 
>
Subject: Re: [MarkLogic Dev General] How to merge two json document in to 
another document in MarkLogic

Can you show an examples of 1.json, 2.json, and 12.json? It's unclear what you 
mean by merge.

Justin

--
Justin Makeig
Director, Product Management
MarkLogic
justin.mak...@marklogic.com

On Aug 16, 2016, at 1:19 PM, Siva Viswabrahmana - Contractor 
> wrote:

Hi,
I am trying to merge /1.json +/2.json into /12.json

Below query does not allow another document{…}

xdmp:document-insert("/test/2.json",document { doc("/test/1.json") 
},(),("aggregate")),
doc("/test/2.json”);

Pls advise.

Regards
Siva.

From: 
>
 on behalf of Rob Szkutak 
>
Reply-To: MarkLogic Developer Discussion 
>
Date: Tuesday, August 16, 2016 at 4:16 PM
To: MarkLogic Developer Discussion 
>
Subject: Re: [MarkLogic Dev General] How to merge two json document in to 
another document in MarkLogic

Hello,

Could you be more specific about what you're trying to accomplish? A sample of 
the structure of your two documents and the merged format you would like to put 
them in would be helpful in understanding how to assist you.

Best,
Rob

Rob Szkutak
Senior Consultant
MarkLogic Corporation
rob.szku...@marklogic.com
www.marklogic.com


From: 
general-boun...@developer.marklogic.com
 
[general-boun...@developer.marklogic.com]
 on behalf of Siva Viswabrahmana - Contractor 
[siva.viswabrahm...@scdhhs.gov]
Sent: Tuesday, August 16, 2016 3:11 PM
To: general@developer.marklogic.com
Subject: [MarkLogic Dev General] How to merge two json document in to another 
document in MarkLogic

Hi,
How to merge two json document in to another document in MarkLogic?

Regards
Siva.
Confidentiality Note


This message is intended for the use of the person or entity to which it is 
addressed and may contain information, including health information, that is 
privileged, confidential, and the disclosure of which is governed by applicable 
law. If the reader of this message is not the intended recipient, or the 
employee or agent responsible to deliver it to the intended recipient, you are 
hereby notified that any dissemination, distribution or copying of this 
information is STRICTLY PROHIBITED.

If you have received this in error, please notify us immediately and destroy 
the related message.
Confidentiality Note


This message is intended for the use of the person or entity to which it is 
addressed and may contain information, including health information, that is 
privileged, confidential, and the 

Re: [MarkLogic Dev General] How to merge two json document in to another document in MarkLogic

2016-08-16 Thread Justin Makeig
What does is the merged document supposed to look like? What is the logic when 
key names collide? Last wins?

Justin

> On Aug 16, 2016, at 1:34 PM, Siva Viswabrahmana - Contractor 
>  wrote:
> 
> Hi,
> 
> /1.json:
> {“id”:”1”, “fname”:”Scott”}
> 
> /2.json:
> {“id”:”2”, “lname”:”McNelay”}
> 
> Hope this works.
> 
> —Siva.
> 
> From:  > on behalf of Justin Makeig 
> >
> Reply-To: MarkLogic Developer Discussion  >
> Date: Tuesday, August 16, 2016 at 4:31 PM
> To: MarkLogic Developer Discussion  >
> Subject: Re: [MarkLogic Dev General] How to merge two json document in to 
> another document in MarkLogic
> 
> Can you show an examples of 1.json, 2.json, and 12.json? It's unclear what 
> you mean by merge. 
> 
> Justin
> 
> --
> Justin Makeig
> Director, Product Management
> MarkLogic
> justin.mak...@marklogic.com 
> 
>> On Aug 16, 2016, at 1:19 PM, Siva Viswabrahmana - Contractor 
>> > wrote:
>> 
>> Hi,
>> I am trying to merge /1.json +/2.json into /12.json
>> 
>> Below query does not allow another document{…}
>> 
>> xdmp:document-insert("/test/2.json",document { doc("/test/1.json") 
>> },(),("aggregate")),
>> doc("/test/2.json”);
>> 
>> Pls advise.
>> 
>> Regards
>> Siva.
>> 
>> From: > > on behalf of Rob Szkutak 
>> >
>> Reply-To: MarkLogic Developer Discussion > >
>> Date: Tuesday, August 16, 2016 at 4:16 PM
>> To: MarkLogic Developer Discussion > >
>> Subject: Re: [MarkLogic Dev General] How to merge two json document in to 
>> another document in MarkLogic
>> 
>> Hello,
>> 
>> Could you be more specific about what you're trying to accomplish? A sample 
>> of the structure of your two documents and the merged format you would like 
>> to put them in would be helpful in understanding how to assist you.
>> 
>> Best,
>> Rob
>> 
>> Rob Szkutak
>> Senior Consultant
>> MarkLogic Corporation
>> rob.szku...@marklogic.com 
>> www.marklogic.com 
>> 
>> 
>> From: general-boun...@developer.marklogic.com 
>>  
>> [general-boun...@developer.marklogic.com 
>> ] on behalf of Siva 
>> Viswabrahmana - Contractor [siva.viswabrahm...@scdhhs.gov 
>> ]
>> Sent: Tuesday, August 16, 2016 3:11 PM
>> To: general@developer.marklogic.com 
>> Subject: [MarkLogic Dev General] How to merge two json document in to 
>> another document in MarkLogic
>> 
>> Hi,
>> How to merge two json document in to another document in MarkLogic?
>> 
>> Regards
>> Siva.
>> Confidentiality Note 
>> 
>> 
>> This message is intended for the use of the person or entity to which it is 
>> addressed and may contain information, including health information, that is 
>> privileged, confidential, and the disclosure of which is governed by 
>> applicable law. If the reader of this message is not the intended recipient, 
>> or the employee or agent responsible to deliver it to the intended 
>> recipient, you are hereby notified that any dissemination, distribution or 
>> copying of this information is STRICTLY PROHIBITED. 
>> 
>> If you have received this in error, please notify us immediately and destroy 
>> the related message.
>> Confidentiality Note 
>> 
>> 
>> This message is intended for the use of the person or entity to which it is 
>> addressed and may contain information, including health information, that is 
>> privileged, confidential, and the disclosure of which is governed by 
>> applicable law. If the reader of this message is not the intended recipient, 
>> or the employee or agent responsible to deliver it to the intended 
>> recipient, you are hereby notified that any dissemination, distribution or 
>> copying of this information is STRICTLY PROHIBITED. 
>> 
>> If you have received this in error, please notify us immediately and destroy 
>> the related message. ___
>> General mailing list
>> General@developer.marklogic.com 

Re: [MarkLogic Dev General] How to merge two json document in to another document in MarkLogic

2016-08-16 Thread Siva Viswabrahmana - Contractor
Hi,

/1.json:
{"id":"1", "fname":"Scott"}

/2.json:
{"id":"2", "lname":"McNelay"}

Hope this works.

-Siva.

From: 
>
 on behalf of Justin Makeig 
>
Reply-To: MarkLogic Developer Discussion 
>
Date: Tuesday, August 16, 2016 at 4:31 PM
To: MarkLogic Developer Discussion 
>
Subject: Re: [MarkLogic Dev General] How to merge two json document in to 
another document in MarkLogic

Can you show an examples of 1.json, 2.json, and 12.json? It's unclear what you 
mean by merge.

Justin

--
Justin Makeig
Director, Product Management
MarkLogic
justin.mak...@marklogic.com

On Aug 16, 2016, at 1:19 PM, Siva Viswabrahmana - Contractor 
> wrote:

Hi,
I am trying to merge /1.json +/2.json into /12.json

Below query does not allow another document{...}

xdmp:document-insert("/test/2.json",document { doc("/test/1.json") 
},(),("aggregate")),
doc("/test/2.json");

Pls advise.

Regards
Siva.

From: 
>
 on behalf of Rob Szkutak 
>
Reply-To: MarkLogic Developer Discussion 
>
Date: Tuesday, August 16, 2016 at 4:16 PM
To: MarkLogic Developer Discussion 
>
Subject: Re: [MarkLogic Dev General] How to merge two json document in to 
another document in MarkLogic

Hello,

Could you be more specific about what you're trying to accomplish? A sample of 
the structure of your two documents and the merged format you would like to put 
them in would be helpful in understanding how to assist you.

Best,
Rob

Rob Szkutak
Senior Consultant
MarkLogic Corporation
rob.szku...@marklogic.com
www.marklogic.com


From: 
general-boun...@developer.marklogic.com
 
[general-boun...@developer.marklogic.com]
 on behalf of Siva Viswabrahmana - Contractor 
[siva.viswabrahm...@scdhhs.gov]
Sent: Tuesday, August 16, 2016 3:11 PM
To: general@developer.marklogic.com
Subject: [MarkLogic Dev General] How to merge two json document in to another 
document in MarkLogic

Hi,
How to merge two json document in to another document in MarkLogic?

Regards
Siva.
Confidentiality Note


This message is intended for the use of the person or entity to which it is 
addressed and may contain information, including health information, that is 
privileged, confidential, and the disclosure of which is governed by applicable 
law. If the reader of this message is not the intended recipient, or the 
employee or agent responsible to deliver it to the intended recipient, you are 
hereby notified that any dissemination, distribution or copying of this 
information is STRICTLY PROHIBITED.

If you have received this in error, please notify us immediately and destroy 
the related message.
Confidentiality Note


This message is intended for the use of the person or entity to which it is 
addressed and may contain information, including health information, that is 
privileged, confidential, and the disclosure of which is governed by applicable 
law. If the reader of this message is not the intended recipient, or the 
employee or agent responsible to deliver it to the intended recipient, you are 
hereby notified that any dissemination, distribution or copying of this 
information is STRICTLY PROHIBITED.

If you have received this in error, please notify us immediately and destroy 
the related message. ___
General mailing list
General@developer.marklogic.com
Manage your subscription at:
http://developer.marklogic.com/mailman/listinfo/general

Confidentiality Note


This message is intended for the use of the person or entity to which it is 
addressed and may contain information, including health information, that is 
privileged, confidential, and the disclosure of which is governed by applicable 
law. If the reader of this message is not the intended recipient, or the 
employee or agent responsible to deliver it to the intended recipient, you are 
hereby notified that 

Re: [MarkLogic Dev General] MarkLogic vs CouchDB

2016-08-16 Thread Abhishek.Srivastav
Thank you!

From: general-boun...@developer.marklogic.com 
[mailto:general-boun...@developer.marklogic.com] On Behalf Of Gary Russo
Sent: Monday, August 15, 2016 7:23 PM
To: 'MarkLogic Developer Discussion'
Subject: Re: [MarkLogic Dev General] MarkLogic vs CouchDB

Be sure to see the trend chart. => 
http://db-engines.com/en/ranking_trend/system/CouchDB%3BMarkLogic


From: Gary Russo [mailto:garyru...@hotmail.com]
Sent: Monday, August 15, 2016 7:22 PM
To: 'MarkLogic Developer Discussion' 
>
Subject: RE: [MarkLogic Dev General] MarkLogic vs CouchDB

There's always db-engines.com => 
http://db-engines.com/en/system/CouchDB%3BMarkLogic


Gary Russo
http://garyrusso.wordpress.com


From: 
general-boun...@developer.marklogic.com
 [mailto:general-boun...@developer.marklogic.com] On Behalf Of 
abhishek.srivas...@cognizant.com
Sent: Monday, August 15, 2016 3:30 PM
To: general@developer.marklogic.com
Subject: Re: [MarkLogic Dev General] MarkLogic vs CouchDB

If you can include, ACID compliance, Search capabilities, Language supported, 
REST support, web compliance, security model.

From: 
general-boun...@developer.marklogic.com
 [mailto:general-boun...@developer.marklogic.com] On Behalf Of Pete Aven
Sent: Monday, August 15, 2016 11:32 AM
To: MarkLogic Developer Discussion
Subject: Re: [MarkLogic Dev General] MarkLogic vs CouchDB

I would start with: What's your use case sir?  Or what is your evaluation 
criteria? A technical comparison may be meaningless depending on what you're 
trying to do.

Pete


From: 
general-boun...@developer.marklogic.com
 [mailto:general-boun...@developer.marklogic.com] On Behalf Of 
abhishek.srivas...@cognizant.com
Sent: Friday, August 12, 2016 6:55 PM
To: general@developer.marklogic.com
Subject: [MarkLogic Dev General] MarkLogic vs CouchDB

Hi All,

Is there any comparison report between MarkLogic and CouchDB. I got something 
over web but seems to be an old one.

Thanks
Abhishek
This e-mail and any files transmitted with it are for the sole use of the 
intended recipient(s) and may contain confidential and privileged information. 
If you are not the intended recipient(s), please reply to the sender and 
destroy all copies of the original message. Any unauthorized review, use, 
disclosure, dissemination, forwarding, printing or copying of this email, 
and/or any action taken in reliance on the contents of this e-mail is strictly 
prohibited and may be unlawful. Where permitted by applicable law, this e-mail 
and other e-mail communications sent to and from Cognizant e-mail addresses may 
be monitored.
This e-mail and any files transmitted with it are for the sole use of the 
intended recipient(s) and may contain confidential and privileged information. 
If you are not the intended recipient(s), please reply to the sender and 
destroy all copies of the original message. Any unauthorized review, use, 
disclosure, dissemination, forwarding, printing or copying of this email, 
and/or any action taken in reliance on the contents of this e-mail is strictly 
prohibited and may be unlawful. Where permitted by applicable law, this e-mail 
and other e-mail communications sent to and from Cognizant e-mail addresses may 
be monitored.
This e-mail and any files transmitted with it are for the sole use of the 
intended recipient(s) and may contain confidential and privileged information. 
If you are not the intended recipient(s), please reply to the sender and 
destroy all copies of the original message. Any unauthorized review, use, 
disclosure, dissemination, forwarding, printing or copying of this email, 
and/or any action taken in reliance on the contents of this e-mail is strictly 
prohibited and may be unlawful. Where permitted by applicable law, this e-mail 
and other e-mail communications sent to and from Cognizant e-mail addresses may 
be monitored.
___
General mailing list
General@developer.marklogic.com
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] How to merge two json document in to another document in MarkLogic

2016-08-16 Thread Justin Makeig
Can you show an examples of 1.json, 2.json, and 12.json? It's unclear what you 
mean by merge. 

Justin

--
Justin Makeig
Director, Product Management
MarkLogic
justin.mak...@marklogic.com

> On Aug 16, 2016, at 1:19 PM, Siva Viswabrahmana - Contractor 
>  wrote:
> 
> Hi,
> I am trying to merge /1.json +/2.json into /12.json
> 
> Below query does not allow another document{…}
> 
> xdmp:document-insert("/test/2.json",document { doc("/test/1.json") 
> },(),("aggregate")),
> doc("/test/2.json”);
> 
> Pls advise.
> 
> Regards
> Siva.
> 
> From:  > on behalf of Rob Szkutak 
> >
> Reply-To: MarkLogic Developer Discussion  >
> Date: Tuesday, August 16, 2016 at 4:16 PM
> To: MarkLogic Developer Discussion  >
> Subject: Re: [MarkLogic Dev General] How to merge two json document in to 
> another document in MarkLogic
> 
> Hello,
> 
> Could you be more specific about what you're trying to accomplish? A sample 
> of the structure of your two documents and the merged format you would like 
> to put them in would be helpful in understanding how to assist you.
> 
> Best,
> Rob
> 
> Rob Szkutak
> Senior Consultant
> MarkLogic Corporation
> rob.szku...@marklogic.com 
> www.marklogic.com 
> 
> 
> From: general-boun...@developer.marklogic.com 
>  
> [general-boun...@developer.marklogic.com 
> ] on behalf of Siva 
> Viswabrahmana - Contractor [siva.viswabrahm...@scdhhs.gov 
> ]
> Sent: Tuesday, August 16, 2016 3:11 PM
> To: general@developer.marklogic.com 
> Subject: [MarkLogic Dev General] How to merge two json document in to another 
> document in MarkLogic
> 
> Hi,
> How to merge two json document in to another document in MarkLogic?
> 
> Regards
> Siva.
> Confidentiality Note 
> 
> 
> This message is intended for the use of the person or entity to which it is 
> addressed and may contain information, including health information, that is 
> privileged, confidential, and the disclosure of which is governed by 
> applicable law. If the reader of this message is not the intended recipient, 
> or the employee or agent responsible to deliver it to the intended recipient, 
> you are hereby notified that any dissemination, distribution or copying of 
> this information is STRICTLY PROHIBITED. 
> 
> If you have received this in error, please notify us immediately and destroy 
> the related message.
> Confidentiality Note 
> 
> 
> This message is intended for the use of the person or entity to which it is 
> addressed and may contain information, including health information, that is 
> privileged, confidential, and the disclosure of which is governed by 
> applicable law. If the reader of this message is not the intended recipient, 
> or the employee or agent responsible to deliver it to the intended recipient, 
> you are hereby notified that any dissemination, distribution or copying of 
> this information is STRICTLY PROHIBITED. 
> 
> If you have received this in error, please notify us immediately and destroy 
> the related message. ___
> General mailing list
> General@developer.marklogic.com 
> Manage your subscription at: 
> http://developer.marklogic.com/mailman/listinfo/general 
> 



smime.p7s
Description: S/MIME cryptographic signature
___
General mailing list
General@developer.marklogic.com
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] How to merge two json document in to another document in MarkLogic

2016-08-16 Thread Siva Viswabrahmana - Contractor
Hello,
Here is the error message

[1.0-ml] XDMP-MULTIROOT: 
xdmp:eval("xdmp:document-insert(/test/2.json,document { 
do...", (), 67298589469402xxx828745814253491...)
 -- Document nodes cannot have multiple roots

-Siva.

From: 
>
 on behalf of Rob Szkutak 
>
Reply-To: MarkLogic Developer Discussion 
>
Date: Tuesday, August 16, 2016 at 4:28 PM
To: MarkLogic Developer Discussion 
>
Subject: Re: [MarkLogic Dev General] How to merge two json document in to 
another document in MarkLogic

Hello,

I did a couple quick tests and offhand your document insertion looks like it 
would work.

Could you share the full error message you're seeing?

Best,
Rob

Rob Szkutak
Senior Consultant
MarkLogic Corporation
rob.szku...@marklogic.com
www.marklogic.com


From: 
general-boun...@developer.marklogic.com
 
[general-boun...@developer.marklogic.com]
 on behalf of Siva Viswabrahmana - Contractor 
[siva.viswabrahm...@scdhhs.gov]
Sent: Tuesday, August 16, 2016 3:19 PM
To: MarkLogic Developer Discussion
Subject: Re: [MarkLogic Dev General] How to merge two json document in to 
another document in MarkLogic

Hi,
I am trying to merge /1.json +/2.json into /12.json

Below query does not allow another document{...}


xdmp:document-insert("/test/2.json",document { doc("/test/1.json") 
},(),("aggregate")),

doc("/test/2.json");


Pls advise.


Regards

Siva.

From: 
>
 on behalf of Rob Szkutak 
>
Reply-To: MarkLogic Developer Discussion 
>
Date: Tuesday, August 16, 2016 at 4:16 PM
To: MarkLogic Developer Discussion 
>
Subject: Re: [MarkLogic Dev General] How to merge two json document in to 
another document in MarkLogic

Hello,

Could you be more specific about what you're trying to accomplish? A sample of 
the structure of your two documents and the merged format you would like to put 
them in would be helpful in understanding how to assist you.

Best,
Rob

Rob Szkutak
Senior Consultant
MarkLogic Corporation
rob.szku...@marklogic.com
www.marklogic.com


From:general-boun...@developer.marklogic.com
 
[general-boun...@developer.marklogic.com]
 on behalf of Siva Viswabrahmana - Contractor 
[siva.viswabrahm...@scdhhs.gov]
Sent: Tuesday, August 16, 2016 3:11 PM
To: general@developer.marklogic.com
Subject: [MarkLogic Dev General] How to merge two json document in to another 
document in MarkLogic

Hi,
How to merge two json document in to another document in MarkLogic?

Regards
Siva.
Confidentiality Note


This message is intended for the use of the person or entity to which it is 
addressed and may contain information, including health information, that is 
privileged, confidential, and the disclosure of which is governed by applicable 
law. If the reader of this message is not the intended recipient, or the 
employee or agent responsible to deliver it to the intended recipient, you are 
hereby notified that any dissemination, distribution or copying of this 
information is STRICTLY PROHIBITED.

If you have received this in error, please notify us immediately and destroy 
the related message.
Confidentiality Note


This message is intended for the use of the person or entity to which it is 
addressed and may contain information, including health information, that is 
privileged, confidential, and the disclosure of which is governed by applicable 
law. If the reader of this message is not the intended recipient, or the 
employee or agent responsible to deliver it to the intended recipient, you are 
hereby notified that any dissemination, distribution or copying of this 

Re: [MarkLogic Dev General] How to merge two json document in to another document in MarkLogic

2016-08-16 Thread Rob Szkutak
Hello,

I did a couple quick tests and offhand your document insertion looks like it 
would work.

Could you share the full error message you're seeing?

Best,
Rob

Rob Szkutak
Senior Consultant
MarkLogic Corporation
rob.szku...@marklogic.com
www.marklogic.com


From: general-boun...@developer.marklogic.com 
[general-boun...@developer.marklogic.com] on behalf of Siva Viswabrahmana - 
Contractor [siva.viswabrahm...@scdhhs.gov]
Sent: Tuesday, August 16, 2016 3:19 PM
To: MarkLogic Developer Discussion
Subject: Re: [MarkLogic Dev General] How to merge two json document in to 
another document in MarkLogic

Hi,
I am trying to merge /1.json +/2.json into /12.json

Below query does not allow another document{…}


xdmp:document-insert("/test/2.json",document { doc("/test/1.json") 
},(),("aggregate")),

doc("/test/2.json”);


Pls advise.


Regards

Siva.

From: 
>
 on behalf of Rob Szkutak 
>
Reply-To: MarkLogic Developer Discussion 
>
Date: Tuesday, August 16, 2016 at 4:16 PM
To: MarkLogic Developer Discussion 
>
Subject: Re: [MarkLogic Dev General] How to merge two json document in to 
another document in MarkLogic

Hello,

Could you be more specific about what you're trying to accomplish? A sample of 
the structure of your two documents and the merged format you would like to put 
them in would be helpful in understanding how to assist you.

Best,
Rob

Rob Szkutak
Senior Consultant
MarkLogic Corporation
rob.szku...@marklogic.com
www.marklogic.com


From: 
general-boun...@developer.marklogic.com
 
[general-boun...@developer.marklogic.com]
 on behalf of Siva Viswabrahmana - Contractor 
[siva.viswabrahm...@scdhhs.gov]
Sent: Tuesday, August 16, 2016 3:11 PM
To: general@developer.marklogic.com
Subject: [MarkLogic Dev General] How to merge two json document in to another 
document in MarkLogic

Hi,
How to merge two json document in to another document in MarkLogic?

Regards
Siva.
Confidentiality Note


This message is intended for the use of the person or entity to which it is 
addressed and may contain information, including health information, that is 
privileged, confidential, and the disclosure of which is governed by applicable 
law. If the reader of this message is not the intended recipient, or the 
employee or agent responsible to deliver it to the intended recipient, you are 
hereby notified that any dissemination, distribution or copying of this 
information is STRICTLY PROHIBITED.

If you have received this in error, please notify us immediately and destroy 
the related message.
Confidentiality Note


This message is intended for the use of the person or entity to which it is 
addressed and may contain information, including health information, that is 
privileged, confidential, and the disclosure of which is governed by applicable 
law. If the reader of this message is not the intended recipient, or the 
employee or agent responsible to deliver it to the intended recipient, you are 
hereby notified that any dissemination, distribution or copying of this 
information is STRICTLY PROHIBITED.

If you have received this in error, please notify us immediately and destroy 
the related message.
___
General mailing list
General@developer.marklogic.com
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] How to merge two json document in to another document in MarkLogic

2016-08-16 Thread Siva Viswabrahmana - Contractor
Hi,
I am trying to merge /1.json +/2.json into /12.json

Below query does not allow another document{...}


xdmp:document-insert("/test/2.json",document { doc("/test/1.json") 
},(),("aggregate")),

doc("/test/2.json");


Pls advise.


Regards

Siva.

From: 
>
 on behalf of Rob Szkutak 
>
Reply-To: MarkLogic Developer Discussion 
>
Date: Tuesday, August 16, 2016 at 4:16 PM
To: MarkLogic Developer Discussion 
>
Subject: Re: [MarkLogic Dev General] How to merge two json document in to 
another document in MarkLogic

Hello,

Could you be more specific about what you're trying to accomplish? A sample of 
the structure of your two documents and the merged format you would like to put 
them in would be helpful in understanding how to assist you.

Best,
Rob

Rob Szkutak
Senior Consultant
MarkLogic Corporation
rob.szku...@marklogic.com
www.marklogic.com


From: 
general-boun...@developer.marklogic.com
 
[general-boun...@developer.marklogic.com]
 on behalf of Siva Viswabrahmana - Contractor 
[siva.viswabrahm...@scdhhs.gov]
Sent: Tuesday, August 16, 2016 3:11 PM
To: general@developer.marklogic.com
Subject: [MarkLogic Dev General] How to merge two json document in to another 
document in MarkLogic

Hi,
How to merge two json document in to another document in MarkLogic?

Regards
Siva.
Confidentiality Note


This message is intended for the use of the person or entity to which it is 
addressed and may contain information, including health information, that is 
privileged, confidential, and the disclosure of which is governed by applicable 
law. If the reader of this message is not the intended recipient, or the 
employee or agent responsible to deliver it to the intended recipient, you are 
hereby notified that any dissemination, distribution or copying of this 
information is STRICTLY PROHIBITED.

If you have received this in error, please notify us immediately and destroy 
the related message.
Confidentiality Note


This message is intended for the use of the person or entity to which it is 
addressed and may contain information, including health information, that is 
privileged, confidential, and the disclosure of which is governed by applicable 
law. If the reader of this message is not the intended recipient, or the 
employee or agent responsible to deliver it to the intended recipient, you are 
hereby notified that any dissemination, distribution or copying of this 
information is STRICTLY PROHIBITED.

If you have received this in error, please notify us immediately and destroy 
the related message.
___
General mailing list
General@developer.marklogic.com
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] How to merge two json document in to another document in MarkLogic

2016-08-16 Thread Rob Szkutak
Hello,

Could you be more specific about what you're trying to accomplish? A sample of 
the structure of your two documents and the merged format you would like to put 
them in would be helpful in understanding how to assist you.

Best,
Rob

Rob Szkutak
Senior Consultant
MarkLogic Corporation
rob.szku...@marklogic.com
www.marklogic.com


From: general-boun...@developer.marklogic.com 
[general-boun...@developer.marklogic.com] on behalf of Siva Viswabrahmana - 
Contractor [siva.viswabrahm...@scdhhs.gov]
Sent: Tuesday, August 16, 2016 3:11 PM
To: general@developer.marklogic.com
Subject: [MarkLogic Dev General] How to merge two json document in to another 
document in MarkLogic

Hi,
How to merge two json document in to another document in MarkLogic?

Regards
Siva.
Confidentiality Note


This message is intended for the use of the person or entity to which it is 
addressed and may contain information, including health information, that is 
privileged, confidential, and the disclosure of which is governed by applicable 
law. If the reader of this message is not the intended recipient, or the 
employee or agent responsible to deliver it to the intended recipient, you are 
hereby notified that any dissemination, distribution or copying of this 
information is STRICTLY PROHIBITED.

If you have received this in error, please notify us immediately and destroy 
the related message.
___
General mailing list
General@developer.marklogic.com
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] Looking for a Polymer/nodejs component for MarkLogic application level login/logout

2016-08-16 Thread Geert Josten
To what extend is it failing for you?

From: 
>
 on behalf of Loren Cahlander 
>
Reply-To: MarkLogic Developer Discussion 
>
Date: Tuesday, August 16, 2016 at 1:59 PM
To: MarkLogic Developer Discussion 
>
Subject: [MarkLogic Dev General] Looking for a Polymer/nodejs component for 
MarkLogic application level login/logout

Has anyone looked into creating a polymer component using Node.js for MarkLogic 
login?

Here is an example of a polymer webpage with a login panel.





Easy Meta Hub













.centered {
  min-width: calc(100% - 200px);
}

paper-toolbar paper-progress {
  --paper-progress-active-color: var(--accent-color);
}

.spacer {
  @apply(--layout-flex);
}
  #login {
margin: 0;
  }

  




Easy Meta Hub




Login





Cancel
Submit




  function openBy(element) {
login.positionTarget = element;
login.open();
  }




Thanks,

Loren
___
General mailing list
General@developer.marklogic.com
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general


[MarkLogic Dev General] How to merge two json document in to another document in MarkLogic

2016-08-16 Thread Siva Viswabrahmana - Contractor
Hi,
How to merge two json document in to another document in MarkLogic?

Regards
Siva.
Confidentiality Note


This message is intended for the use of the person or entity to which it is 
addressed and may contain information, including health information, that is 
privileged, confidential, and the disclosure of which is governed by applicable 
law. If the reader of this message is not the intended recipient, or the 
employee or agent responsible to deliver it to the intended recipient, you are 
hereby notified that any dissemination, distribution or copying of this 
information is STRICTLY PROHIBITED.

If you have received this in error, please notify us immediately and destroy 
the related message.
___
General mailing list
General@developer.marklogic.com
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] cts:element-values() issue

2016-08-16 Thread Yalaverthi, Sudheer (LNG-RDU)
I have multiple grade elements. Ignore this thread.

From: general-boun...@developer.marklogic.com 
[mailto:general-boun...@developer.marklogic.com] On Behalf Of Rob Szkutak
Sent: Tuesday, August 16, 2016 3:47 PM
To: MarkLogic Developer Discussion 
Subject: Re: [MarkLogic Dev General] cts:element-values() issue

Hello,

Do you have multiple  elements in some of your documents? That could 
explain why you're seeing more results beyond A, B and C.

If you can't filter your results from element-values correctly, another way to 
filter those out of your result set may be to add a "where" before your return:

where $grade eq 'A' or $grade eq 'B' or $grade eq 'C'

Best,
Rob

Rob Szkutak
Senior Consultant
MarkLogic Corporation
rob.szku...@marklogic.com
www.marklogic.com


From: 
general-boun...@developer.marklogic.com
 [general-boun...@developer.marklogic.com] on behalf of Yalaverthi, Sudheer 
(LNG-RDU) [sudheer.yalaver...@lexisnexis.com]
Sent: Tuesday, August 16, 2016 2:33 PM
To: general@developer.marklogic.com
Subject: [MarkLogic Dev General] cts:element-values() issue
Hi,


I have some data with the below format.


Mark
A
2016


I need to find out in between 2011 to 2016, how many students got grade A, how 
many got grade B, how many got grade C.

I initially wrote a query like this.


xquery version "1.0-ml";
declare namespace html = "http://www.w3.org/1999/xhtml;;

for $grade in
cts:element-values(
  xs:QName('grade'),
  (),
  ("frequency-order"),
  cts:and-query((
cts:element-range-query(xs:QName('year'), '>=', xs:int(2011)),
cts:element-range-query(xs:QName('year'), '<=', xs:int(2016)),
cts:element-range-query(xs:QName('grade'), '=', ('A', 'B', 'C'))
  ))
)
 return concat("grade :", $grade, " students with this grade :" , 
cts:frequency($grade))




I was expecting only grade A, B and C in the output but to my surprise, I am 
getting other grades as well like D, E, F and so on.

What am I missing here and is there any efficient way to achieve this? I have 
around 160 million records.


-Sudheer
___
General mailing list
General@developer.marklogic.com
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] cts:element-values() issue

2016-08-16 Thread Rob Szkutak
Hello,

Do you have multiple  elements in some of your documents? That could 
explain why you're seeing more results beyond A, B and C.

If you can't filter your results from element-values correctly, another way to 
filter those out of your result set may be to add a "where" before your return:

where $grade eq 'A' or $grade eq 'B' or $grade eq 'C'

Best,
Rob

Rob Szkutak
Senior Consultant
MarkLogic Corporation
rob.szku...@marklogic.com
www.marklogic.com


From: general-boun...@developer.marklogic.com 
[general-boun...@developer.marklogic.com] on behalf of Yalaverthi, Sudheer 
(LNG-RDU) [sudheer.yalaver...@lexisnexis.com]
Sent: Tuesday, August 16, 2016 2:33 PM
To: general@developer.marklogic.com
Subject: [MarkLogic Dev General] cts:element-values() issue

Hi,


I have some data with the below format.


Mark
A
2016


I need to find out in between 2011 to 2016, how many students got grade A, how 
many got grade B, how many got grade C.

I initially wrote a query like this.


xquery version "1.0-ml";
declare namespace html = "http://www.w3.org/1999/xhtml;;

for $grade in
cts:element-values(
  xs:QName(‘grade’),
  (),
  (“frequency-order”),
  cts:and-query((
cts:element-range-query(xs:QName('year'), '>=', xs:int(2011)),
cts:element-range-query(xs:QName('year'), '<=', xs:int(2016)),
cts:element-range-query(xs:QName('grade'), '=', ('A', 'B', 'C'))
  ))
)
 return concat("grade :", $grade, " students with this grade :" , 
cts:frequency($grade))




I was expecting only grade A, B and C in the output but to my surprise, I am 
getting other grades as well like D, E, F and so on.

What am I missing here and is there any efficient way to achieve this? I have 
around 160 million records.


-Sudheer
___
General mailing list
General@developer.marklogic.com
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general


[MarkLogic Dev General] cts:element-values() issue

2016-08-16 Thread Yalaverthi, Sudheer (LNG-RDU)
Hi,


I have some data with the below format.


Mark
A
2016


I need to find out in between 2011 to 2016, how many students got grade A, how 
many got grade B, how many got grade C.

I initially wrote a query like this.


xquery version "1.0-ml";
declare namespace html = "http://www.w3.org/1999/xhtml;;

for $grade in
cts:element-values(
  xs:QName('grade'),
  (),
  ("frequency-order"),
  cts:and-query((
cts:element-range-query(xs:QName('year'), '>=', xs:int(2011)),
cts:element-range-query(xs:QName('year'), '<=', xs:int(2016)),
cts:element-range-query(xs:QName('grade'), '=', ('A', 'B', 'C'))
  ))
)
 return concat("grade :", $grade, " students with this grade :" , 
cts:frequency($grade))




I was expecting only grade A, B and C in the output but to my surprise, I am 
getting other grades as well like D, E, F and so on.

What am I missing here and is there any efficient way to achieve this? I have 
around 160 million records.


-Sudheer
___
General mailing list
General@developer.marklogic.com
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general