- 论坛徽章:
- 0
|
我有两个sql查询语句:
语句1:select substr("Timestamp",2,6) as date, avg("AVG_Space_Used_Percent") as val from "Disk_DV" where substr("Timestamp",2,6) between '080501' and '080531' and ("System_Name" like '%PEKII347%' or "System_Name" like '%pekii347%') group by substr("Timestamp",2,6) order by substr("Timestamp",2,6)
语句2:select substr("Timestamp",2,6) as date, avg("AVG_%_Used") as val from "NT_Logical_Disk_DV" where substr("Timestamp",2,6) between '080501' and '080531' and ("Server_Name" like '%PEKII347%' or "Server_Name" like '%pekii347%') group by substr("Timestamp",2,6) order by substr("Timestamp",2,6)
我现在想实现当语句1执行失败的情况下,去执行语句2,请问在命令行中应该怎么写?请高人指点,谢谢。 |
|