Skip to content

Instantly share code, notes, and snippets.

View andrerom's full-sized avatar

André R. andrerom

View GitHub Profile
@andrerom
andrerom / check_row_size.sh
Last active July 16, 2020 11:26 — forked from suya55/check_row_size.sh
mysql row size checker
#!/bin/bash
#
# usage: mysqldump --no-data | check_row_size.sh
#
#
#
# https://dev.mysql.com/doc/refman/8.0/en/column-count-limit.html#row-size-limits
#
@andrerom
andrerom / new_way.php
Last active December 12, 2015 09:49 — forked from dpobel/new_way.php
Updated query to reflect added ContentTypeIdentifier by @crevillo in 0cb178324a63767664dc0aed0f2ddd1ace7d1e1d in January 2013
<?php
use \eZ\Publish\API\Repository\Values\Content\Query;
$locationService = $this->getRepository()->getLocationService();
$searchService = $this->getRepository()->getSearchService();
$urlAliasService = $this->getRepository()->getUrlAliasService();
$root = $locationService->loadLocation( 2 );
$query = new Query();
$query->criterion = new Criterion\LogicalAND(
@andrerom
andrerom / papi_bootstrap.php
Created September 5, 2012 09:46 — forked from pspanja/papi_bootstrap.php
Public API boostrap
<?php
/**
* Get ServiceContainer (exposes the API)
* @var \eZ\Publish\API\Container $serviceContainer
*/
$serviceContainer = require "bootstrap.php";
$repository = $serviceContainer->getRepository();
$administratorUser = $repository->getUserService()->loadUser( 14 );