I hope you take something away...

If you do please leave something for me :)

Setting up debug mode on Drupal 8

  1. First copy sites/example.settings.local.php to default/settings.local.php
  2. Now uncomment the following lines in default/settings.php
    # if (file_exists(__DIR__ . '/settings.local.php')) {
    #   include __DIR__ . '/settings.local.php';
    # }
  3. Now debugging is set. You also can use the following command
    drupal routing:debug <route name>
    This command will give the user information regarding a specific route


PostgreSQL and NOT IN

PostgreSQL treats LEFT JOIN and NOT EXISTS equally, using same execution plan for both of them (namely a Hash Anti Join for the example above).

As for NOT IN, which is semantically different since its logic is trivalent and it can return NULL, PostgreSQL tries to take this into account and limits itself to using a filter against a subplan (a hashed subplan for a hashable resultset like in example above).

DrupalCon Asia - 2016

Submitted by nmeegama on Fri, 02/19/2016 - 09:36

Drupal - The perfect frontend for document management

A common problem with Document Management Systems (DMS) is the fact that they don’t have a very user-friendly Interface. To build one, is a complex and time consuming process. Drupal can solve this problem by integrating with any document management system and provide a more intutive user experience.

Permission persistance for new files for a particular users

Story: Setting permission for directory for a particular user

Usually what we do when we want to give permission to folder (lets say our users name is abc for this example and directory name is test):

chown -R abc test

Problem: Does not set the permission to newly created files

Solution: setting the setgid bit so that any new file's (in test) owner is also user abc

sudo chmod -R u+s test