Converting ogg file to mp3 format with Sound Converter

August 11, 2011

It’s the holiday season. The English summer rain serves only to sharpen the anticipation of the foreign sun that you will be enjoying in the not too distant future.
There is only one problem. How do you take your music collection with you when it’s all in ogg format and you don’t have a handy Android device to transfer it onto.

Step forward Sound Converter – another in the seemingly endless supply of really useful open source utilities for Linux.

NOTE – I’ve tried this on both Ubuntu and Mint and, as you’d expect, the steps are the same. The screenshots in this post are taken from Mint because the novelty still hasn’t worn off yet :-) Read the rest of this entry »

Minty Freshness

August 8, 2011

“Oohh, you’re all minty”, is just the sort of thing I’d like Deb to say to me just after I’ve brushed my teeth in the morning. Most of the time though, I have to content myself with some muffled threats and demands for coffee. My beloved is definitely not a morning person.

I’m typing this in a shiny new version of Libre Office and my eyes are slowly becoming accustomed to the lack of brown and purple and the preponderance of green on the desktop.

Yes, I’ve decided to give Linux Mint a try… Read the rest of this entry »

If you can’t do it in PL/SQL, do it in SQL

July 31, 2011

The tension was palpable on the bridge of The Enterprise. The hulk of the giant Teredation Cruiser filled the View Screen.

With baited breath they awaited the response of the Teredation Captain to the message they had just transmitted.

Suddenly the image on the screen changed from that of the menacing warship to Simon, Lord High Hatter of the Teredations. In a voice which hinted at an unaccustomed uncertainty, he exclaimed,
“What is this PL/SQL of which you speak ?”

OK, so maybe it wasn’t the bridge of the Enterprise so much as in the beer garden at the Nut and Squirrel. The question, however, is pretty much accurate.

In an attempt to distract himself from the sad news that Claude Gnapka had finally left Luton for Walsall, Simon posed the following programming problem :

He needed a SQL query to return the first working day on or after the 23rd of the month, together with the first working day of the following month. He wanted both dates to be returned in the same row.
The catch ? Simon works on Teradata which, owing to a glitch in the Universal Translator ( or something), doesn’t have anything like PL/SQL or T-SQL built in. Read the rest of this entry »

DBMS_APPLICATION_INFO – Are we nearly there yet ?

July 23, 2011

Deb has come to the conclusion that, when on a long car journey, I’m not a great passenger.
“Are we nearly there yet ?” I enquire politely…usually around five minutes into a four-hour journey.
“No, not yet”, comes the patient reply.
“Are we almost nearly there yet ?”
“No, I’ll let you know when we are”, she responds with iron patience.
A few minutes pass…
“Are we almost nearly almost there ?”
At this point, I’m usually offered the option of walking the rest of the way.
It’s the same with long-running programs on the database. I want to know how far it’s gone and how far it’s got to go.
Oh, what Deb would do for an in-car equivalent of DBMS_APPLICATION_INFO.

Deb would probably have some sympathy with the DBA who gets a call from a user who has a process running and is, essentially, asking “are we nearly there yet ?”
Fortunately, with a bit of foresight and the judicious application of a little DBMS_APPLICATION_INFO magic, the answer to this question is right there in V$SESSION, or even V$SESSION_LONGOPS. Read the rest of this entry »

The Oracle Database – Where’s the “Upgrade Now” button ?

July 5, 2011

Regular readers of this blog ( hello Mum) will have noticed that I’ve been a bit quiet lately.
Having tired of my life of leisure, I now have a proper job and have consequently been a little bit busy.

I have though, had time to reflect on the question of Oracle database upgrades and why they are never ever standard.

“We’ve decided to upgrade the database”. Those words are bound to strike equal amounts of anticipation and abject terror into the heart of any DBA…or at least, any DBA who has gone through an upgrade before.

To be fair, it’s not the upgrade itself that is going to cause the problem, it’s all of the misconceptions that come with it.

The CIO/IT Manager/Project Manager is almost bound at some point to come out with one of the following gems :

“We don’t need to test, the application code will still work in exactly the same way”
“We need to upgrade/move our servers/Application/Operating System anyway so we can do it all at the same time to minimize downtime.”
“According to the salesman Oracle can now make the tea, so it must be true.”

My personal favourite is from a person who shall remain nameless :

“We want to be fast-followers. X team is upgrading their database in July so we should be done by June”. Read the rest of this entry »

PL/SQL Injection – The Doctor Will See You Now

June 16, 2011

Following on from my recent post about SQL Injection I had an excellent comment from Gary.

Whilst we’ve been able to establish that the PL/SQL solution we implemented does not suffer the same vulnerability to injection as the concatenated SQL statement, this does lead us to a further question – does using PL/SQL automatically render us immune from injection attacks ?

For the purposes of this post, I’m going to leave PHP to one-side and concentrate on the PL/SQL side of the matter. Read the rest of this entry »

Oracle, bind variables and SQL Injection – Keeping out unwanted guests

June 7, 2011

My son, Michael ( yes, it is the only name I can spell), is currently following in his father’s footsteps and studying Computer Science.
As is only natural, he does occasionally have the urge to rebel against all that his parents hold dear. In his case he’s rejected the path of light and Linux and has become … a Microsoft Certified Professional. Oh the shame. Where did I go wrong ?
All of which links, if somewhat tenuously, to the subject at hand. When he took his first steps into the world of programming, we had a look at PHP ( as part of a LAMP set-up, naturally).
In one of the introductory manuals, we came across an example of how to authenticate web users against a database.
The author was clearly trying to introduce various language concepts and would certainly not claim that his example was intended for production use. However, with a bit of tweaking for use against an Oracle database, it does offer a very clear illustration one area of the potential vulnerabilities of web applications to SQL Injection attacks. It also offers the opportunity to illustrate a major benefit of using bind variables in queries against Oracle – i.e. protection against SQL Injection.

I know that a fair few people who stumble across this site are new to Oracle and want to play around with Oracle XE. These people are also usually pretty experienced in other technologies (hi Wayne, hope you’re still enjoying all that sunshine).

So, the purpose of this post is to :

  • Illustrate the way in-line SQL statements can be injected
  • Show how this can be countered in an Oracle database by use of bind variables
  • Have a look at letting Oracle handle user authentication
  • Celebrate the visionary genius of Messrs Young, Young and Johnson. “For Those About to Rock” was not merely an album of raucous Blues-based Heavy Metal, but a prophecy about the potential pitfalls of Web Application development.
  • Oh, and give you the chance to laugh at my PHP prowess ( or lack thereof)

Read the rest of this entry »

Using Flashback for Automated Testing – a stepping-stone to World Domination

May 26, 2011

As I’m between jobs at the moment, I’ve had time to sit and reflect on possible future career directions.
With Deb’s help and inspiration (“if that washing isn’t done by the time I get back, there’ll be trouble!”) I think I may have come up with something.
Yep, I’m looking into the possibility of becoming an Evil Genius and Megalomaniac. After all, I’ve already got the alter-ego – I mean, “The Anti-Kyte”, that’s never going to be a super hero name, is it ?
Apart from that, there’s also the costume to consider. Let’s face facts here, mine is just not a figure that would be flattered by brightly coloured spandex.

If I’m going to run an efficient evil empire, I’ll need a properly designed and efficient data-driven application. Everything must be thoroughly tested. The temperature control on the piranha tank failing or some meddling super-spy escaping the cunningly planned trap at a crucial moment could do untold damage to the share price.
A suite of automated tests that I can run repeatedly to verify both functionality and performance under load is a must-have.
In that case, I’m going to need a way of running my test suite, then quickly rolling back the resultant database changes, fixing any problems and running it all over again.
It’s time to take a fresh look at the Flashback functionality available in the Oracle Database. Read the rest of this entry »

Oracle XE – Speeding up Startup and getting Nofications on the Desktop in Ubuntu

May 16, 2011

Oh the tension. 2-0 up at half-time. Visions of last-day drama and an eleventh-hour escape floating tantilisingly before my eyes. Then, grim reality. A second-half collapse and the prize is snatched away once more. So, this is what it must be like to be an Arsenal fan.
I know that they say misery loves company, but it’s not really any consolation. Yes, my beloved West Ham have been relegated from the Premiership.

In an effort to rouse myself from the resultant depression, I decided to have a look at addressing one of those minor annoyances that I’m always intending to get around to but somehow never quite do. In this case, it’s how to get confirmation that my Oracle XE database has started before trying to connect to it ( and that it’s shut down before I turn off my computer). Read the rest of this entry »

Android Phone as a Wireless Hot-Spot

May 14, 2011

I have finally got around to having a proper play with my new(ish) Android Phone.
In doing so, I’ve discovered that :

  • it can read music files in ogg format ( good old Linux)
  • yes, Angry Birds IS addictive
  • it works very nicely as a Wireless Hot-Spot.

A quick tour through the toys I’m using for this particular exercise.
The Emachines E350 netbook running good old Ubuntu 10.04.2 is the computer. Yes, this should work on Windows as well, if your that way inclined.
The phone in question is an HTC Desire S running Android 2.3.3
Read the rest of this entry »


Follow

Get every new post delivered to your Inbox.

Join 57 other followers