Sybase NNTP forums - End Of Life (EOL)

The NNTP forums from Sybase - forums.sybase.com - are now closed.

All new questions should be directed to the appropriate forum at the SAP Community Network (SCN).

Individual products have links to the respective forums on SCN, or you can go to SCN and search for your product in the search box (upper right corner) to find your specific developer center.

Detect changes in a BLOB column?

6 posts in Trigger Last posting was on 2012-03-19 15:20:46.0Z
Thomas Steinmaurer Posted on 2003-10-27 23:32:50.0Z
From: "Thomas Steinmaurer" <ts@iblogmanager.com>
Newsgroups: Advantage.Trigger
Subject: Detect changes in a BLOB column?
Date: Tue, 28 Oct 2003 00:32:50 +0100
Lines: 12
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 5.50.4807.1700
X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4910.0300
NNTP-Posting-Host: 62.46.227.87
Message-ID: <3f9dabc1@solutions.advantagedatabase.com>
X-Trace: 27 Oct 2003 16:35:29 -0700, 62.46.227.87
Path: solutions.advantagedatabase.com!solutions.advantagedatabase.com!62.46.227.87
Xref: solutions.advantagedatabase.com Advantage.Trigger:5
Article PK: 1136074

Hi there,

the <> operator is applicable to several datatypes except BLOBs.

I can check whether a BLOB column IS NULL or IS NOT NULL,
is there a way to detect changes in a BLOB column in an SQL script
based trigger?

Thank you,
Thomas


Jeremy D. Mullin Posted on 2003-10-28 16:05:59.0Z
From: Jeremy D. Mullin <IHateSpamjeremym@extendsys.com>
Newsgroups: Advantage.Trigger
Subject: Re: Detect changes in a BLOB column?
Date: Tue, 28 Oct 2003 09:05:59 -0700
Message-ID: <MPG.1a0841ce7458c833989bd2@solutions.advantagedatabase.com>
References: <3f9dabc1@solutions.advantagedatabase.com>
Organization: ESI
X-Newsreader: MicroPlanet Gravity v2.30
NNTP-Posting-Host: 198.60.232.45
X-Trace: 28 Oct 2003 09:10:17 -0700, 198.60.232.45
Lines: 25
Path: solutions.advantagedatabase.com!solutions.advantagedatabase.com!198.60.232.45
Xref: solutions.advantagedatabase.com Advantage.Trigger:6
Article PK: 1136077

Hi Thomas,

There isn't currently, but Alex brought up a good idea for 7.1. We've
recently added some CRC stuff for other features, and we could try to
add a scalar function that returns a CRC of the blob data. That CRC
value could be used to compare two blobs.

J.D. Mullin
Advantage R&D

In article <3f9dabc1@solutions.advantagedatabase.com>,
ts@iblogmanager.com says...

> Hi there,
>
> the <> operator is applicable to several datatypes except BLOBs.
>
> I can check whether a BLOB column IS NULL or IS NOT NULL,
> is there a way to detect changes in a BLOB column in an SQL script
> based trigger?
>
> Thank you,
> Thomas
>
>
>


Thomas Steinmaurer Posted on 2003-10-28 18:05:50.0Z
From: "Thomas Steinmaurer" <ts@iblogmanager.com>
Newsgroups: Advantage.Trigger
References: <3f9dabc1@solutions.advantagedatabase.com> <MPG.1a0841ce7458c833989bd2@solutions.advantagedatabase.com>
Subject: Re: Detect changes in a BLOB column?
Date: Tue, 28 Oct 2003 19:05:50 +0100
Lines: 27
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 5.50.4807.1700
X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4910.0300
NNTP-Posting-Host: 62.46.231.136
Message-ID: <3f9eb0b9@solutions.advantagedatabase.com>
X-Trace: 28 Oct 2003 11:08:57 -0700, 62.46.231.136
Path: solutions.advantagedatabase.com!solutions.advantagedatabase.com!62.46.231.136
Xref: solutions.advantagedatabase.com Advantage.Trigger:7
Article PK: 1136078

Hi Jeremy,

> There isn't currently, but Alex brought up a good idea for 7.1. We've
> recently added some CRC stuff for other features, and we could try to
> add a scalar function that returns a CRC of the blob data. That CRC
> value could be used to compare two blobs.

That's exactly the same way how I'm doing that with InterBase/Firebird.
IB/FB supports external user-defined functions, and what I've done is
that I wrote an UDF in Delphi, which returns the CRC for a BLOB.

So I'm able to do something like:

