banner_bild_01 banner_bild_02 banner_bild_03 banner_bild_04 banner_bild_05
banner_bild_06 banner_bild_07 banner_bild_08

TSM SQL Advanced Tutorial (7)


Home SQL



If your query creates output containing the same information multiple times while you want to see it only once, you may use the "distinct" clause. In our example, we want to know which nodes are associated with schedules. The following query will show all nodes for which associations exist:

select node_name from associations

While this method will work, it might probably print the same node several times, if you associated it with more than just one schedule. We can eliminate the redundancy by typing:

select distinct(node_name) from associations

This will insure that any nodename will only be listed once.

Lets assume that, based on the previous example, you want to see only those nodes, that do NOT have a schedule associated with it. Obviously we won't find that information in the associations table. What we will have to do is query the nodes table, check whether an association exists for the node and print the nodename if no such association is defined.

select node_name from nodes where node_name not -
in (select node_name from associations)

Obviously we don't need the "distinct" clause since any node exists only once on the nodes table.

 Alle erwähnten Produkte und Bezeichnungen können eingetragene Warenzeichen der jeweiligen Hersteller sein und werden als solche betrachtet.
Bei Fragen oder Problemen kontaktieren Sie bitte

Navigation  | Über GS  |  Lösungen  |  ServiceReferenzen  |  Impressum  |  Download

© 2016 by General Storage GbR. Alle Rechte vorbehalten



Kontaktieren Sie uns:

Telefon: +49 6206 157686
Telefax:  +49 6206 157687


55. Tagung des
AK Storagemanagement
09.-11. April 2018,

IBM Spectrum Protect und Veeam Kundenform,
13. Juni 2018,
Skyloft Frankfurt Airport

dsmISI for Veeam ermöglicht unbegrenzte Speicher für Backups

Hier nachlesen

General Storage Lösungen
Ready for IBM Tivoli Software