how to combine 3 xlst into 1 xslt

Hi,

Please find the attachments,
Here to run my application the same input file I’m giving 3 times to application as step1 step2 step3[environment: spring batch].
Which is now taking more time…? How can I merge these three steps into a single step.
Currently  
Step1 I’m using DB and converting some amounts
Step2 using these db data I’m aggregating
Step3 using db data and step2 aggregated data
conversion.JPG
conversion1.JPG
nkk1712Asked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Gertone (Geert Bormans)Information ArchitectCommented:
Don't you think this is a little vague as a question?

If this is a pipeline you are setting up, please realize that sometimes it is good to have a series of simple XSLTs instead of one complex.
But from the information you give I know nothing.
I can't relate the images you show to XSLT functionality.

So, you need to give more info.
What are the XSLTs doing. How is the process now (a pipeline or three parallel transforms, if the later, how do you merge the result data)

nkk1712Author Commented:
Okay …
I know it’s difficult to understand. But I’ll try.

I’m having input *.xml file [150-160 files 1.64 GB] for each step will I  have run all these input xml files
Here I observed one thing, my logic part what I showed in images is taking very less time, the most  time is taken for coping rest of part. Somehow if I change these 3 steps into one step then I can get what I’m looking at.
Anyway
In step1
           I’m converting amounts using DB
            USD to EUR
            GBP to USD
In Step2
      I’m aggregating these converted amounts for specific codes
In Step3
      I’m using these aggregation amounts

here for each step i am using one xslt, please find the attachment

conver.ppt
Gertone (Geert Bormans)Information ArchitectCommented:
So you are pipelining
Much of the time will be lost in accessing the files and building the tree models.
So there is indeed a good chance that you will need less time when the three XSLT's are combined into one
How that needs to be done depends on the XSLTs itself... please share

There is a second optimisation.
If you could use XSLT2, you could access all the files as one collection
Then you only need one transform, meaning you only need to launch the JavaVM once for the entire set

So, XSLTs please, a source XML example and an answer to the question: "can you use Saxon 9.3 for XSLT2?"

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Microsoft Azure 2017

Azure has a changed a lot since it was originally introduce by adding new services and features. Do you know everything you need to about Azure? This course will teach you about the Azure App Service, monitoring and application insights, DevOps, and Team Services.

nkk1712Author Commented:
sorry :)  i can not share my xslt files

im using Saxon 9.0.0.5
my environment java, spring-batch, hibernate,jpa.

can you tell me the second one , with an example.
Gertone (Geert Bormans)Information ArchitectCommented:
You ask on an open forum to help you integrate 3 XSLTs into 1 XSLT
and then you can't share the XSLTs???

Well, strange indeed, then I can't share my solution for this :-)

As an independent consultant I imply non disclosure with everything that is sent to me.
Maybe you can email the XSLTs, so I can look at them and still keep them confident
(email address in my profile)

about dealing with the 160 files in one go try this

<xsl:for-each select="collection('file:///c:/source-dir/?select=*.xml')">
  <!-- apply templates here, with a mode for the processing of the file -->
</xsl:for-each>

use result document for writing to a file with the same name in a different location

Best is to integrate the processing of the three XSLT whilst you walk the tree, if possible.
If that is not possible, you can always store the result of an XSLT in a variable and apply-template that variable to the next mode
For that you need to carefully add modes to each template

Make sure XSLT version is set to 2.0 for all of this

Can I suggest that you upgrade saxon by the way?

This is as far as I can go without seeing teh XSLTs
nkk1712Author Commented:
I've requested that this question be deleted for the following reason:

i can not share &nbsp;the xslt doc
Gertone (Geert Bormans)Information ArchitectCommented:
advice was given on how to solve this.
I consider the question answered.
Deletion is not an option
Gertone (Geert Bormans)Information ArchitectCommented:
closing recommendations:
accept: http://www.experts-exchange.com/Web_Development/Web_Languages-Standards/XML/XPath/Q_27342994.html#a36709535
assist: http://www.experts-exchange.com/Web_Development/Web_Languages-Standards/XML/XPath/Q_27342994.html#a36708573

In my latest answer (suggested for accept)
I explain the process of integration plus the process of pulling multiple source files at the time.
More detail can not be given due to lack of the original XSLT.
The original question is answered as good as possible lacking further input from the question poster
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Web Languages and Standards

From novice to tech pro — start learning today.