Page 1 of 1

Delete Complete Log

Posted: 15 Apr 2014, 15:40
by OE6CLD
Hi all,

Not sure if I have missed this in the (excellent) manual, but was not able to find it.

I sometimes need to delete the complete log to import an updated version edited on a different computer. I have not found a possibility where I can say select all (all log entries) and delete.

Using SQLite this is quite easy, I simply delete the log file. I next create a new database, import my updated ADIF file and done.

At home my computer in the shack and my main computer in the office are sharing a MySQL database server, so both always are showing the same. Additionally I also have an Apple laptop where I use Log4OM in a VM. When operating from a different location, or on a business trip with plenty of time in the evening, I ofen go through the log, update a lot of entries, or add some additional information. When back home, easiest to way update would be to export everything into an ADIF file, wipe the log on the main computer and import the ADIF file.

What's the best way to do this using a MySQL database server?

Is there a way to select all log entries in a database and delete them?

73,
Claus, OE6CLD/EI7JZ

Re: Delete Complete Log

Posted: 15 Apr 2014, 17:00
by G4POP
Claus,
I think that you should use MySQL via the intranet/internet then all computers can use a common database from any location.

Alternatively use a common SQLite log on Dropbox which is what I do because it is so much easier to set up and use, the drawback is that simultaneous update from multiple computers is not good it's really best where you are updating on only one computer at a time allowing time for synchronisation, which it seems would be fine for you.

It is possible to delete the complete database from the archive manager just enable update and deletion, select all and press your keyboards delete key. However this can be very slow and deleting the SQLite file is much better.

Re: Delete Complete Log

Posted: 15 Apr 2014, 18:22
by PB4FUN
Or do a delete query :
QSO Archive - Archive Management - Field update (no rows selected msg, click away)
On the right in the field above the red labels enter : delete from log
Check the checkboxes from the red labels and press the "I understand ...."-button

Re: Delete Complete Log

Posted: 16 Apr 2014, 08:06
by OE6CLD
Hello Terry, hello Meindert,

Thanks for your advice and suggestions!

@Terry: I already thought about using Dropbox, but my MySQL server works perfectly fine, I easily can do some additional reports, and I usually don't have internet when operating with the laptop - although I could try to tether with my mobile phone. At the moment I prefer my local MySQL server, which offers more benefits (but I always have an ADIF beackup on Dropbox).

@Meinert: This was exactly the missing link ;) I'm quite familiar with SQL, but I always thought that I had to select all/some entries first before using SQL. To click away the no rows selected message did the trick! This does exactly what I want, thanks again.

73,
Claus, OE6CLD/EI7JZ

Re: Delete Complete Log

Posted: 16 Apr 2014, 10:40
by IW3HMH
there is also another table that should be truncated to completely clear the DB.
Also if you CREATE MYSQL database again with the same name, the DB will be deleted and recreated.

Code: Select all

DROP SCHEMA IF EXISTS `##DATABASENAME##` ;
CREATE SCHEMA IF NOT EXISTS `##DATABASENAME##` DEFAULT CHARACTER SET utf8 ;
USE `##DATABASENAME##` ;
Database creation script in MYSQL is in roaming\LogOm folder and is called log4om.qsl