Saturday, 8 May 2004

Upgrading to Kernel 2.6

Due to various technicality issues arising from incompatibilities with my kernel 2.5, I was forced to upgrade to 2.6 (on the laptop here)

So a quick check, and then by force having to reboot back to 2.4 to do it,
I upgraded, and a few things didn't work. I needed to add a line in /etc/netowkr/interfaces
eth2 inet dhcp auto

# or similar and /etc/modules
psmouse

The first, (eth2) my PCMCIA wireless network card moved to eth2 (when under 2.4 and 2.5)
it was eth1.

At the psmouse, it's a new module needed for the PS2 type interfaces, of which my Trackpad on the Vaio lappy
is one.

So .. a quick, 40 mins of play and Im up to 2.6.5 .. not bad for a days work.

Thanks Linux (and debian) for making this all possible.!
(love it)

Thursday, 8 April 2004

Some JS Links to Fancy

Always looking for some links to deal with JS, specifically, obfucating it.

See this link for more links on compressing, stripping, crunching and obfuscating JavaScript (ECMAScript)

Optimizing JavaScript

This link (from above link) has worked best at the moment (didn't break the 23k JS file we had)

Script Squisher

Thursday, 11 March 2004

Sybase output parameter issue with ColdFusion

Using Sybase 12.5 we have a stored procedure that
returns a string in an output parameter.

The Stored procedure is declared like

create proc sp_foobar
@pc_char1 char(10),
@pi_int1 int,
@pvc_vc1 varchar(512),
@pc_char2 char(6),
@pvc_vc2 varchar(40),
@pvc_vc3 varchar(255),
@pb_bit1 bit,
@pvc_vc4 varchar(20),
@pvc_return_code varchar(30) output
as


...

In ColdFusion, we were calling the stored procedure as follows.













But this throws an error,

[Macromedia][Sybase JDBC Driver][Sybase]Operand type clash: VARCHAR is incompatible with VOID TYPE

and it highlights the last cfprocparam (the output variable).as the issue

I worked out that if you pass it a value="" parameter, it stops it from failing.. ie



The sproc, in this example as part of it's internal logic/contract returns "SPROC_SUCCESS" as it's varchar, in @pvc_return_code. What Coldfusion puts in this
v_return_code is now equal to only the first letter. (ie 'S')

Hrmmm, .. so .. I worked a way around this one also... A Fix for this BUG .. make the 'value=""' a string as long as the string you expect to be returned. eg,



and then you would get #v_return_code# equal to "SPROC_SUCCESS"

Odd, any takers? Someone SURELY has seen this before.

Current 5 booksmarks @ del.icio.us/pefdus