Skip to content

Store history data in SQL Database: MySQL, PostgreSQL or SQLite

License

Notifications You must be signed in to change notification settings

dschaedl/ioBroker.sql

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

30 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Logo

ioBroker.sql

This adapter saves state history into SQL DB.

Supports PostgreSQL, mysql, Microsoft SQL Server and sqlite. You can leave port 0 if default port is desired.

MS-SQL:

Use localhost\instance for host and check that TCP/IP connections are enabled. https://msdn.microsoft.com/en-us/library/bb909712(v=vs.90).aspx

SQLite:

is "file"-DB and cannot manage too many events. If you have a big amount of data use real DB, like PostgreSQL and co.

MySQL:

You can install mysql on linux systems:

apt-get install mysql-server mysql-client 

mysql -uroot -p

CREATE USER 'iobroker‘@’%’ IDENTIFIED BY 'iobroker';
GRANT ALL PRIVILEGES ON * . * TO 'iobroker'@'%';
FLUSH PRIVILEGES;

If required edit /etc/mysql/my.cnf to set bind to IP-Address for remote connect.

Warning: iobroker user is "admin". If required give limited rights to iobroker user.

Changelog

0.1.2 (2015-12-22)

  • (bluefox) fix MS-SQL port settings

0.1.1 (2015-12-19)

  • (bluefox) fix error with double entries

0.1.0 (2015-12-14)

  • (bluefox) support of strings

0.0.3 (2015-12-06)

  • (smiling_Jack) Add demo Data ( todo: faster insert to db )
  • (smiling_Jack) change aggregation (now same as history Adapter)
  • (bluefox) bug fixing

0.0.2 (2015-12-06)

  • (bluefox) allow only 1 client for SQLite

0.0.1 (2015-11-19)

  • (bluefox) initial commit

License

The MIT License (MIT)

Copyright (c) 2015 bluefox

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

About

Store history data in SQL Database: MySQL, PostgreSQL or SQLite

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 75.7%
  • HTML 24.3%