Friday, April 21, 2006

Crystal Reports Strikes Again

Ok...

Besides the fact that Crystal Reports saves the development data WITH the report definition, I have stumbled with another weirdness of it.

Like almost everyone else we use two databases: one for development and one for production.

Because my boss here wanted to develop with a database server as similar as possible to the production server, he put the developement database on the same server where the production is. More similar than this I think it's impossible ;-)

Anyway... I completed the report design tested all the quirks and stuff, and it was ready to production.

When I put the report in production... BANG! There was the development data.

DAMN! I knew I did everything right, checked all the code, every single byte and nothing was wrong... Until I checked the damn Crystal Reports Definition File.

And there it was, hidden in plain sight: DevelopmentDatabase.dbo.TableName.

Yep! You guessed it right. In my case it doesn't matter if I change the ConnectionInfo to set the ProductionDatabase. Because the development and production database are in the same server, the SQL Server will always read from the development database.

WTF?!

Why?! Again, WHY?!

Let's thinkg for a moment, shall we?

We're creating a report engine tool that will be used with several different databases, with several different table names.

Developers tend to have two different environments: Development and Production.

We need to store the name of the table from where we will collect the data to print in the report.

How do we do this?

I don't know about people at BusinessObjects but I'd store only the table name, because development and production usually are VERY different from each other.

To make a long story short:

AFTER you change the ConnectionInfo property for each and every table in the Crystal Report Document, you need to set the Location of each table.

Wednesday, April 19, 2006

Crystal Rep... ARGH!!!

Today my boss asked me to build a report that needed to be printed from our web application.

So, me and my really stupid mouth said: "Sure, boss, I could use Crystal to build the report and then send a PDF to the browser." And everybody would be happy.

First a little explanation, the last time I have used Crystal Reports was the version shipped with VB3, almost 10 years ago. Back then it was a relatively good tool for creating reports, but sometimes we would just drop it and write the report by hand. On the good old days of Client-Server applications ;-)

Nowadays we don't have the luxury of having a connected printer on the client (because the client is the web browser) so the next best thing is a PDF that we send to the browser.

After this many years, I thouhgt that Crystal have evolved a little bit. And in fact it did.

But one thing remained... The damn dumb Saved Data.

Why?! In the name of the Lord, why?!

Why the developer of Crystal still needs to save data WITH the report?

It's just plain dumb.

I can't imagine one single reason for saving data with the report definition file.

Can anyone please tell me one, just ONE, single reason?

Tuesday, April 11, 2006

Hooray!!! Another one...

who have the guts to say that FireFox needs a LOT of improvements.

John Carroll, from ZD Net. You can find it here.

After a Long and Dark Winter...

For the last few months I was in a cave, figuratively. How can I say? I wasn't being myself.

When I started writing this blog I was unemployed, and thought it would be a useful way to keep my developer skills sharp. But after several month still unemployed I was hit by a mild depression.

After my home computer crashed I found myself unable to write anything useful, and in a way I've put this blog to rest.

Last month, after a long hunt, I've got a new job.

I'm working for a medium-sized data center, developing internal software. It's a very good place to work, and I found myself able to write again.

Soon you'll have more and more news and stuff.

Just a sneak preview of what's coming up next:

  • Auto-Complete text box
  • A very useful calendar control
  • FireFox rants... :-P

and much more...

So, stay tuned for the great rebirth.