Feeds:
Posts
Comments

My first Home PHP project, IdeaForecasting, has yet to draw a great deal of interest, but most of the search engines have found it. In fact the Chinese have taken a great interest in the form of BaiDuSpider!

I wish the Idea of IdeaForecasting would take off, but I haven’t really publicized it yet. In the mean time I’m learning a great deal about PHP, MySQL and OpenSolaris.

At the Cork Open Coffee today there was discussion about how the University of Cork could be utilized to solve real world business problems, with a counterpoint that the University also was a resource for IP that was underutilized or not exploited at all. Answers without questions that had been explored and solved, but not yet marketed and deployed. And I thought of how that could happen.

I have always been boring, in most conversations I almost never initiate a subject, but I can always contribute (read; shoot my mouth off). This is true in my IT skills. I know many things, but I don’t create many new things, but I can solve most puzzles and resolve problems. And in reviewing them, I find it’s more to do with not having an agenda, or operating under a set of predefined solutions. I examine the issue, then produce an alternative resolution. I become creative in my solutions, I invent extraordinary resolutions. I remain empty, of any preconceived notion of a solution (not empty of ego mind you) but I exploit the Tao of the problem. Hence I don’t project a topic of conversation, or add a new project, or imagine anything extraordinary until I have a problem to solve.

This was my dilemma about the university folks, creating answers, where there were no questions (yet?). Applications, without anywhere to apply them. For me, IT problems ARE the mother of invention.


The Tao is like a well:
used but never used up.
It is like the eternal void:
filled with infinite possibilities.

Even though my workplace and reduced costs by migrating from Sybase on Solaris to Sybase on redhat. We are now in a move from Sybase to MySQL to further reduce the license costs of the applications. This has brought to forefront one of the reasons to use Sybase. Triggers and stored procedures. And while MySQL now provides both, and transactions in InnoDB engines, Sybase triggers and Procedure are far more advanced. This forms a type of trap, they are very useful, but create serious obstacles to convert triggers that perform Referential Integrity. Just to highlight two types of these issues, take the following;

You can not use ’select’ criteria in a trigger that returns a value. This prevents executing a select on a table to check for the existence of record prior to an insert/update. This was a major issue with a trigger used to produce a history file via a ‘update’ that had to both insert and update the history table. My workaround was to create a MySQL procedure that had no such restriction, and to call the procedure from the trigger. This worked very well, but of course meant that there was additional overhead and more coding involved.

The second example was, in my opinion, was a far more severe omission of Referential Integrity, ‘Rollback’! You cannot perform a rollback in a trigger. What! Further more, you have use ’set autocommit=0′ either as a database default, which it is not, by default, set. Or set it during the batch or client operation that you are performing. Twice bad! Again, my solution was to call a procedure that could perform a ‘rollback’ and to ensure that either the developer set autocommit off or to insure that it was set as a database wide option.

As easy as these solutions were, they highlight an omission of functionality that requires addressing in the future development of MySQL.

Sybase On Red Hat Linux

I’ve been installing Sybase 15.0.2 on several systems lately, both Core 2 Duo’s and quad Xeon’s and have been impressed with the ‘normalcy’ of the installations. With the one exception that they have all has a ’segmentation’ failure with the backup server during the initial ’startup’ script this is due to the omission of a shell variable LD_POINTER_GUARD=0 from the standard installation script. Once you add this element in the SYBASE.sh and source it, the backup server will start normally.

Best Quote from a friend

I never thought I’d get to be a Senior Programmer just by getting old!

One thing I’ve noticed about Twitter and Jaiku, is a common thread in IT, Scaleability! It’s an issue that I worked on in my days with AT&T Wireless. Mobile phone vendors have been dealing with SMS and voice connection transactions for many years and the volume of such transactions have only grown over the years since I had to deal with 25+ million transactions per day. If the current growing pains of these Web 2.0 social networking systems are projected, they are both headed for failure in the form of catastrophic system overload. While I admire innovative Ideas, like these services, their infrastructure does not appear well thought out. A bit more foundation in the infrastructure, and less optimism of the performance, should have been the first design requirement.

Being a database kind of guy, I can’t help but believe that a fundamental disconnect in the understanding of transactions utilized in these systems is the root cause here. I have yet to see a significant teaching or understanding of database issues in the current crop of programmers. There seems to be belief that data analysis is not a worth while task in current programming efforts. I see this in the form of articles detailing new ‘database’ products and methods, and new ‘lightweight’ database processes, etc. Mostly the requirements for ‘new’ DBMS and ‘Lightweight’ processes, is the underestimations of the data tasks of most modern IT functions. If you don’t know your own data, you don’t know anything. Any system that is not fundamentally tied in with a database system is merely a calculator.

