| Author | Message | 
		
		  | RAJESHRAMAKRISHNAN | 
			  
				|  Posted: Thu Aug 24, 2006 9:11 am    Post subject: Multipart message - Help |   |  | 
		
		  | Voyager
 
 
 Joined: 01 May 2004Posts: 96
 
 
 | 
			  
				| I have the following two XML messages: 
 1.
 
 <ROOT1>
 <MessageBlock>
 Sample
 </messageBlock>
 </ROOT1>
 
 2.
 
 I now want to embed the 1st message in to a second message as follows
 <ROOT2>
 <Envelope>
 <ROOT1>
 <MessageBlock>
 Sample
 </messageBlock>
 </ROOT1>
 </Envelope>
 </ROOT2>
 
 To achieve this I have developed two message sets with the 2nd one having the 1st one as a multipart message.
 
 But I don't have any idea as to how to generate the second message using ESQL. Please let me know how to create the second message using ESQL code. Thanks in advance
 |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | special_agent_Queue | 
			  
				|  Posted: Thu Aug 24, 2006 9:25 am    Post subject: |   |  | 
		
		  |  Centurion
 
 
 Joined: 27 Jul 2006Posts: 102
 
 
 | 
			  
				| if it's xml you shouldn't need message sets. 
 all you need to do is start building a normal 2nd xml message, and then copy the first message into the 2nd message at the appropriate tag.
 |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | madi | 
			  
				|  Posted: Thu Aug 24, 2006 10:01 am    Post subject: |   |  | 
		
		  |  Chevalier
 
 
 Joined: 17 Jan 2006Posts: 475
 
 
 | 
			  
				| sounds easy to me ..... did you try something and failed?? 
 post your code if you have any
   
 --madi
 |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | special_agent_Queue | 
			  
				|  Posted: Thu Aug 24, 2006 10:07 am    Post subject: |   |  | 
		
		  |  Centurion
 
 
 Joined: 27 Jul 2006Posts: 102
 
 
 | 
			  
				| unless you are generating both, and the first message is not an input message.  when it's not an input message, you can just make it like you would make a normal xml message. |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | madi | 
			  
				|  Posted: Thu Aug 24, 2006 10:09 am    Post subject: |   |  | 
		
		  |  Chevalier
 
 
 Joined: 17 Jan 2006Posts: 475
 
 
 | 
			  
				| 
   
	| ahmeeeekaSet wrote: |  
	| unless you are generating both, and the first message is not an input message. |  
 whats the complication if you are generating both??
 
 --madi
 |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | special_agent_Queue | 
			  
				|  Posted: Thu Aug 24, 2006 11:44 am    Post subject: |   |  | 
		
		  |  Centurion
 
 
 Joined: 27 Jul 2006Posts: 102
 
 
 | 
			  
				| There isn't.  It makes it simpler, at least in my opinion. |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | kimbert | 
			  
				|  Posted: Thu Aug 24, 2006 3:06 pm    Post subject: |   |  | 
		
		  |  Jedi Council
 
 
 Joined: 29 Jul 2003Posts: 5543
 Location: Southampton
 
 | 
			  
				| 
  Forget about the multipart idea, unless you are going to transform to a non-XML format. Just create a message tree with the correct structure, same as you would normally. 
	| Quote: |  
	| Please let me know how to create the second message using ESQL code. |  |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | RAJESHRAMAKRISHNAN | 
			  
				|  Posted: Thu Aug 24, 2006 7:38 pm    Post subject: |   |  | 
		
		  | Voyager
 
 
 Joined: 01 May 2004Posts: 96
 
 
 | 
			  
				| Hi Guys, 
 Thanks for all the response. I know that this can be easily achieved by using a simple XML transformation. But I am learning Multipart messages hence I need your help.
 
 Please help me to acheive this using Multipart  message sets and ESQL.
 
 Thanks very much
 |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | kimbert | 
			  
				|  Posted: Fri Aug 25, 2006 1:46 am    Post subject: |   |  | 
		
		  |  Jedi Council
 
 
 Joined: 29 Jul 2003Posts: 5543
 Location: Southampton
 
 | 
			  
				| 
  Just create an MRM tree with the correct structure. It doesn't make any difference whether the message set contains multipart messages - the MRM parser handles all those details for you. 
	| Quote: |  
	| Please help me to acheive this using Multipart message sets and ESQL |  |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | special_agent_Queue | 
			  
				|  Posted: Fri Aug 25, 2006 4:58 am    Post subject: |   |  | 
		
		  |  Centurion
 
 
 Joined: 27 Jul 2006Posts: 102
 
 
 | 
			  
				| RAJESHRAMAKRISHNAN, If I gave you an XML message that looked like this:
 <Transaction>
 <Deposit>
 <AccountNum>Sample</AccountNum>
 </Deposit>
 </Transaction>
 
 What would the ESQL be to create this?
 
 Now take that ESQL and use it for
 <ROOT2>
 <Envelope>
 <ROOT1>
 <MessageBlock>
 Sample
 </messageBlock>
 </ROOT1>
 </Envelope>
 </ROOT2>
 
 When using an embedded multipart message with XML, it does not matter to you that it is multipart.  You just create the XML message the same way as always.
 |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | madi | 
			  
				|  Posted: Fri Aug 25, 2006 6:37 am    Post subject: |   |  | 
		
		  |  Chevalier
 
 
 Joined: 17 Jan 2006Posts: 475
 
 
 | 
			  
				| man ....... your just wasting your time posting here without trying anything ....... first try something and if it does not work . post the problems and your code ....... then and then only will you get anything out of this forum 
 otherwise its just discussion about  ideas that come into our minds
  and it will not make any sense to you 
 now as i see it ...... you are just confusing yourself with all the multipart stuff
 
 just take it easy and write some code and im sure you will get what you want
 
   
 and one more thing ........ be a little more active on the forum ...... most probably you will get replies immediately ...... so keep checking the forum for replies regularly
 
 --madi
 |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | RAJESHRAMAKRISHNAN | 
			  
				|  Posted: Sun Aug 27, 2006 9:00 pm    Post subject: |   |  | 
		
		  | Voyager
 
 
 Joined: 01 May 2004Posts: 96
 
 
 | 
			  
				| Hi Madi, 
 Thanks for your "Polite Answer". I can't understand how you can assume that people are not trying anything before posting here. There was a problem in the message set that I fixed (Something simple).
 
 One last advice to you -
 
 People can be busy or unwell at times for them to be  be a little more "active on the forum ...... " so I request you not to assume things.
 
 Thanks every one for the help.
 
 Thanks
 Rajesh
 |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  |  |