コード例 #1
0
 public function execute(DataSourceHandler $handler, DataControllerCallContext $callcontext, $connection, $sql, __SQLDataSourceHandler__AbstractQueryCallbackProxy $callbackInstance)
 {
     $statement = OCIImplHelper::oci_parse($connection, $sql);
     try {
         OCIImplHelper::oci_execute($connection, $statement, OCI_NO_AUTO_COMMIT);
         $result = $callbackInstance->callback($callcontext, $connection, $statement);
     } catch (Exception $e) {
         OCIImplHelper::oci_free_statement($connection, $statement);
         throw $e;
     }
     OCIImplHelper::oci_free_statement($connection, $statement);
     return $result;
 }
コード例 #2
0
 public function executeIndividualStatement(DataSourceHandler $handler, $connection, $sql)
 {
     $statement = OCIImplHelper::oci_parse($connection, $sql);
     try {
         OCIImplHelper::oci_execute($connection, $statement, OCI_NO_AUTO_COMMIT);
         $affectedRecordCount = OCIImplHelper::oci_num_rows($connection, $statement);
     } catch (Exception $e) {
         OCIImplHelper::oci_free_statement($connection, $statement);
         throw $e;
     }
     OCIImplHelper::oci_free_statement($connection, $statement);
     return $affectedRecordCount;
 }