Skip to content

Latest commit

History

7 Commits

Folders and files

NameName
Last commit message
Last commit date

Repository files navigation

Handling MySQL and MongoDB databases with Java

Basic data handling with Java, MySQL and MongoDB

Libraries needed:

MySQL

Given a database, this program is able to create a table pet if pet doesn't already exist.

mysql> describe pet;

FieldTypeNullKeyDefaultExtra
namevarchar(20)YESNULL
ownervarchar(20)YESNULL
speciesvarchar(20)YESNULL
sexchar(1)YESNULL

Other features of the program:

  • Show all rows in the table.
  • Insert new row.
  • Delete a row given parameters (key, value).
    • DELETE FROM pet WHERE key=value

MongoDB

Compared to MySQL, MongoDB is more flexible regarding handling data.

Given a database test, the program is able to:

  • See all collections inside test.
  • Read all documents inside one collection.
  • Create a new collection.
  • Insert documents into a collection.
  • Remove a document from a collection.
  • Drop an entire collection.

About

Basic data handling with Java, MySQL and MongoDB

Topics

Resources

Stars

1 star

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages