29 October 2008

I have a bloody dream of software never written by a sane head

I have a couple of ideas. Development wise. Something I want to do on the side on my free time usually spent not being with my family but watching stupid tv shows and movies in order to free my mai9nd from all day developing in some stupid, soon to replace programming languages. But I digress.
I had several ideas today:
1. Writing an unit testing framework fro stored procedures in MySQL, written in MySQL for MySQl. I don't think those exists. And I think they are needed for the all continuous integration thingy. and I think uit would be an interesting idea to implement it. If , ever, I'm going to do that I'm going to open source it and host it on Google Code. Way cool idea, I must say. I'm impressed with my self.
2. Writing a microblogging service bus that will connect to other microblogging services of interest pool their data and present disperses them as a part of their aggregate feed.
Here it is how I envisioned it. It would be php based on REST. So simple pot and GET request. no fancy WSDL. XMl would be used to send data over the web each service bus will host data and provide service for one personal microblog (which would be accessed through a client, separately written in whichever technology I or someone chooses). Now the owner of the microblog would in theory register to someone else's microfeed, and pool their data as well as his whenever a microblog feed would be requested by a client (obviously mine and theirs feed would be differentiated). Each microblog would also post a service with commonly used words to link to a cluster of relate microposts, and a service listing other microblogs aggregating feeds from this blog.

3. For my next laptop which I will buy in a couple of years I'm going for a pure virtual platform. Here is what I want. A laptop with a fresh, fast , stable and lite linux install with VirtualBox or something better installed. And then several virtual machine , with various configurations(I may need to run several on the same time) , each used for a separate purpose - testing, development, home use, art... etc. Neat. I just can't wait for 2010 to come. Thats the year I'm going probably to get my new laptop. Maybe. If I'm lucky. Really lucky.
On the personal note, my son who just turned eleven months old and I barely see during the week started walking by him self. So no longer hand holding. No boy he is a home missile bent on general havoc and destruction. I love the little dynamo.
I work for nine hours a day, minimum, and drive for two hours plus one hour for waking up and doing morning stuff nobody needs to know. So I'm gone for twelve hours each day during the bloody week. And that my friends takes a toll, on me on may family on everybody. And of course when I get home I'm next to useless.

25 October 2008

Oracle , stored procedures and table statements

I drive for two hours every day to go to and from the work. In my car I hav an mp3 player and I spend those hours listening to trade podcasts. Mostly .NET rocks, FLOSS weekly and Stack Overflow. There are others , but they are not currently worth mentioning. I heard in one episode of .NET rocks that the internet is killing the software printing industry. They said that less and less people have time to read and study a book on any topic for several months before starting to work with the technology they were studying. Now, everybody uses Google.
Developers usually open their IDE, or editor, read some tutorials and then start coding. When they hit a problem they google the solution for it. Nobody reads. Nobody has the time to learn a technology that will change inside a year. I guess is true. Thats how I started doing it. Learning by googling. And really, I think thats the wrong way to do it.
See, here is my rationale. You can acomplish lots of thing by doing that. But I guarantee that you wont do it right, You are bound to miss some fundamental things. Or you are going to use the wrong solution for the problem you are facing. All things which would be easily avoided if you've taken time to learn a technology properly.
But thats not possible. You have so much to learn, so many possibilites. It is not possible to learn them throughly. It would take you all your working day to just keep up with all of that, I wish I could. But I can't.
What I do is pick a technology, buy a book or two and separate one hour a day, each working day to learn it chapter by chapter. These are technologies I like or think will be critical for my work for a longer period of time. Like SQL Server, or ASP.NET.
Now things will come that will require of me to learn something new just for one project. The technology in question may be extensive, but I don't have the time and the energy to learn it properly. In those cases I resort to Google to be my guide.
And thats what happened with stored procedures and Oracle. See, I'm kinda the db guy for my team. So for our latest project I got stuck doing database work besides my regular web work, Our client uses an Oracle database. We planned several stored procedures to handle all data transactions between the client and the database. Now, I haven't ever worked with Oracle and PL/SQL. And the project was way under way , so I didn't have much time to learn PL/SQL. So I started googling.
My first task was to create two procedures which would create some new tables and destroy them respectively. Some alter table statements were thrown in the mix.
Now , the first problem was that I couldn't do CREATE AND ALTER TABLE statements inside a stored procedure. I had to use EXECUTE IMMEDIATE, which runs all sorts of queries inside the stored procedure.
Now the following problem was that the created stored procedures couldn't create tables becuase my user couldn't explicitly do that . My user , which was handed to me by the client, received its permissions through roles. In order for a stored procedure created by my user to be able to create tables and so , my user must have the CREATE TABLE privilege granted to it specific.
Here is the code:

GRANT CREATE TABLE TO UserName;

CREATE STORED PROCEDURE TestProc
AS
BEGIN
EXECUTE IMMEDIATE 'CREATE TABLE TestTable (name VARCHAR2 NULL)';
END;

It took me two whole days to do that. Fantastic. One site that helped me a lot was this.

21 October 2008

Incompetent people piss me off

I'm so pissed when someone in the team does not do their job. I'm so angry. And what angers me most is when I have no power what so ever to compel them to do so. I can say something. I can remind that someone about what they must do, and I can even share the work weight with them which is the stupidest thing for me to do, since I'm not paid to work for two people. I'm not paid to do any of those things either. But I do them non the less.
I'm so pissed off.
I want the project to succeed. I want to advance in my career. I depend on my team mates doing their job so we can all succeed. Software development is not a single player activity. It takes several people to finish an average project. It doesn't take one, it takes several. But what if some of them do not want to do their job. What if some want to sit in their chair, do nothing except reading funny papers on the internet and saying: I don't know anything, I don't know how to do that bla ... bla... bla...
Move your ass, god dammit. You retarded morons. Why did you even applied for this job if you didn't want to work and commit your self? Why! There are plenty of government founded jobs for those type of people. Leave room for someone who wants to work.

20 October 2008

Fighting to learn

Learning things is hard. It takes time and resources, not to mention will. The older I get the harder it is. I think that's true for every body. I just read a blog post from Ethan Vizitei and I couldn't agree more with what he said. I don't know. This is something that was bothering me for a long time. See I'm a learner. I like to learn, I want to learn. I want to better my self.
I've been doing it since I was a boy. Learning to program, learning to write, learning a new trade or skill. Always learning, always being a target of those who do not. I had a rough child hood. My learning separated my from my peers. People do not like those who separate them selves from the mold. I knew things , I wanted to know things and people reacted violently when I showed my knowledge. Verbally and physically.
Bastards.
When I grew older and bigger, when I started lifting weights people stopped being physical with me . I moved away, started working in the industry and baam. They still were there, those who refuse to learn.
Its OK, that's their decision. I accept that. But the sheer amount of energy those people used to deter others from learning and introduce new things is amazing. I just always kept finding my place in knowing what others didn't (not something unusual per se) for the sheer fact I willed my self to explore and learn those things. How can anyone evolve as a software developer if not by constantly learning new things?
It's just tiresome talking with those people. Explaining things to them, listening to their half baked rationale why things should remain the same. It is so hard, it is so depressing and so fruitless. You can change people, you just cant... But refusing to learn, refusing evolve is not something I will settle for.