Once again:
G1 is bricked. No alarm clock… No phone.. No sleep. It happened before, and they replaced my new phone with a refurbished one. Second time this happens in three months.
[rantmode]
Called rogers:
30 minutes wait on “”priority queue”". At 2AM that’s just 30 minutes wait. Yuppy!
30m on the phone with rogers staff that kept transferring me. After all they want to make sure I only get the best service possible…
Finally I get the “finest technical specialist”. Yes these were the exact words of the operator. He wisely advices me to remove my battery and put it back again, and then turn on the phone. Just to be safe he tells me to do it again. Guess what genius, it still doesn’t work! Of course I did this like five times just before calling, after all I wanted a working phone right?
We got to a point that he asked if I had my data backed up and I replied that I have my data “in the cloud”.
What the hell was I thinking?
I ask him if my answer “was satisfactory” and then the guy keeps repeating ”your answer was not satisfactory, and no that does not answer my question” in a hostile voice. This guy really hates buzzwords. More than I do.
So I tell him “you won’t frekin treat me like that, i’m your customer” and he answers that he “also has a family. And just because he works in a call center he still holds a college degree”. The college degree argument – always loved this one.
I give my normal reply to this kind of statement.
“I work at macdonalds and have no degree. Why does that matter?”
He hangs up on me….
Lesson learned: Technical specialists from call centers really hate people from macdonalds. Oh, and Rogers call center is really bad. The thing is I really wonder if the competition is any better? :\
I was looking for a branch of ScotiaBank in Markham. Tried their website and – I don’t know if it’s down or if it’s just me – but couldn’t really find the information! In the bottom however I did notice this link saying Branch Locations and I decided to give it a try:
Now I had a copy of all the branches in GPX 1.1, which is pretty useful but quite boring to just text search.
So I decided to use pureXML to do the work for me. I didn’t want to have to create a new database / table / etc so for the sake of saving time I decided to use the pureXML Industry Demo, which happens to support GPX. After inserting the document – added schema validation just to test it – I could now query the data and retrieve what I want using either XQuery or SQL/XML. According to that page all the XML documents are stored in a XML Column named DOCUMENT in the GPX table. So now I just need to translate to XQuery something like “get me all the ScotiaBank branches that are in Markham”. As I’m not really interested in creating elaborate spatial queries but just in getting things done I decided a simple text search would suffice.
XQuery
declare default element namespace "http://www.topografix.com/GPX/1/1";
for $branch in db2-fn:xmlcolumn('GPX.DOCUMENT')/gpx/wpt
where $branch/name/contains(.,'MARKHAM')
return $branch
And now here are the ScotiaBank branches that exist in Markham:
Enough for me. I got the addresses and phone numbers, I can now go to google maps and check it out. However if the amount of data was significant you could use XQuery / XSLT / Yahoo Pipes / etc to transform the data into KML and load it up automatically either in any map viewer of your choice.
In case you need to clean up a big mess and re-install fresh. From the shell / bash / your choice for a command line.
Drop all databases db2 "list database directory"
# For each database (replace $db with actual name)
db2 "drop database $db"
Login as the Administrative Server Owner (normally dasusr1) and stop it
su dasusr1 db2admin stop
Stop each of the DB2 instances that exist.
e.g. su db2inst1
db2 "force application all"
db2stop force
db2terminate
Remove the Administrative Server (replace V9.7 with current version. Install path might be different if the installation was personalized) sudo su
/opt/ibm/db2/V9.7/instance/dasdrop
Drop all the instances
e.g. # still as root, sudo su. Repeat for each instance.
/opt/ibm/db2/V9.7/instance/db2idrop db2inst1
# just in case you feel like using db2inst1 again while avoiding those nasty SQL1005N.
# reference: directory structure DB2 database Linux is available here
rm -rf /home/db2inst1/sqllib
rm -rf /home/db2inst1/db2inst1
Uninstall DB2 /opt/ibm/db2/V9.7/install/db2_deinstall -a
The execution completed successfully. Congratulations!
To reinstall you can either use db2setup (quite comprehensive and easy to use GUI) or if our a real *nix ninja you might want to consider db2_install and manually configuring all the necessary users / authorizations / etc.
In case you feel like messing up your system so you can use my guide to un-install DB2 but you don’t have DB2 – I can also help you with that. DB2 Express-C is completely free and has no limitations other than a maximum use of 2GB of ram and 2 processors. Sounds nice – try it! [http://www-01.ibm.com/software/data/db2/express]
If you would love to see blazing fast XML storage and querying you should also give pureXML a try [http://www-01.ibm.com/software/data/db2/xml]. It comes bundled with Express-C with exactly the same capabilities as the Enterprise version of DB2. I’m thinking of writing a beginners guide to pureXML somewhere in the future in the blog – maybe after the masters thesis. I think that would get everyone really excited about this technology. Maybe some screen-casts!
Interrompo o minha ininterruptível e infindável tese de mestrado devido a surpresa do dia – Um screencast sobre Rails, em Português. A notícias surge do estaminé do José Mota. A qualidade é surpreendente e é sem dúvida um primeiro episódio que promete. Se estavas a espera de uma oportunidade de aprender rails e não sabes o inguelish está aqui a tua oportunidade para aprender. O link, esse está aqui http://jose-mota.net/2009/08/rails-a-moda-do-porto-episodio-1. Boas aprendizagens.
Call to open-source enthusiasts: Don’t work on Google Chromium. You work in a open-source project that is the foundation for Chrome and then you don’t even get support for Linux?? What’s up twith all the non-implemented messages?
I’m not even talking about the fact that they should open-source ALL the code and considering the implications of these kind of open-source arrangements (that are far more frequent than one would initially think). I’m just talking of relying on open-source enthusiasts to improve their browser and than not even giving them the same that you get when using Windows.
Just found this JSON Grammar[1] on my daily searches. Also found a JSON validation tool[2] provided on by the json.org. Was quite surprised to find out that both do not include escaping the solidus character. First I thought maybe the images were old and not updated but after reading the RFC[3] I’m pretty sure this is not valid JSON:
Invalid: {
"a": "/",
"b": "\\"
}
Valid: {
"a": "\/",
"b": "\\"
}
Any thoughts? I noticed another little problem with the grammar:
{
"agent" : 007
}
While cool this is not valid JSON I mean we would all love the 007 number but, not in JSON! This might solve that problem:
Number : '-'? ('0'|Digit19 Digit+) ( '.' Digit+)?;
fragment Digit19
: '1'..'9'
;
Bottom line: Wouldn’t it be nice if the languages provided their own grammars so we all had a formal way of verifying if a string is (or isn’t) in a specific language?
UPDATE: Richard Clarke already updated the grammar. Kudos to him for keeping up an open JSON Grammar and updating it as soon as any error is reported. See comments for his insight about the issue.
Darkness at the break of noon
Shadows even the silver spoon
The handmade blade, the child’s balloon
Eclipses both the sun and moon
To understand you know too soon
There is no sense in trying.
Pointed threats, they bluff with scorn
Suicide remarks are torn
From the fool’s gold mouthpiece
The hollow horn plays wasted words
Proves to warn
That he not busy being born
Is busy dying.
Temptation’s page flies out the door
You follow, find yourself at war
Watch waterfalls of pity roar
You feel to moan but unlike before
You discover
That you’d just be
One more person crying.
So don’t fear if you hear
A foreign sound to your ear
It’s alright, Ma, I’m only sighing.
As some warn victory, some downfall
Private reasons great or small
Can be seen in the eyes of those that call
To make all that should be killed to crawl
While others say don’t hate nothing at all
Except hatred.
Disillusioned words like bullets bark
As human gods aim for their mark
Made everything from toy guns that spark
To flesh-colored Christs that glow in the dark
It’s easy to see without looking too far
That not much
Is really sacred.
While preachers preach of evil fates
Teachers teach that knowledge waits
Can lead to hundred-dollar plates
Goodness hides behind its gates
But even the president of the United States
Sometimes must have
To stand naked.
An’ though the rules of the road have been lodged
It’s only people’s games that you got to dodge
And it’s alright, Ma, I can make it.
Advertising signs that con you
Into thinking you’re the one
That can do what’s never been done
That can win what’s never been won
Meantime life outside goes on
All around you.
You lose yourself, you reappear
You suddenly find you got nothing to fear
Alone you stand with nobody near
When a trembling distant voice, unclear
Startles your sleeping ears to hear
That somebody thinks
They really found you.
A question in your nerves is lit
Yet you know there is no answer fit to satisfy
Insure you not to quit
To keep it in your mind and not fergit
That it is not he or she or them or it
That you belong to.
Although the masters make the rules
For the wise men and the fools
I got nothing, Ma, to live up to.
For them that must obey authority
That they do not respect in any degree
Who despise their jobs, their destinies
Speak jealously of them that are free
Cultivate their flowers to be
Nothing more than something
They invest in.
While some on principles baptized
To strict party platform ties
Social clubs in drag disguise
Outsiders they can freely criticize
Tell nothing except who to idolize
And then say God bless him.
While one who sings with his tongue on fire
Gargles in the rat race choir
Bent out of shape from society’s pliers
Cares not to come up any higher
But rather get you down in the hole
That he’s in.
But I mean no harm nor put fault
On anyone that lives in a vault
But it’s alright, Ma, if I can’t please him.
Old lady judges watch people in pairs
Limited in sex, they dare
To push fake morals, insult and stare
While money doesn’t talk, it swears
Obscenity, who really cares
Propaganda, all is phony.
While them that defend what they cannot see
With a killer’s pride, security
It blows the minds most bitterly
For them that think death’s honesty
Won’t fall upon them naturally
Life sometimes
Must get lonely.
My eyes collide head-on with stuffed graveyards
False gods, I scuff
At pettiness which plays so rough
Walk upside-down inside handcuffs
Kick my legs to crash it off
Say okay, I have had enough
What else can you show me?
And if my thought-dreams could be seen
They’d probably put my head in a guillotine
But it’s alright, Ma, it’s life, and life only.
Liked it, here’s more (added other artists for those who still don’t love Dylan):
Uma aplicação interessante vinda de uma start-up Portuguesa. Nada de betas fechados nem convites, portanto se estão interessados podem dar lá um saltinho. Descrito em poupas palavras e sem as habituais buzzwords o lappiz é uma rede social – keep reading, tinha que ser dito – para partilha conhecimento académico (leia-se, universitário).
O fixe disto tudo é que não é dirigido a professores nem outros interesses que não o de dar aos alunos suma melhor maneira de comunicar e partilhar conhecimento. É um produto bastante completo e que – na sua iteração inicial – foi fundamental para o meu (relativo)? (in)?sucesso como aluno. Se continuar com a mesma filosofia terá de certo um futuro risonho.
Pontos negativos: Isso da autorização para adicionar amigos é coisa do passado. Agora é follow a quem me apetecer, com opção para block.
Caso estejam interessados em saber um pouco mais sobre a start-up (assim como nas muito habituais buzzwords) podem ler este artigo da TeK.