[firebird-support] Transactions

2014-04-11 Thread cornievs
Please help my understand what will happen in the following cases involving transactions. System: Delphi XE2, Firebird 2,5x, Using DBX components. Isolation level: ReadCommitted. The actual statements are much more complex and involves various statements in the transaction and/or triggers

[firebird-support] How to quot;fixquot; SYSDBA/masterkey login

2014-01-08 Thread cornievs
Hi I want to fix my software usage of SYSDBA/masterkey and would appreciate pointers to fastest/best way to do so. I have +- 100 installations running on WinXp/Win7 and Firebird 2.5.1 or 2.5.2. The software is develop with Delphi XE2/DBX. For a start I just want to copy the rights of

[firebird-support] Select * where FieldString = 3 allowed on some Firebird servers

2013-07-12 Thread cornievs
Background Testing Server Windows 7 Professional Firebird 2.5.2 Superserver (Default settings with just TCP-IP changes) Production Server Windows 7 Home Firebird 2.5.2 Superserver (Default settings with just TCP-IP changes) In my application developed in Delphi XE2, dbExpress I made the error

[firebird-support] How do I get the differences between 2 timestamps as a timestamp.

2013-06-03 Thread cornievs
I have the following table (Staff_Events) ... Start_Date TIMESTAMP, End_Date TIMESTAMP, Period TIMESTAMP, and need to set Period to the time difference between End_Date and Start_Date. End_Date will always be later than Start_Date. (Enforce by on Insert/Update triggers.) I know I

[firebird-support] Advice needed on speed between triggers and application inserts/updates

2013-05-02 Thread cornievs
I am a developer of accounting software and mostly learned my trade by trail and error and from this forum. (Thanks for all the info and tips I receive daily on this forum.) Setup: Delphi XE2 + DBX + Firebird 2.5x Firebird mostly running on dual core pentiums, Windows XP/7 Pro. Workstations =

[firebird-support] How do you 0/null results to a GROUP BY query

2012-10-24 Thread cornievs
Hi All I have query which extract the sales per day from a table Select EXTRACT(YEAR from DT) as YEARNO, EXTRACT(YEARDAY from DT) AS DAYNO, SUM(DUE) from CLIENT_INVOICES group by YEARNO, WEEKNO. It works 100%, but only returns the dates with sales, I need it to also include the dates with

[firebird-support] How do you get a summary SUM() from a union of tables

2012-07-02 Thread cornievs
Hi I have 2 (and more) tables with identical structure: Simplified structure and data: CODE VARCHAR(15) QUAN INTEGER Table A Item1, 50 Item1, 40 Item2, 70 Table B Item1, 50 Item2, 100 Item2, 30 I need to get the sum(QUAN) for all the rows in all the tables group by CODE Item1, 140 Item2, 200

[firebird-support] Which value will be used after converting a field from Double Prec to Decimal

2012-02-15 Thread cornievs
I have column with field type DOUBLE PRECISION and needs to convert it to DECIMAL (15,4). In a test with a field value of 23.99, I change it to DECIMAL (15,4) and got want I need in my Delphi (DBX) application of 24.. Then I change it back to DOUBLE PRECISION and notice that the value

[firebird-support] Speed of an query with IN select

2011-12-27 Thread cornievs
Is there a way I can speed up the following query? Select CODE, STKCODE, DESCRIPTION from COUNT_SHEETS_DETAIL where code STARTING WITH 'TPL' and STKCODE in (Select STKCODE from (Select STKCODE, COUNT(STKCODE) as COUNT1 from COUNT_SHEETS_DETAIL where code STARTING WITH 'TPL' GROUP BY STKCODE