More on BSB’s

Ever since I started posting about Australian Payment Systems, I’ve been getting lots of hits on the site from people searching for a list of BSB numbers.

This list can be purchased, but lots of people are searching for a free copy on the net and I’m not sure why.

If you have a deposit showing up on your bank statement and you can’t work out who it’s from,  contact your bank or try this site which lets you lookup the details for a given BSB  [2009-08-07 – link deleted at APCA request]

If you’re after the BSB of your own account, don’t assume you can get the right one from looking up a list – you really need to check with your bank!

If you are building an application and you want to validate BSB’s that people enter, then you don’t just need the list now, you also need to keep up to date with changes to the list, so you really should go buy a subscription. On the other hand, if you don’t mind annoying people by rejecting their BSBs if someone opens an account at a new branch, then there’s a copy of the list (dated 22 Nov, 2002) on the go software download page (look for bank.exe) [2009-08-07 – link deleted at APCA request]

And if you’re just curious about what banks there are, this table might be what you’re after:

Bank Number Bank Code Bank Name BSB’s
01 ANZ ANZ Banking Group 1097
03 WBC Westpac Banking Corporation 1434
06 CBA Commonwealth Bank 1692
08 NAB National Australia Bank 2151
09 RBA Reserve Bank of Australia 7
10 BSA Bank of South Australia 198
11 STG St. George Bank 88
12 BQL Bank of Queensland 120
14 PIB Primary Industry Bank 1
15 T&C Town & Country Bank 7
18 MBL Macquarie Bank 20
19 ADV Advance Bank (Now St George) 11
21 CMB Chase Manhattan Bank 44
23 BAL Bank of America 4
24 CTI Citibank 11
26 BTA Bankers Trust Australia 20
29 BOT Bank of Tokyo – Mitsubishi (Australia) 2
30 BWA BankWest 137
33 STG St. George Bank 106
34 HBA HSBC Bank Australia 38
35 BOC Bank of China 2
36 IBJ IBJ Australia Bank 2
40 CST Colonial State Bank 535
41 DBA Deutsche Bank AG 2
42 TBT Trust Bank 30
45 OCB Oversea-Chinese Banking Corporation 4
46 ADV Advance Bank (Now St George) 14
48 MET Suncorp-Metway 407
52 TBT Trust Bank 122
55 BML Bank Of Melbourne 157
57 ASL Australian Settlements Limited 25
63 BAE Bass & Equitable Building Society 1
63 BBL Bendigo Bank 25
63 GBS Greater Building Society Ltd 5
63 HBS Heritage Building Society 999
64 AUB Australian Unity Building Soc Ltd 1
64 IMB Illawarra Mutual Building Soc Ltd 2
64 IOF IOOF Building Society Ltd 1
64 MBS Greater Building Society Ltd 1
64 MMB Maitland Mutual Building Soc Ltd 1
64 MPB Mackay Permanent Building Soc Ltd 1
65 BAY Wide Bay Capricorn Building Society 53
65 PPB Pioneer Permanent Building Soc Ltd 2
65 ROK The Rock Building Society Limited 1
66 SUN Suncorp 1
70 CUS CreditLink 36
73 WBC Westpac Banking Corporation 1232
76 CBA Commonwealth Bank 1585
80 CRU Credit Union Services Corporation (Cuscal) 234
90 APO Australia Post 60
91 ARA Arab Bank Australia 12
91 FNC Bank One 11
91 MCB Mizuho Corporate Bank 1
91 SSB State Street Bank and Trust Company 1
92 ING ING Bank (Australia) Limited 1
92 MID HSBC Bank plc 4
92 UOB United Overseas Bank 1
93 AMP AMP Bank 9
93 ICB International Commercial Bank of China 2
94 BCY Bank of Cyprus 9
94 LBA Laiki Bank 7
94 MEB Members Equity Bank 2
94 TBB Taiwan Business Bank 1

rendering html in firefox from irb

Here’s a Firefox version of yesterday’s script to render html from irb.

For best results, go to about:config and set to 1 (or from the menu, go to tools->options->tab, and set "open links from other applications in:" to "the most recent tab/window")

here’s the script:

require ‘base64’ 
class Firefox

 #edit to suit
 @@firefox_path=’C:\Program Files\Mozilla Firefox\firefox.exe’

 def Firefox.html_as_data_uri(html)
      ‘data:text/html;base64,’+ Base64.encode64(html).gsub("\n", ”)

 def Firefox.show_html(html)
  #can’t use fork on windows
  IO.popen("#{@@firefox_path} #{Firefox.html_as_data_uri(html)}")

rendering html from irb

for the last few weeks I’ve been doing some fairly tedious documentation stuff, e.g. pulling together ‘requirements‘ from out of different word docs into a single list, categorising them (e.g. into ‘functional’, ‘non-functional’, ‘future’) and then creating a new table for each group that lists each requirement with an ID, a description, and a link back to the original source document.

I’m not going to explain why I need to do all that, it’s just The Way Things Are Done Around Here.

So I’ve been using word automation to extract the source docs as html, like this:

def get_html_from_doc(docname)
 	winword ='word.application')
tempfile.close #word reopens it
winword.Quit unless winword.nil?

then Rubyful Soup to pull the data from html tables into some linked hashes, which were saved as yaml. Once the data was a collection of ruby objects, I could modify it interactively with irb, then turn it into html. However while irb would happily print out the html source, if I wanted to see how that html would display I needed to first save it to a file, then load that file into IE. That got boring pretty quickly, so I put together this little routine to pipe a html string straight into a MSHTML control.

require 'win32ole'

class ShowHTML

def ShowHTML.create_new_window'InternetExplorer.Application')
#check our window is still around
rescue WIN32OLERuntimeError

def ShowHTML.show_hash(hash)

Here’s a screenshot of how this looks:
displaying html from irb
irb (foreground) displaying the ENV hash in a html window (background)