Quantcast
Channel: ADSM.ORG
Viewing all articles
Browse latest Browse all 2470

Joined or Nested SQL Statement

$
0
0
I need to develop an SQL select statement that gives me the occupancy of each node as well as the platform name. Since this information comes from 2 different tables, I would have to join or nest the SQL select statement. So far, I have this to give me the occupancey results. I need to know how to get the platform name (and I want to get all this using one statement)

select NODE_NAME,SUM(PHYSICAL_MB) AS "MB's USED",SUM(NUM_FILES) AS "NUMBER OF FILES" FROM OCCUPANCY GROUP BY NODE_NAME ORDER BY "MB's USED"DESC


Any help appreciated!

Viewing all articles
Browse latest Browse all 2470