- learning erb
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
h option(*srcstmt:*nodebugio) | |
* compile with 15 to CRTMOD then run | |
* CRTPGM FIRSTPGM BNDSRVPFM(TESTFIRST) | |
d bankAccount1 ds QUALIFIED | |
d accountNbr 7P 0 | |
d balance 11P 2 | |
d bankAccount2 ds QUALIFIED | |
d accountNbr 7P 0 | |
d balance 11P 2 | |
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
<!DOCTYPE html> | |
<html ng-app="todoApp"> | |
<head> | |
<title>TO DO List</title> | |
<link href="bootstrap.css" rel="stylesheet" /> | |
<link href="bootstrap-theme.css" rel="stylesheet" /> | |
<script src="angular.js"></script> | |
<script> | |
var model = { |
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
DROP TABLE IF EXISTS authors, books; | |
DROP SEQUENCE IF EXISTS author_id_seq, book_id_seq; | |
CREATE SEQUENCE author_id_seq START 1; | |
CREATE SEQUENCE book_id_seq START 1; | |
create table authors ( | |
id INTEGER PRIMARY KEY DEFAULT NEXTVAL('author_id_seq'), | |
name VARCHAR(50) NOT NULL, | |
UNIQUE(name) |
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
import java.sql.*; | |
import java.util.Properties; | |
public class MySqlBatchInsert { | |
int counter = 0; | |
Connection conn; | |
PreparedStatement ps; | |
public MySqlBatchInsert() throws SQLException, ClassNotFoundException { | |
String url = "jdbc:mysql:///rmswms"; |
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
h nomain option(*nodebugio:*srcstmt) debug(*yes) | |
* | |
d getnow pr 26A | |
* | |
d adddur pr 26A | |
d initalValue 26A VALUE | |
d scale 3P 0 VALUE | |
d units 7A VALUE | |
d success 4A | |
* |
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
H option(*srcstmt : *nodebugio) debug(*yes) bnddir('ADDDUR') | |
H dftactgrp(*no) actgrp(*caller) | |
H EXTBININT(*YES) | |
H ALWNULL(*USRCTL) | |
H copyright('(C) COPYRIGHT StoneEagle Insurance Systems, Inc. 2010') | |
*========================================================================= | |
* | |
* Pgm : TST_ADDDUR - Test Add Duration | |
* Pgmer: | |
* Date : August 2014 |
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 'sinatra' | |
gem 'sinatra' | |
require 'sinatra/reloader' if development? | |
require 'jt400.jar' | |
require 'yaml' | |
set :public_folder, 'public' | |
db = YAML.load_file '/config/database.yml' | |
Java::JavaClass.for_name db['driver'] | |
connection = java.sql.DriverManager.get_connection(db['dburl'], db['username'], db['password']) |
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 'sinatra' | |
require 'sinatra/reloader' if development? | |
require 'lib/jt400.jar' | |
require 'bigdecimal' | |
require 'yaml' | |
require 'json' | |
set :public_folder, 'public' | |
db = YAML.load_file '/config/db.yml' | |
Java::JavaClass.for_name db['driver'] |
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 table Employee ( | |
id int generated always as identity Primary Key | |
, name varchar(50) | |
, title varchar(50) | |
, office varchar(50) | |
, extension char(4) | |
, startdate DATE | |
, salary int); | |
insert into Employee (name, title, office, extension, startdate, salary) values |
OlderNewer