Toad World® Forums

Automation - How to concatenate multiple queries

I have multiple automation scripts that use export wizard to save results of queries in Excel output files.

At present, I have to open and run each one in sequence. They work fine.

I would like to be able to merge the 7 scripts into a single script. The run a single script that executes each query, saves the result to Excel and executes the following queries in sequence.

Since you already have automation jobs set up for each query, you can call each job with a Run Automation step. Basically you can create a master job that runs all the other jobs in the sequence you want. There were some bugs in the past that let the job skip run automation steps where it would perform the 1st one and skip one or more following steps with no error generated. I have not tried this in 3.5 yet, hopefully it is fixed.

Dumb question here – how do I create a ‘master job’?

From: GregDavis11009 [mailto:bounce-GregDavis11009@toadworld.com]

Sent: Thursday, September 04, 2014 11:10 AM

To: toaddatapoint@toadworld.com

Subject: RE: [Toad Data Point - Discussion Forum] Automation - How to concatenate multiple queries

RE: Automation - How to concatenate multiple queries

Reply by GregDavis11009

Since you already have automation jobs set up for each query, you can call each job with a Run Automation step. Basically you can create a master job that runs all the other jobs in the sequence
you want. There were some bugs in the past that let the job skip run automation steps where it would perform the 1st one and skip one or more following steps with no error generated. I have not tried this in 3.5 yet, hopefully it is fixed.

To reply, please reply-all to this email.

Stop receiving emails on this subject.

Or
Unsubscribe from Toad Data Point - General
notifications altogether.

Toad Data Point - Discussion Forum

Flag
this post as spam/abuse.

The same as any other automation job, but in this one you will have Run Automation Script steps that will call the other automation jobs you have already created in the order you want. One automation job that runs the other jobs (the master job). This allows you to run them all (via the master job) or run them individually. See image

What do I do with the Return Code?

From: GregDavis11009 [mailto:bounce-GregDavis11009@toadworld.com]

Sent: Thursday, September 04, 2014 11:47 AM

To: toaddatapoint@toadworld.com

Subject: RE: [Toad Data Point - Discussion Forum] Automation - How to concatenate multiple queries

RE: Automation - How to concatenate multiple queries

Reply by GregDavis11009

The same as any other automation job, but in this one you will have Run Automation Script steps that will call the other automation jobs you have already created in the order you want. One
automation job that runs the other jobs (the master job). This allows you to run them all (via the master job) or run them individually. See image

To reply, please reply-all to this email.

Stop receiving emails on this subject.

Or
Unsubscribe from Toad Data Point - General
notifications altogether.

Toad Data Point - Discussion Forum

Flag
this post as spam/abuse.

Nothing, unless you want to trap errors. You can set any step in automation to continue on error (instead of stopping the job) and then put in a conditional
step that looks at the return code value and takes action based on that value (0=normal completion, non-zero values have different error meanings that you can take different actions on).

Greg

From: jaya.sinnathamby [mailto:bounce-jayasinnathamby@toadworld.com]

Sent: Thursday, September 04, 2014 9:51 AM

To: toaddatapoint@toadworld.com

Subject: RE: [Toad Data Point - Discussion Forum] Automation - How to concatenate multiple queries

RE: Automation - How to concatenate multiple queries

Reply by jaya.sinnathamby

What do I do with the Return Code?

From: GregDavis11009 [mailto:bounce-GregDavis11009@toadworld.com]

Sent: Thursday, September 04, 2014 11:47 AM

To: toaddatapoint@toadworld.com

Subject: RE: [Toad Data Point - Discussion Forum] Automation - How to concatenate multiple queries

RE: Automation - How to concatenate multiple queries

Reply by GregDavis11009

The same as any other automation job, but in this one you will have Run Automation Script steps that will call the other automation jobs you have already created in the order you want. One
automation job that runs the other jobs (the master job). This allows you to run them all (via the master job) or run them individually. See image

To reply, please reply-all to this email.

Stop receiving emails on this subject.

Or
Unsubscribe from Toad Data Point - General
notifications altogether.

Toad Data Point - Discussion Forum

Flag
this post as spam/abuse.

To reply, please reply-all to this email.

Stop receiving emails on this subject.

Or
Unsubscribe from Toad Data Point - General
notifications altogether.

Toad Data Point - Discussion Forum

Flag
this post as spam/abuse.

Thanks.

Will try it soon.

Jaya

From: GregDavis11009 [mailto:bounce-GregDavis11009@toadworld.com]

Sent: Thursday, September 04, 2014 12:03 PM

To: toaddatapoint@toadworld.com

Subject: RE: [Toad Data Point - Discussion Forum] Automation - How to concatenate multiple queries

RE: Automation - How to concatenate multiple queries

Reply by GregDavis11009

Nothing, unless you want to trap errors. You can set any step in automation to continue on error (instead of stopping the job) and then put in a conditional
step that looks at the return code value and takes action based on that value (0=normal completion, non-zero values have different error meanings that you can take different actions on).

Greg

From: jaya.sinnathamby [mailto:bounce-jayasinnathamby@toadworld.com]

Sent: Thursday, September 04, 2014 9:51 AM

To: toaddatapoint@toadworld.com

Subject: RE: [Toad Data Point - Discussion Forum] Automation - How to concatenate multiple queries

RE: Automation - How to concatenate multiple queries

Reply by jaya.sinnathamby

What do I do with the Return Code?

From: GregDavis11009 [mailto:bounce-GregDavis11009@toadworld.com]

Sent: Thursday, September 04, 2014 11:47 AM

To: toaddatapoint@toadworld.com

Subject: RE: [Toad Data Point - Discussion Forum] Automation - How to concatenate multiple queries

RE: Automation - How to concatenate multiple queries

Reply by GregDavis11009

The same as any other automation job, but in this one you will have Run Automation Script steps that will call the other automation jobs you have already created in the order you want. One
automation job that runs the other jobs (the master job). This allows you to run them all (via the master job) or run them individually. See image

To reply, please reply-all to this email.

Stop receiving emails on this subject.

Or
Unsubscribe from Toad Data Point - General
notifications altogether.

Toad Data Point - Discussion Forum

Flag
this post as spam/abuse.

To reply, please reply-all to this email.

Stop receiving emails on this subject.

Or
Unsubscribe from Toad Data Point - General
notifications altogether.

Toad Data Point - Discussion Forum

Flag
this post as spam/abuse.

To reply, please reply-all to this email.

Stop receiving emails on this subject.

Or
Unsubscribe from Toad Data Point - General
notifications altogether.

Toad Data Point - Discussion Forum

Flag
this post as spam/abuse.