Page 1 of 1

ExportToMySQL error

Posted: Fri 26 May 2023 7:01 am
by AndyKF650
Hi there

I just had cause to run the ExportToMySQL.exe to update MYSQL tables following a couple of days hiatus from my hosting company HostPresto.

The dayfile update worked with no issues at all but the monthly update sprang the following error message at the start of the process but then went through to complete the update.

My question is this an error on my side or is it an issue with the .exe script. I am running the v1.80.0 script with CMX 3.25.1 b3244


andyk@raspberrypi:~/CumulusMX $ sudo mono ExportToMySQL.exe monthly
Parameter: monthly
You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '' at line 1
You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '' at line 1
You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '' at line 1
You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '' at line 1
23-05-26 07:50

Re: ExportToMySQL error

Posted: Mon 29 May 2023 6:33 pm
by mcrossley
Are you saying that the monthly import seems to have worked?

Can you try importing a single monthly file and see if you get the same error.

The logging for ExportToMySQL is minimal to say the least so there is no real clue where the error is happening. Note to self - add more logging to the next build!

Re: ExportToMySQL error

Posted: Mon 29 May 2023 8:46 pm
by AndyKF650
Hi Mark

I just reran the whole test again with a single month, monthly and dayfile parameters. Whilst they all appeared to work the error showed up on the monthly test only.

The attached file shows the cmd line screen shot from my RPi.

Re: ExportToMySQL error

Posted: Wed 02 Aug 2023 4:29 pm
by mcrossley
Could you post the monthly file you used please?

Re: ExportToMySQL error

Posted: Wed 02 Aug 2023 4:46 pm
by AndyKF650
Hi Mark

Do you really want the whole monthly files from the beginning of time or 4 years ago! As far as I know the monthly parameter just runs all the monthly files present on the data base.

Re: ExportToMySQL error

Posted: Wed 02 Aug 2023 4:50 pm
by mcrossley
I thought you also ran against a single month and still got the error?

Re: ExportToMySQL error

Posted: Wed 02 Aug 2023 4:57 pm
by AndyKF650
Hi Mark

It was only the monthly parameter that gave the error. The dayfile and single month parameters worked with no errors as I mentioned the other day.
I just reran the whole test again with a single month, monthly and dayfile parameters. Whilst they all appeared to work the error showed up on the monthly test only

Re: ExportToMySQL error

Posted: Wed 02 Aug 2023 5:01 pm
by mcrossley
Ah, so it is likely just one of your files that has errors in it.

There will need to be a new version of ExportToMySQL for the next release of CMX, so I'll add more verbose logging of what is going on to enable you to track down the issue...