Tell RDBMS Intra SQL Transaction?

Trying to capture some sql server/sybase related research (minimal). I need to tell the underlying RDBMS type the current statement is running on and run a raiserror dependant on it (as the method signature is heterogenous). Intra-procedure to support portable code. However, @@servername is the closest I’ve got so far, which is crap, and the syntax check fails on both anyway cos of the method signatures. Nuts and bolts. I think I’m going to have to construct the SQL in calling process which knows what type of rdbms it’s using. Ah well.

DECLARE @errorString varchar(50), @errorValue int
SET @errorString = 'processing date hack'
SET @errorValue = @@error
IF LEFT(@@SERVERNAME, 3) = 'SYB'
BEGIN
RAISERROR 17000 'Failed while processing %1! with error no %2!.', @errorString, @errorValue
END
ELSE
RAISERROR ('Failed while processing %s with error no %d.',
16, 1, @errorString, @errorValue)
END

cURL FTP Usage

Transfer file by FTP

curl -T /home/mrsock/tactical/recurseExceptionMessages.txt ftp://login:password@ftpserver.com/test/recurseExceptionMessages.txt

FTP rename transferred file:

curl -Q "RNFR test/recurseExceptionMessages.txt" -Q "RNTO test/recurseExceptionMessages.txt.newname" "ftp://login:password@ftpserver.com"