Skip to content

Instantly share code, notes, and snippets.

Avatar

Sergei Ogainsbourg ogaaaan

View GitHub Profile
View gist:6620021
DROP TABLE IF EXISTS `posts`;
CREATE TABLE IF NOT EXISTS `posts` (
`id` int(5) NOT NULL AUTO_INCREMENT,
`title` varchar(64) NOT NULL COMMENT '件名',
`body` text NOT NULL COMMENT '本文',
`created` datetime NOT NULL,
`modified` datetime NOT NULL,
PRIMARY KEY (`id`),
KEY `title` (`title`,`body`(191))
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 AUTO_INCREMENT=1;
@ogaaaan
ogaaaan / backup_mysql.sh
Created Jan 11, 2012
Backup MySQL Files
View backup_mysql.sh
#!/bin/bash
# Backup From MySQL
#
# Copyright : 2011 Seiji Ogawa [Ogaaaan]
# http://torhamzedd.blogspot.com
# License : The MIT License
# [jp] http://goo.gl/0sFoc
# [en] http://goo.gl/KPxS
@ogaaaan
ogaaaan / backup_log.sh
Created Jan 11, 2012
Backup Logfiles
View backup_log.sh
#!/bin/bash
# Backup From Log
#
# Copyright : 2011 Seiji Ogawa [Ogaaaan]
# http://torhamzedd.blogspot.com
# License : The MIT License
# [jp] http://goo.gl/0sFoc
# [en] http://goo.gl/KPxS
View backup_file.sh
#!/bin/bash
# Backup From File
#
# Copyright : 2011 Seiji Ogawa [Ogaaaan]
# http://torhamzedd.blogspot.com
# License : The MIT License
# [jp] http://goo.gl/0sFoc
# [en] http://goo.gl/KPxS
@ogaaaan
ogaaaan / LibreOfficeBASICSummary.txt
Created Aug 4, 2011
LibreOfficeBASIC概要まとめ
View LibreOfficeBASICSummary.txt
===============================================================================================
LibreOffice BASIC 要約
2011.08.06 Ogaaaan
===============================================================================================
■構造
【セクション】
サブルーチン
Sub...End Sub
@ogaaaan
ogaaaan / getCorrectedNextMonth.php
Created Aug 1, 2011
1ヶ月後の日付を返す(1ヶ月飛ばさない)
View getCorrectedNextMonth.php
<?php
/**
* getCorrectedNextMonth
*
* 年月日を渡すとその翌月の当日を調整して返す
*
* 2011-01-31を渡すと、2011-02-312011-03-03ではなく
* 翌月内に収まるようにして2011-02-28を返す
* 月額課金をわかり易くするために使う。
*
View sout.java
class MyFirstTest {
public static void main(String[] args) {
System.out.println("Hello World!");
}
}
@ogaaaan
ogaaaan / JFrameTest.java
Created May 30, 2011
JavaでSwingを表示してみる
View JFrameTest.java
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package jframetest;
import java.awt.*;
import javax.swing.*;
import javax.swing.tree.*;
@ogaaaan
ogaaaan / FrameTest.java
Created May 30, 2011
JavaでAWTを表示してみる
View FrameTest.java
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package frametest;
import java.awt.*;
/**
*
* @author ogaaaan
View java_tutorial01.java
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package javatest;
/**
*
* @author ogaaaan