Skip to content

Instantly share code, notes, and snippets.

View booyaa's full-sized avatar
🏠
Working from home forevah!

Mark Sta Ana booyaa

🏠
Working from home forevah!
View GitHub Profile
@booyaa
booyaa / gist:4110981
Created November 19, 2012 14:38
RIBCL Example for changing ILO password for a given login
<!-- RIBCL Sample Script for Integrated Lights-Out -->
<!-- Copyright (c) 2003 Hewlett-Packard Development Company, L.P. -->
<!-- Description: This is a sample XML script to modify an existing -->
<!-- user's login id, display name, password and/or -->
<!-- privileges in the database of local users on an -->
<!-- iLO device. -->
<!-- NOTE: You will need to replace the values inside the quote -->
<!-- marks with values that are appropriate for your -->
@booyaa
booyaa / gist:4110985
Created November 19, 2012 14:39
RIBCL Example for setting Host power settings
<!-- RIBCL Sample Script for Integrated Lights-Out -->
<!-- Copyright (c) 2003 Hewlett-Packard Development Company, L.P. -->
<!-- Description: This is a sample XML script to toggle the power -->
<!-- on the host server in which the iLO is executing. -->
<!-- NOTE: You will need to replace the USER_LOGIN and PASSWORD -->
<!-- values with values that are appropriate for your -->
<!-- environment. -->
@booyaa
booyaa / castlemaine-conf.js
Created December 2, 2012 17:45
castlemaine - nodejs tool to convert foreign exchange currencies
module.exports = {
apiKey : 'YOUR OPEN EXCHANGE RATES API KEY'
, sourceCcy : 'USD'
, targetCcy : 'GBP'
}
@booyaa
booyaa / pocketCal.js
Created December 3, 2012 21:05
pocket calendar - generates a pdf from calendar year
#!/usr/bin/env node
// kinda works
// npm modules: pdfkit
// pre-req is a calendar file: ncal -y > 2012.txt
// usage ./readCal.js
var fs = require('fs')
, path = require('path')
, PDFDocument = require('pdfkit')
@booyaa
booyaa / gist:4260210
Created December 11, 2012 16:49
UPDATE query with join
UPDATE f
SET isAwesome = 1
FROM foo f
INNER JOIN bar b
ON f.id = b.id

Got this gem (paraphrased by me) from a fellow cow-orker whilst on a soft skills course:

A department of developers are analogous to a cricket team, as infrastructure/ops support are to a football team. We're a group of specialists, who move together as one, with a common goal of making the business successful. However at the end of the day the batsman still has to hit the ball all by his or herself. The rest of the team can't help them do this.

@booyaa
booyaa / SSISandOracleBFF.mkd
Last active December 11, 2015 02:29
Making SSIS and Oracle play nice

##Packaged stored procedures carp with the following error

failed with the following error: "ORA-01858: a non-numeric character was found where a numeric was expected

Add this to the end of your Oracle Connection Manager: UseSessionFormat=true

##Codepage warnings

Update this property in your Oracle ConnectionManager

@booyaa
booyaa / gist:4585277
Last active December 11, 2015 10:18
Useful Lotus Notes toolbar formula buttons

###OpenByReplicaID

@Command([FileOpenDBRepID];@Prompt([OkCancelEdit]; "Enter Replica ID"; "I will open the db based on Replica"; "00000000:00000000"))

###ViewReplicaID

@Prompt([OkCancelEdit]; "Replica ID"; "Copy the code below"; @ReplicaID)

###View Db Props

@booyaa
booyaa / SQLtoXML.mkd
Last active December 11, 2015 17:28
SQL to XML

####Oracle (requires r11.2 or better)

It's easier to break down the query into pieces. You have the following table:

songtitle               | artist
final countdown         | europe
hello                   | lionel richie
never gonna give you up | rich ashley

You'd like it to look like this

@booyaa
booyaa / OracleVersionSniffing.sql
Created January 25, 2013 14:32
Oracle Version Sniffing
clear
SET HEAD ON
SET VERIFY OFF
col instance_name form a8 Heading "Instance"
col name form a8 Heading "DB Name"
col host_name form a12 Heading "Hostname"
select version
,name
,log_mode
,host_name