I have monitored all the discussions of DRM with regards to Music and Movies, but until I started installing a Sybase ASE 15.0.1 installation, as a first stage to a Sybase 12.0 upgrade at the company which I work for, that I realized that Sybase must hate it’s own customers. I say this as that’s the only reason why they would use SYSAM and this draconian DRM license software in Version 15.xx. They want to put themselves out of business by pissing off their user base.  

My company have a contract with Sybase Ireland and I am an honest DBA installing a new version of Sybase ASE exactly like the one it will replace. I’m not trying to steal from Sybase. But this DRM assumes that I am a thief, and that I cannot be trusted. Even when we as a company pay thousands per year for support we barely use (because Sybase is a solid product). I’m a thief by their own DRM definitions.

We will be moving to MySQL, as soon as we are able, Sybase will be loosing yet another customer because of their suicidal  business plan.

 

I stumbled upon this article about Who Will Win the 2008 U.S. Presidential Election?. And realized that what they we claiming here was not a predictive method, but merely these people’s attempt to fit, to pattern match, ‘Presidential Electability’ factors to winners of elections. And making a half hearted attempt to apply these historical factors to up coming election. I’ll give you some examples, these are the factors they used in a previous ‘prediction’ Who Should Win the 2004 U.S. Presidential Election? they used factors like

if the candidate served as Director of Central Intelligence (e.g., George H. W. Bush), was a four- or five-star general officer in the United States Armed Forces (e.g., Dwight D. Eisenhower), or ordered the combat use of nuclear weapons (e.g., Harry S. Truman),

as you can see such ‘factors’ could only be applied to demonstrate why Truman beat Dewey, not as a general rule that proves the model.The factors used in the 2008 ‘prediction’ only suggest combinations of Presidential candidates , but can not predict them, because the factors are based on historical artifacts as part of the pattern matching, factors that can not be predicted in advance.

With that in mind there are no factors for emotional content, or future historical events.

They further go on to make this statement, We assume that major party primary voters are rational and will understand the empirical power of our algorithm. and we all know that voters for both nominees or candidates are not rational. And with a model that does not factor the level of ‘rational’ or irrationality of the electoral process, they can not forecast or predict. In other words, they can’t put their money where their mouths are.

They make another bold statement Readers of this paper could make a lot of money at Intrade.com if our assumption that major party primary voters are rational is correct. but you don’t see them making money.

The old adage is this, never take investment advice from a poor broker.

I’m in a Podcast

Come listen to my voice. Here

I was recently presented with The Code Book and while leafing through the pages during a moment of boredom I managed to create a simple crypto using the Julius Caesar character substitution method using Sybase T-SQL. And though I’m sure that the resulting encrypted text could be broken with brute force, it would not be easy, nor very worthwhile for most messaging.

In this world of spying and privacy invasion from all directions, a little personal crypto might be in order, particularly if one is inclined to be suspicious of commercial algorithms. and while this stored procedure is simple, it can be enhanced, feel free to use it for your own needs.

CREATE PROCEDURE dbo.simple_crypto
(
@key_word varchar(25),
@message varchar(255),
@direction varchar(8)
)
as

set nocount on

declare
@key_input varchar(20),
@key varchar(27),
@key2 char(27),
@olumn int, @olumnk int,
@input varchar(255),
@olumnb int,
@output varchar(255),
@out char(1), @a_char char(1),
@undone varchar(255),
@count int

select @count = 97, @olumnk = 1
select @key_input = lower(@key_word) –’branedy’
select @input = lower(@message)

create table #alpha (a_char char(1))

while @count <= 122
begin
insert into #alpha
values (char(@count))

select @count = @count + 1
end

select @key = char(32)

while @olumnk <= datalength(@key_input)
begin
select @out = substring(@key_input, @olumnk, 1)

delete from #alpha where a_char = @out

if @@rowcount = 1
begin
select @key = @key + @out
end

select @olumnk = @olumnk+1

end

select @key = @key + a_char from #alpha

drop table #alpha

select
@olumn = 1,
@olumnb = 1,
@key2 = ‘abcdefghijklmnopqrstuvwxyz{‘

—————–encrypt

if @direction = ‘Cipher’
begin

while @olumnb <= datalength(@input)
begin
select @output = @output + char(charindex(substring(@input, @olumnb,1), @key) + 96)
select @olumnb = @olumnb+1
end

select @input + ‘ = ‘ + @output as ‘Encrypted’

end
——————————————-decrypt

if @direction = ‘Decipher’
begin

select @output =@message

while @olumn <= datalength(@output)
begin
select
@undone = @undone+ char(ascii(substring(@key, charindex(substring(@output, @olumn,1), @key2),1))) –,
select @olumn = @olumn+1
end

select @output + ‘ = ‘ + @undone as ‘Decrypted’
end

——————————–

select ‘From the key ‘ + @key

return
GO

Older Posts »