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
/* Add a sale */ | |
CREATE OR REPLACE PROCEDURE add_sale( | |
v_cust_id customers.id%TYPE, | |
v_prod_id products.id%TYPE, | |
v_qty sales.qty%TYPE | |
) | |
IS | |
v_price_single products.price%TYPE; | |
v_price_total sales.price%TYPE; | |
BEGIN |
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
/* check that there is enough quantity */ | |
CREATE OR REPLACE TRIGGER check_enough_stock | |
BEFORE INSERT ON sales | |
FOR EACH ROW | |
DECLARE | |
v_qoh product.qoh%TYPE; | |
e_not_enough_stock EXCEPTION; | |
BEGIN | |
SELECT qoh INTO v_qoh | |
FROM products |
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
[hamstar@behemoth:/etc] ?? dig localdomain. | |
; <<>> DiG 9.7.3 <<>> localdomain. | |
;; global options: +cmd | |
;; Got answer: | |
;; ->>HEADER<<- opcode: QUERY, status: SERVFAIL, id: 15303 | |
;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 0, ADDITIONAL: 0 | |
;; QUESTION SECTION: | |
;localdomain. IN A |
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
// | |
// Do any local configuration here | |
// | |
// Consider adding the 1918 zones here, if they are not used in your | |
// organization | |
//include "/etc/bind/zones.rfc1918"; | |
// Reverse DNS | |
zone "0.0.10.in-addr.arpa" { |
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
/* | |
* To change this template, choose Tools | Templates | |
* and open the template in the editor. | |
*/ | |
package Enums; | |
/** | |
* | |
* @author fwm8280 |
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
class TaskFactory { | |
public void save( Task task ) { | |
HashMap data = new HashMap<>(); | |
data.put("Name", task.getName() ); | |
data.put("Description", task.getDescription() ); | |
// etc... | |
if ( task.isNew() ) { |
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
package Helpers; | |
import java.util.Observable; | |
import java.util.Observer; | |
import java.util.Vector; | |
/** | |
* @author Shane van Wyk [GFN5594] | |
* @author Robert McLeod | |
* @since 02/10/2011 |
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
#!/usr/bin/env bash | |
# This is an RVM Project .rvmrc file, used to automatically load the ruby | |
# development environment upon cd'ing into the directory | |
# First we specify our desired <ruby>[@<gemset>], the @gemset name is optional. | |
environment_id="ruby-1.9.3-p0@captor" | |
# | |
# Uncomment following line if you want options to be set only for given project. |
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
PROMPT='%{$fg_bold[red]%}➜ %n%{$fg_bold[white]%}@%{$fg_bold[green]%}%m%{$fg_bold[white]%}:%{$fg[cyan]%}%/ %{$fg_bold[blue]%}$(git_prompt_info)%{$fg_bold[blue]%} % %{$reset_color%}' | |
ZSH_THEME_GIT_PROMPT_PREFIX="git:(%{$fg[red]%}" | |
ZSH_THEME_GIT_PROMPT_SUFFIX="%{$reset_color%}" | |
ZSH_THEME_GIT_PROMPT_DIRTY="%{$fg[blue]%}) %{$fg[yellow]%}✗%{$reset_color%}" | |
ZSH_THEME_GIT_PROMPT_CLEAN="%{$fg[blue]%})" |
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 | |
class EventNotFoundException extends Exception{}; | |
class Event extends SuperModel { | |
protected $TABLE = 'event'; | |
protected $db_fields; | |