Page 1 of 1

List Server, Parallel and Sequence jobs in 7.5.1

Posted: Fri Dec 23, 2011 2:10 pm
by I_Server_Whale
Hi all,

Trying to get the list of server jobs in a project from uvsh but having a tough time understanding the results. Although the project has 0 server jobs, the below query returns 13 as the output. Am I going wrong with the UV query?

Code: Select all

>PTERM CASE NOINVERT

>LOGTO taxprd

>SELECT 'Server:',COUNT(*) FMT '10L' FROM DS_JOBS WHERE JOBTYPE='0' COL.SUP COUNT.SUP COL.SPCS 0;

Compiling "JOBTYPE".

IF JOBTYPEIND =  THEN 0 ELSE JOBTYPEIND

  

Server:13

or same result with

Code: Select all

>PTERM CASE NOINVERT

>LOGTO taxprd

>SELECT 'Server:',COUNT(*) FMT '10L' FROM DS_JOBS WHERE JOBTYPE='0';

Compiling "JOBTYPE".

IF JOBTYPEIND =  THEN 0 ELSE JOBTYPEIND

 


Server:13

Any help or inputs are greatly appreciated.

Best Regards,

Posted: Fri Dec 23, 2011 2:27 pm
by chulett
Run it without the count and see what those 13 rows look like.

Posted: Fri Dec 23, 2011 3:11 pm
by I_Server_Whale
Haa! It returns the folders:

Code: Select all

>LOGTO ds_tutorial
>SELECT * FROM DS_JOBS WHERE JOBTYPE='0';


Job name.... \\\
Description.
No..........
Category....

Job name.... \\\\Jobs
Description.
No..........
Category.... \Jobs

Job name.... \\\\Jobs\Work_In_Pro
             gress
Description.
No..........
Category.... \Jobs\Work_In_Progre
             ss

Job name.... \\\\Jobs\Work_In_Pro
             gress\Whale
Description.
No..........
Press any key to continue...



Category.... \Jobs\Work_In_Progre
             ss\Whale

Job name.... \\\\Jobs\Work_In_Pro
             gress\Whale\Aggrega
             te
Description.
No..........
Category.... \Jobs\Work_In_Progre
             ss\Whale\Aggregate

Job name.... \\\\Jobs\Work_In_Pro
             gress\Whale\Copy
Description.
No..........
Category.... \Jobs\Work_In_Progre
             ss\Whale\Copy

Job name.... \\\\Jobs\Work_In_Pro
             gress\Whale\Joins
Description.
Press any key to continue...





No..........
Category.... \Jobs\Work_In_Progre
             ss\Whale\Joins

Job name.... \\\\Jobs\Work_In_Pro
             gress\Whale\Loops
Description.
No..........
Category.... \Jobs\Work_In_Progre
             ss\Whale\Loops

Job name.... \\\\Jobs\Work_In_Pro
             gress\Whale\Merge
Description.
No..........
Category.... \Jobs\Work_In_Progre
             ss\Whale\Merge

Job name.... \\\\Jobs\Work_In_Pro
             gress\Whale\Transfo
             rm_Functions
Press any key to continue...





Description.
No..........
Category.... \Jobs\Work_In_Progre
             ss\Whale\Transform_
             Functions

Job name.... \\\\Tutorial
Description.
No..........
Category.... \Tutorial

Job name.... \\\\Tutorial\My Jobs
Description.
No..........
Category.... \Tutorial\My Jobs

Job name.... \\NextNumber
Description.
No.......... 55
Category....

Press any key to continue...



13 records listed.
>
The count makes sense although that is not what I'm looking for. Not sure how to avoid the inclusion of the folder count into the count of JOBTYPE='0'.

Cheers,
Whale.

Posted: Fri Dec 23, 2011 3:30 pm
by chulett
Yes, it does. :wink:

Something similar to and NAME not like '\\*' should help.

Posted: Fri Dec 23, 2011 9:40 pm
by ray.wurlod
Category placeholders don't have a JOBNO value and therefore that is reported as 0. Craig's solution is the one to use.