(self, sql)
| 153 | return 0 |
| 154 | |
| 155 | def pgsql_actual_time(self, sql): |
| 156 | try: |
| 157 | #success, res = self.execute_sql('explain (FORMAT JSON, analyze) ' + sql) |
| 158 | success, res = self.execute_sql('explain (FORMAT JSON, analyze) ' + sql) |
| 159 | if success == 1: |
| 160 | cost = res[0][0][0]['Plan']['Actual Total Time'] |
| 161 | return cost |
| 162 | else: |
| 163 | return -1 |
| 164 | except Exception as error: |
| 165 | logging.error('pgsql_actual_time Exception', error) |
| 166 | return -1 |
| 167 | |
| 168 | def mysql_cost_estimation(self, sql): |
| 169 | try: |
nothing calls this directly
no test coverage detected