2017 © Pedro Peláez
 

library doctrine-compressed-fields

Library provide functional to split data from entity to different property by bit mask.

image

konstantinkuklin/doctrine-compressed-fields

Library provide functional to split data from entity to different property by bit mask.

  • Wednesday, August 30, 2017
  • by KonstantinKuklin
  • Repository
  • 2 Watchers
  • 2 Stars
  • 2 Installations
  • PHP
  • 1 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

Doctrine Compressed Fields

Doctrine Compressed Fields is a library which is allow to store data from different Entity properties in one column by using bits mask., (*1)

Build Status GitHub release Scrutinizer Code Quality Code Coverage Minimum PHP Version License, (*2)

DO NOT USE IN PRODUCTION! Developing still in progress., (*3)

Motivation

Sometimes we need to store simple boolean value like true or false and we use for it tinyint(1) which cost is 1 byte(bits)., (*4)

So we lose 7 bits on every such value if a column! Just imagine we lose 7k bits(700b = 0.68kb) on each 1k rows with 1 bool element stored in tinyint(1). Here you can find the solution, how to store data without losing memory and hdd free space., (*5)

Installation using composer

Execute in console:, (*6)

composer require konstantinkuklin/doctrine-compressed-fields

Documentation

  • in progress

Running tests

To run the tests, you need the sqlite extension for php. On Unix-like systems, install:, (*7)

php5-sqlite, (*8)

On Windows, enable the extension by uncommenting the following lines in php.ini, (*9)

extension = php_pdo_sqlite.dll
extension = php_sqlite3.dll
extension_dir = ext

Running the tests from the project root:, (*10)

./vendor/bin/phpunit

On Windows run phpunit from the full path, (*11)

phpunit

The Versions

30/08 2017

dev-master

9999999-dev

Library provide functional to split data from entity to different property by bit mask.

  Sources   Download

MIT

The Requires

 

The Development Requires

by Konstantin Kuklin

database doctrine bit mask