This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* @author Marco Pivetta <ocramius@gmail.com> | |
*/ | |
use Zend\ServiceManager\ServiceManager; | |
use Zend\Mvc\Service\ServiceManagerConfig; | |
use DoctrineORMModuleTest\Framework\TestCase; | |
use ContentTest\Util\ServiceManagerFactory; | |
use Zend\Loader\StandardAutoloader; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CREATE OR REPLACE FUNCTION public.json_append(data json, insert_data json) | |
RETURNS json | |
IMMUTABLE | |
LANGUAGE sql | |
AS $$ | |
SELECT ('{'||string_agg(to_json(key)||':'||value, ',')||'}')::json | |
FROM ( | |
SELECT * FROM json_each(data) | |
UNION ALL | |
SELECT * FROM json_each(insert_data) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
IF (NOT EXISTS(SELECT * FROM QSYS2.SYSTABLES WHERE TABLE_SCHEMA = 'BACKUP' AND TABLE_NAME='MYTABLE')) THEN | |
CREATE TABLE BACKUP.MYTABLE | |
AS (SELECT * FROM MYLIB.MYTABLE) | |
WITH DATA; | |
ELSE | |
INSERT INTO BACKUP.MYTABLE | |
SELECT * FROM MYLIB.MYTABLE; | |
END IF; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"require": { | |
"guzzlehttp/guzzle": "4.*" | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Goes in your .git/config file | |
[alias] | |
# Temporarily stop tracking a file in git. | |
# usage: git unwatch path/to/file | |
unwatch = update-index --assume-unchanged | |
# Resume tracking a file in git. | |
# usage: git watch path/to/file | |
watch = update-index --no-assume-unchanged |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* This is a quick example of how to stream a file to a client, likely a browser, | |
* using Zend Expressive. There are a lot of factors which it doesn't take in to | |
* account. But for the purposes of a quick intro, this should suffice. | |
*/ | |
class ViewDocumentPageAction | |
{ | |
protected function downloadFile() | |
{ |
OlderNewer