public function query($sql){
		LogMaster::log($sql);
		$stm = oci_parse($this->connection,$sql);
		if ($stm===false) throw new Exception("Oracle - sql parsing failed\n".oci_error($this->connection));
		
		$out = array(0=>null);
		if($this->insert_operation){
			oci_bind_by_name($stm,":outID",$out[0],999);
			$this->insert_operation=false;
		}
		
		
		$mode = ($this->is_record_transaction() || $this->is_global_transaction())?OCI_DEFAULT:OCI_COMMIT_ON_SUCCESS;
		$res = @oci_execute($stm,$mode);
		if ($res===false) throw new Exception(oci_error($this->connection));
		
		$this->last_id=$out[0];
		
		return $stm;
	}