% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/default.R
\name{mysqlHasDefault}
\alias{mysqlHasDefault}
\title{Check if default database is available.}
\usage{
mysqlHasDefault()
}
\description{
RMySQL examples and tests connect to a database defined by the
\code{rs-dbi} group in \code{~/.my.cnf}. This function checks if that
database is available, and if not, displays an informative message.
}
\examples{
if (mysqlHasDefault()) {
  db <- dbConnect(RMySQL::MySQL(), dbname = "test")
  dbListTables(db)
  dbDisconnect(db)
}
}