IF (F_CRC(OLD.BLOBCOLUMN) <> F_CRC(NEW.BLOBCOLUMN))
THEN ...

So far it works like a treat with text and binary data.


Regards,
Thomas


"Thomas Steinmaurer" <t.steinmaurer Posted on 2004-04-02 20:15:03.0Z
From: "Thomas Steinmaurer" <t.steinmaurer@_no_upscene_spam_.com>
Newsgroups: Advantage.Trigger
References: <3f9dabc1@solutions.advantagedatabase.com> <MPG.1a0841ce7458c833989bd2@solutions.advantagedatabase.com>
Subject: Re: Detect changes in a BLOB column?
Date: Fri, 2 Apr 2004 22:15:03 +0200
Lines: 19
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 5.50.4807.1700
X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4910.0300
NNTP-Posting-Host: 62.46.233.22
Message-ID: <406dcb07@solutions.advantagedatabase.com>
X-Trace: 2 Apr 2004 13:20:23 -0700, 62.46.233.22
Path: solutions.advantagedatabase.com!solutions.advantagedatabase.com!62.46.233.22
Xref: solutions.advantagedatabase.com Advantage.Trigger:39
Article PK: 1136106

Hi Jeremy,

> There isn't currently, but Alex brought up a good idea for 7.1. We've
> recently added some CRC stuff for other features, and we could try to
> add a scalar function that returns a CRC of the blob data. That CRC
> value could be used to compare two blobs.

Do you know, if something comparable to a scalar CRC function, for
detecting blob data changes, will be available in 7.1?


Thanks,
Thomas Steinmaurer
LogManager Serie - Logging/Auditing Suites supporting
InterBase, Firebird, Advantage Database and MS SQL Server
Upscene Productions
http://www.upscene.com


Jeremy D. Mullin Posted on 2004-04-07 22:29:10.0Z
From: Jeremy D. Mullin <no@email.com>
Newsgroups: Advantage.Trigger
Subject: Re: Detect changes in a BLOB column?
Date: Wed, 7 Apr 2004 16:29:10 -0600
Message-ID: <MPG.1ade2ea43c6760c5989c79@solutions.advantagedatabase.com>
References: <3f9dabc1@solutions.advantagedatabase.com> <MPG.1a0841ce7458c833989bd2@solutions.advantagedatabase.com> <406dcb07@solutions.advantagedatabase.com>
Organization: ESI
X-Newsreader: MicroPlanet Gravity v2.30
NNTP-Posting-Host: 198.102.102.187
X-Trace: 7 Apr 2004 16:37:46 -0700, 198.102.102.187
Lines: 13
Path: solutions.advantagedatabase.com!solutions.advantagedatabase.com!198.102.102.187
Xref: solutions.advantagedatabase.com Advantage.Trigger:43
Article PK: 1136110

In article <406dcb07@solutions.advantagedatabase.com>,
t.steinmaurer@_no_upscene_spam_.com says...

> Do you know, if something comparable to a scalar CRC function, for
> detecting blob data changes, will be available in 7.1?

Hi Thomas,

This request did not make it into 7.1. To drive your point home contact
an Advantage sales rep and let them know you're interested in this
feature.

J.D. Mullin
Advantage R&D


Thomas Steinmaurer Posted on 2012-03-19 15:20:46.0Z
Date: Mon, 19 Mar 2012 16:20:46 +0100
From: Thomas Steinmaurer <t.steinmaurer_dontbugmewithspam@upscene.com>
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.2.28) Gecko/20120306 Thunderbird/3.1.20
MIME-Version: 1.0
Newsgroups: Advantage.Trigger
Subject: Re: Detect changes in a BLOB column?
References: <3f9dabc1@solutions.advantagedatabase.com>
In-Reply-To: <3f9dabc1@solutions.advantagedatabase.com>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
NNTP-Posting-Host: 193.186.164.129
Message-ID: <4f674e7d$1@solutions.advantagedatabase.com>
X-Trace: 19 Mar 2012 08:19:25 -0700, 193.186.164.129
Lines: 14
Path: solutions.advantagedatabase.com
Xref: solutions.advantagedatabase.com Advantage.Trigger:509
Article PK: 1136570

Hello,

> the<> operator is applicable to several datatypes except BLOBs.
>
> I can check whether a BLOB column IS NULL or IS NOT NULL,
> is there a way to detect changes in a BLOB column in an SQL script
> based trigger?

This thread is rather oldish (from 2003). I wonder if there is something
available in ADS 10.10, which allows me to compare BLOB content?


Thanks,
Thomas