| 451 | | sprintf(gcQuery,"SELECT tProperty.uKey,tProperty.cValue,tContainer.cLabel FROM tProperty,tContainer" |
| | 463 | if(uTargetNode) |
| | 464 | sprintf(gcQuery,"SELECT tProperty.uKey,tProperty.cValue,tContainer.cLabel FROM tProperty,tContainer" |
| | 465 | " WHERE tProperty.uKey=tContainer.uContainer AND tProperty.uType=3 AND" |
| | 466 | " tProperty.cName='1k-blocks.luUsage' AND tContainer.uDatacenter=%u" |
| | 467 | " AND tContainer.uNode=%u" |
| | 468 | " AND tContainer.uStatus=1",uDatacenter,uTargetNode); |
| | 469 | else |
| | 470 | sprintf(gcQuery,"SELECT tProperty.uKey,tProperty.cValue,tContainer.cLabel FROM tProperty,tContainer" |
| 477 | | sprintf(gcQuery,"SELECT tProperty.uKey,tProperty.cValue FROM tProperty,tContainer" |
| | 496 | if(uTargetNode) |
| | 497 | sprintf(gcQuery,"SELECT tProperty.uKey,tProperty.cValue FROM tProperty,tContainer" |
| | 498 | " WHERE tProperty.uKey=tContainer.uContainer AND tProperty.uType=3 AND" |
| | 499 | " tProperty.cName='1k-blocks.luSoftLimit' AND tContainer.uDatacenter=%u" |
| | 500 | " AND tContainer.uNode=%u" |
| | 501 | " AND tContainer.uStatus=1",uDatacenter,uTargetNode); |
| | 502 | else |
| | 503 | sprintf(gcQuery,"SELECT tProperty.uKey,tProperty.cValue FROM tProperty,tContainer" |
| 541 | | sprintf(gcQuery,"SELECT cValue,uKey,cLabel,cName FROM tProperty,tContainer WHERE" |
| | 567 | if(uTargetNode) |
| | 568 | sprintf(gcQuery,"SELECT cValue,uKey,cLabel,cName FROM tProperty,tContainer WHERE" |
| | 569 | " tProperty.uKey=tContainer.uContainer AND" |
| | 570 | " tContainer.uDatacenter=%u AND" |
| | 571 | " tContainer.uNode=%u AND" |
| | 572 | " cValue!='0' AND uType=3 AND cName LIKE '%%.luFailcnt'" |
| | 573 | " ORDER BY CONVERT(cValue,UNSIGNED) DESC LIMIT 10",uDatacenter,uTargetNode); |
| | 574 | else |
| | 575 | sprintf(gcQuery,"SELECT cValue,uKey,cLabel,cName FROM tProperty,tContainer WHERE" |
| | 606 | " tContainer.uNode=%u AND" |
| | 607 | " cName='Venet0.luMaxDailyInDelta'" |
| | 608 | " GROUP BY uKey ORDER BY CONVERT(cValue,UNSIGNED) DESC LIMIT 10",uACTIVE,uDatacenter,uTargetNode); |
| | 609 | else |
| | 610 | sprintf(gcQuery,"SELECT FORMAT(SUM(cValue/1000),2),uKey,cHostname,TIME(FROM_UNIXTIME(tProperty.uModDate)) FROM" |
| | 611 | " tProperty,tContainer WHERE" |
| | 612 | " tProperty.uKey=tContainer.uContainer AND cValue!='0' AND uType=3 AND" |
| | 613 | " tContainer.uStatus=%u AND" |
| | 614 | " tContainer.uDatacenter=%u AND" |
| | 642 | " tContainer.uNode=%u AND" |
| | 643 | " cName='Venet0.luMaxDailyOutDelta'" |
| | 644 | " GROUP BY uKey ORDER BY CONVERT(cValue,UNSIGNED) DESC LIMIT 10",uACTIVE,uDatacenter,uTargetNode); |
| | 645 | else |
| | 646 | sprintf(gcQuery,"SELECT FORMAT(SUM(cValue/1000),2),uKey,cHostname,TIME(FROM_UNIXTIME(tProperty.uModDate)) FROM" |
| | 647 | " tProperty,tContainer WHERE" |
| | 648 | " tProperty.uKey=tContainer.uContainer AND cValue!='0' AND uType=3 AND" |
| | 649 | " tContainer.uStatus=%u AND" |
| | 650 | " tContainer.uDatacenter=%u AND" |
| | 678 | " tContainer.uNode=%u AND" |
| | 679 | " (cName='Venet0.luInDelta' OR cName='Venet0.luOutDelta')" |
| | 680 | " GROUP BY uKey ORDER BY CONVERT(cValue,UNSIGNED) DESC LIMIT 10",uACTIVE,uDatacenter,uTargetNode); |
| | 681 | else |
| | 682 | sprintf(gcQuery,"SELECT FORMAT(SUM(cValue/2000),2),uKey,cHostname FROM" |
| | 683 | " tProperty,tContainer WHERE" |
| | 684 | " tProperty.uKey=tContainer.uContainer AND cValue!='0' AND uType=3 AND" |
| | 685 | " tContainer.uStatus=%u AND" |
| | 686 | " tContainer.uDatacenter=%u AND" |
| 644 | | sprintf(gcQuery,"SELECT FORMAT(SUM(cValue/1000000000),2),uKey,cHostname FROM" |
| | 708 | if(uTargetNode) |
| | 709 | sprintf(gcQuery,"SELECT FORMAT(SUM(cValue/1000000000),2),uKey,cHostname FROM" |
| | 710 | " tProperty,tContainer WHERE" |
| | 711 | " tContainer.uStatus=%u AND" |
| | 712 | " tContainer.uDatacenter=%u AND" |
| | 713 | " tContainer.uNode=%u AND" |
| | 714 | " tProperty.uKey=tContainer.uContainer AND cValue!='0' AND uType=3 AND" |
| | 715 | " (cName='Venet0.luIn' OR cName='Venet0.luOut')" |
| | 716 | " GROUP BY uKey ORDER BY CONVERT(cValue,UNSIGNED) DESC LIMIT 10",uACTIVE,uDatacenter,uTargetNode); |
| | 717 | else |
| | 718 | sprintf(gcQuery,"SELECT FORMAT(SUM(cValue/1000000000),2),uKey,cHostname FROM" |