Hi Eric,

Table 'nodes' has column 'nodegroup' so just use
        select node_name from nodes where nodegroup='specific-large-nodegroup'

It's not possible to memorize the database schema so I always use these 2:
        # to get list of available tables
        select tabname from syscat.tables
        # to see what colums are present in that table
        select colname from syscat.columns where tabname='NODES'

Easiest is to query for a single object from table using 'fetch...'
        select * from nodes fetch first 1 row only
however it is useless  if you run it against an empty table:
        Protect: SP01>select * from COLLOCGROUP
        ANR2034E SELECT: No match found using this criteria.
        ANS8001I Return code 11.
In that case use syscat.columns.

Martin Janosik

-----Original Message-----
From: ADSM: Dist Stor Manager <ADSM-L@VM.MARIST.EDU> On Behalf Of Loon, Eric 
van (ITOP DI) - KLM
Sent: piatok 12. augusta 2022 9:24
To: ADSM-L@VM.MARIST.EDU
Subject: [EXTERNAL] [ADSM-L] SQL query to identify all nodegroup members

Hi everybody,

I'm trying to create a SQL query to identify all nodegroup members for a 
specific nodegroup. The problem is that a select node_name from nodegroup 
returns only the first 2048 characters, so for large nodegroups, the output is 
incomplete...
Does anybody know a solution for this issue? Thanks in advance!

Kind regards,
Eric van Loon
Core Infra
********************************************************
For information, services and offers, please visit our web site: 
http://www.klm.com . This e-mail and any attachment may contain confidential 
and privileged material intended for the addressee only. If you are not the 
addressee, you are notified that no part of the e-mail or any attachment may be 
disclosed, copied or distributed, and that any other action related to this 
e-mail or attachment is strictly prohibited, and may be unlawful. If you have 
received this e-mail by error, please notify the sender immediately by return 
e-mail, and delete this message.

Koninklijke Luchtvaart Maatschappij NV (KLM), its subsidiaries and/or its 
employees shall not be liable for the incorrect or incomplete transmission of 
this e-mail or any attachments, nor responsible for any delay in receipt.
Koninklijke Luchtvaart Maatschappij N.V. (also known as KLM Royal Dutch 
Airlines) is registered in Amstelveen, The Netherlands, with registered number 
33014286
********************************************************

Unless stated otherwise above:
Kyndryl Česká republika, spol. s r. o.
Sídlo: V Parku 2294/4, Chodov, 148 00  Praha 4,
IČ: 096 28 886
Zapsaná v obchodním rejstříku, vedeném Městským soudem v Praze (oddíl C, vložka 
339277)
Registered address: V Parku, 2294/4, Chodov, 148 00 Prague 4
Company ID: 096 28 886
Registered in the Commercial Register maintained by the Municipal Court in 
Prague (Part C, Entry 339277

Reply via email to