Bareos Bug Tracker
Bareos Bug Tracker

View Issue Details Jump to Notes ] Related Changesets ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0000964bareos-core[All Projects] directorpublic2018-06-13 15:392018-06-22 17:18
Reporterfrank 
Assigned To 
PriorityhighSeveritymajorReproducibilityalways
StatusclosedResolutionfixed 
PlatformOSOS Version
Product Version17.2.5 
Target VersionFixed in Version17.2.6 
Summary0000964: Query failed: ERROR: column reference "jobbytes" is ambiguous
DescriptionPredefined query (5) in bconsole called via query command fails.

DB-Backend: PostgreSQL

---

Query failed: ERROR: column reference "jobbytes" is ambiguous

LINE 1: ...Set AS FileSet,Level,StartTime, JobFiles,ROUND(JobBytes/1...

                                                             ^



SELECT DISTINCT Job.JobId AS JobId,Client.Name AS Client, FileSet.FileSet AS FileSet,Level,StartTime, JobFiles,ROUND(JobBytes/1024.0/1024.0/1024.0,3) AS GB,Count(VolumeName) AS Volumes FROM Client,Job,JobMedia,Media,FileSet WHERE Client.Name='okmprd1118d' AND Client.ClientId=Job.ClientId AND Job.Type='B' AND Job.JobStatus IN ('T','W') AND Job.FileSetId=FileSet.FileSetId AND JobMedia.JobId=Job.JobId AND JobMedia.MediaId=Media.MediaId GROUP BY Job.JobId,Client.Name,FileSet.FileSet,Level,StartTime,JobFiles,JobBytes ORDER BY Job.StartTime;

---
Steps To ReproduceReproduced on bareos-dir Version: 17.2.5 (14 Feb 2018) x86_64-redhat-linux-gnu redhat CentOS Linux release 7.5.1804 (Core) CentOS_7 x86_64


*query

Available queries:

     1: List up to 20 places where a File is saved regardless of the directory and Client

     2: List where the most recent copies of a file with path of a Client are saved

     3: List last 20 Full Backups for a Client

     4: List all backups for a Client after a specified time

     5: List all backups for a Client and COUNT the Volumes which been used

     6: List Volume Attributes for a selected Volume

     7: List Volumes used by selected JobId

     8: List Volumes to Restore All Files

     9: List Pool Attributes for a selected Pool

    10: List total files/bytes by Job

    11: List total files/bytes by Volume

    12: List Files for a selected JobId

    13: List Jobs stored on a selected MediaId

    14: List Jobs stored for a given Volume name

    15: List Volumes Bareos thinks are in changer

    16: List Volumes likely to need replacement from age or errors

    17: List Volumes Bareos thinks are eligible for the changer

    18: List Volumes by Volume:

    19: List Volumes by Jobs:

    20: List Volumes for a jobname:

Choose a query (1-20): 5

Enter Client Name: okmprd1118d

Query failed: ERROR: column reference "jobbytes" is ambiguous

LINE 1: ...Set AS FileSet,Level,StartTime, JobFiles,ROUND(JobBytes/1...

                                                             ^



SELECT DISTINCT Job.JobId AS JobId,Client.Name AS Client, FileSet.FileSet AS FileSet,Level,StartTime, JobFiles,ROUND(JobBytes/1024.0/1024.0/1024.0,3) AS GB,Count(VolumeName) AS Volumes FROM Client,Job,JobMedia,Media,FileSet WHERE Client.Name='okmprd1118d' AND Client.ClientId=Job.ClientId AND Job.Type='B' AND Job.JobStatus IN ('T','W') AND Job.FileSetId=FileSet.FileSetId AND JobMedia.JobId=Job.JobId AND JobMedia.MediaId=Media.MediaId GROUP BY Job.JobId,Client.Name,FileSet.FileSet,Level,StartTime,JobFiles,JobBytes ORDER BY Job.StartTime;

*
TagsNo tags attached.
bareos-master: impactyes
bareos-master: actionfixed
bareos-18.2: impact
bareos-18.2: action
bareos-17.2: impactyes
bareos-17.2: actionfixed
bareos-16.2: impactno
bareos-16.2: action
bareos-15.2: impactno
bareos-15.2: action
bareos-14.2: impactno
bareos-14.2: action
bareos-13.2: impactno
bareos-13.2: action
bareos-12.4: impactno
bareos-12.4: action
Attached Files

- Relationships
child of 0000916resolvedjoergs Release bareos-17.2.6 

-  Notes
(0003045)
joergs (administrator)
2018-06-19 14:53

Merged https://github.com/bareos/bareos/pull/87 [^] that fixed this issue.

- Related Changesets
bareos: master 338a81f8
Timestamp: 2018-05-04 21:59:20
Author: Daniel Néri
Ported: N/A
Details ] Diff ]
Fix ambiguous sample queries

When the JobBytes column was added to the JobMedia table (in commit
d31cd38e59f979e256370268d679d6f281ec758c), some sample queries became
ambiguous.
mod - core/src/dird/query.sql Diff ] File ]

- Issue History
Date Modified Username Field Change
2018-06-13 15:39 frank New Issue
2018-06-13 15:55 maik Status new => confirmed
2018-06-19 14:49 joergs Relationship added child of 0000916
2018-06-19 14:49 joergs bareos-master: impact => yes
2018-06-19 14:49 joergs bareos-17.2: impact => yes
2018-06-19 14:49 joergs bareos-16.2: impact => no
2018-06-19 14:49 joergs bareos-15.2: impact => no
2018-06-19 14:49 joergs bareos-14.2: impact => no
2018-06-19 14:49 joergs bareos-13.2: impact => no
2018-06-19 14:49 joergs bareos-12.4: impact => no
2018-06-19 14:51 joergs Changeset attached => bareos master 338a81f8
2018-06-19 14:53 joergs Note Added: 0003045
2018-06-19 14:53 joergs Status confirmed => resolved
2018-06-19 14:53 joergs Resolution open => fixed
2018-06-19 14:53 joergs Assigned To => joergs
2018-06-22 17:18 joergs bareos-master: action => fixed
2018-06-22 17:18 joergs bareos-17.2: action => fixed
2018-06-22 17:18 joergs Assigned To joergs =>
2018-06-22 17:18 joergs Status resolved => closed
2018-06-22 17:18 joergs Fixed in Version => 17.2.6


Copyright © 2000 - 2018 MantisBT Team
Powered by Mantis Bugtracker