[firebird-support] Retreiving exception message in PSQL

2013-06-17 Thread sir_wally_lewis
Hi. I call a stored procedure in PSQL like this: BEGIN EXECUTE PROCEDURE MY_PROC WHEN ANY DO BEGIN THEERRMSG = 'GDSCODE ' || CAST( GDSCODE AS VARCHAR(20)); INSERT INTO FAILED_LOG ( TS_SRT, DE_MSG ) VALUES (

[firebird-support] Re: Rename database command

2013-06-05 Thread sir_wally_lewis
Hi Sean, While I don't pretend to understand Firebird at the atomic level. I am just trying to cope with database slowdowns. We find the only bullet proof methodology to solve database slowdowns is a backup restore. So we are searching for a method to be able to resolve database slowdowns,

[firebird-support] Re: Rename database command

2013-06-04 Thread sir_wally_lewis
Hi Ann, Thanks for your input. A problem with nbackup is transaction counts are not reset. As you know our company builds and works with databases around 800 GB. It became clear to us that to keep the system going we have to run a backup/restore every weekend because of slow downs when

[firebird-support] Re: Rename database command

2013-06-02 Thread sir_wally_lewis
/2013 4:22 PM, sir_wally_lewis rgilland1966@... wrote: current practice is. - backup database - restore to new name. - rename old database ( can't be done by firebird ) - rename new name to production name. ( can't be done by firebird ) any step fails process is failed

[firebird-support] Re: Rename database command

2013-06-01 Thread sir_wally_lewis
current practice is. - backup database - restore to new name. - rename old database ( can't be done by firebird ) - rename new name to production name. ( can't be done by firebird ) any step fails process is failed. This allows for 100 percent fool proof backup restore.

[firebird-support] Rename database command

2013-05-30 Thread sir_wally_lewis
There is a DROP DATABASE command. It would make life a lot simpler if I could RENAME a database. DROP DATABASE is too dangerous a command. We can't have it feasible that a client loses it's database RENAME DATABASE new_name.fdb Would resolve the show stopping failure of dropping a database.

[firebird-support] Re: Timeout occurred while waiting for a secondary connection for event processing

2013-05-26 Thread sir_wally_lewis
OK, Our network guy knew what was happening. We use Firebird Events for our applications to listen to changes in the database. However the port the apps listen to must be set. And the network guy had firewalled all ports except 3050. We needed to update firebird.conf to a specfied port for

[firebird-support] Timeout occurred while waiting for a secondary connection for event processing

2013-05-24 Thread sir_wally_lewis
Does anyone know what this means? Simply trying to open a dataset and I get this error just after the system simply stops. Server Version: LI-V6.3.1.26351 Firebird 2.5

[firebird-support] Temporary directories in firebird.conf not being used

2013-05-06 Thread sir_wally_lewis
Hi, I am using Firebird 2.5 on linux ( CentOS 6 ) I have set the firebird.conf temporary directories variable to point to our large data storage folders. However Firebird is determined not to use it and instead uses '/tmp' So I have not been able to run any restore process as firebird runs out

[firebird-support] compaing NULL values like NEW,COLUMN and OLD.COLUMN in triggers

2012-11-26 Thread sir_wally_lewis
We need to do a lot of checking in update triggers to check for value changes. ie if( OLD.FIELD1 NEW.FIELD1 )OR( OLD.FIELD2 NEW.FIELD2 )THEN DO SOMETHING; However if either value is NULL then the response will be NULL. Is there an easy way to compare values, taking into account these

[firebird-support] Cannot restore a database because of failed unique key index

2012-10-23 Thread sir_wally_lewis
Hi, We use Firebird 2.5.1 on Linux 64 bit Firebird fails to restore because of a unique constraint( see below ). However when interrogating the data, no duplicate is found. ( see below SQL, unique key is on the grouped by fields ) How can this be? Kind Regards, Robert. SELECT ID_VN,

[firebird-support] Writing Carraige returns into a field using SQL

2012-09-03 Thread sir_wally_lewis
Hi, I have a problem, where I need to use SQL to update a Memo field. The textual data includes carriage returns. This should be simple however the below fails: UPDATE ST_SCLE_PRNT_FMT SET NA_SCLE_PRNT_FRMT = '[2|02:*]' || #13#10 || 'BARFMTDEFAULT=00' || #13#10 || 'USEDATE=SELLDATE' || #13#10

[firebird-support] Re: Writing Carraige returns into a field using SQL

2012-09-03 Thread sir_wally_lewis
Thanks, Brain was faded. Kind Regards, Robert.

[firebird-support] uuidlib uuid_create() crashes firebird

2012-02-12 Thread sir_wally_lewis
Hi, I got the uuidlib UDF library off the IBPheonix website. I installed it into CentOS 6 64 bit operating system by compiling the source. I ensured the UDF has executable permision. Using Firebird 2.5.1 superclassic I declared the function as in example DECLARE EXTERNAL FUNCTION UUID_CREATE

[firebird-support] Re: Firebird 2.5: Optimize of IN or EXISTS performance

2011-11-14 Thread sir_wally_lewis
your table structure does not seem suitable for an exists query. IN querys were never ever optimised. Here is proper syntax for EXISTS: SELECT * FROM TABLE1 WHERE( EXISTS ( SELECT * FROM TABLE2 WHERE( TABLE1.KEY1 = TABLE2.KEY1 ) AND( TABLE1.KEY2 = TABLE2.KEY2 ))) ie. there needs to be

[firebird-support] Re: Pascal UDF passing timestamps/strings

2011-10-11 Thread sir_wally_lewis
so these functions look like: procedure fbdatetopascaldate( ib_datetime : PISC_QUAD; VAR pscl_dt : TDATETIME ); var tm_date:Tm; begin init_tm(tm_date); isc_decode_date(ib_datetime,@tm_date); pscl_dt := EncodeDate(tm_date.tmYear + 1900, tm_date.tm_mon + 1, tm_date.tm_mday ) +

[firebird-support] creating a database in ubuntu

2011-10-08 Thread sir_wally_lewis
OK, I use ubuntu lucid ( 10.04 ) I have got all the way to installing and running firebird 2.1 super installing and running flamerobin every time i try to create a database i get this: Engine Code: 335544344 Engine Message : I/O error for file /opt/data/firebird/blank/blank.fdb Error

[firebird-support] Re: Pascal UDF passing timestamps/strings

2011-10-07 Thread sir_wally_lewis
, Frank Schlottmann-Gödde frank@... wrote: On 07.10.2011 10:44, sir_wally_lewis wrote: Has anyone successfully written a pascal UDF to pass timestamps/strings without using the ibobjects library? Yes, what problems do you face? mit freundlichen Grüßen Frank Schlottmann-Gödde