How to use AMET without mySQL?

Well, glad you’ve made it past those initial errors. Sorry about those. I’ll be sure to correct the process of running without the database in a future release.

The error you’re getting now means you don’t have the “ncdf4” R library installed. You’ll need to install it as you did the other required R libraries.

The ncdf4 library is required to open the CMAQ output files. This technically isn’t a critical part of AMET. I use this function to check the names in your CMAQ output files. If you have trouble installing this R package, I can give you a workaround. It would require a minor edit to one of the AMET R files.

But if you can simply install the ncdf4 package, that would glide you past this issue.

Wyat

Wyat

1 Like

Hi Wyat,

Thanks for spending time looking into these issues. The program is running now without MySQL. In case other people may need to use AMET without My SQL, I attach the script I am using here: aqProject_post_only.csh (7.4 KB).

Thanks,
Qian

Hi Wyat,

I met another issue that might be related to MySQL when running the analysis. I set AMET_DB to F, ran the script “run_scatterplot.csh” and got the error about loading RMySQL.

I tried to install this package but failed. The error message is " fatal error: mysql.h: No such file or directory". I googled for solutions. It seems that the package needs MySQL to be installed in the system. It not, do you know how to install this package without MySQL?

Thanks,
Qian

Right. The RMySQL package is not installed either.

In the AMET R_analysis_code folder, modify the AQ_Misc_Functions.R file and comment out the two lines below.

#if(!require(RMySQL)){stop(“Required Package RMySQL was not loaded”)}

#mysql <- list(login=amet_login, passwd=amet_pass, server=mysql_server, dbase=dbase, maxrec=maxrec) # Set MYSQL login and query options

I suppose I never fully tested the databaseless option on a system that didn’t already have database support setup. I’ll be sure to correct this going forward.

Please let me know if that corrects the issue you’re having with the scatter plot script. Thanks.

Wyat

Yes, it works! I just got the scatterplot. Thanks, Wyat.

Great. Thanks for your patience working through these issues. It’s helpful going forward as I improve support for using AMET-AQ without the database.

Wyat