>>>>> On Mon, 13 Nov 2017 08:33:26 -0700, Bill Arlofski said:
> 
> On 11/13/2017 03:49 AM, Martin Simmons wrote:
> 
> > Why not take this info from the job table, rather than having to parse it 
> > from
> > the joblog?
> > 
> > __Martin
> 
> 
> Hi Martin,
> 
> I usually try to avoid directly accessing the catalog if possible. In this
> case, what I am looking for is so simple to get from bconsole it is just one
> bconsole command, then a few trivial grep/cut/sed/tr statements.
> 
> Directly querying the db is usually straight forward with MySQL, but
> PostgreSQL has a slightly more more complex setup for permissions - which can
> cause people minor headaches. Also, because we have SQL "standards"™, I
> usually need to write 3 different queries so that the script will work with
> MySQL, MariaDB, and PostgreSQL (see www.revpol.com/baculasummaryemails for
> example)
> 
> Having said all that, I have still not 100% ruled out querying the catalog
> directly. :)   If I run into a feature idea that I want to implement which
> needs information not included in the job summary - but is available in the
> catalog - then I will probably just shift gears. :)

Yes, I see what you mean.  

You could try "llist jobid=xxxx" as way to access the catalog without SQL.

One reason for not reading the joblog is that it is optional (configured via
the Messages resource).

__Martin

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users

Reply via email to