Re: [firebird-support] UPDATE OR INSERT in Firebird 3

2020-11-25 Thread 'Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
will be more portable to other db engines because > it is closer to the standard. > > I hope that suggestion proves helpful > Warmly > River~~ > > On 19/11/2020, 'Walter R. Ojeda Valiente' > sistemas2000profesio...@gmail.com [firebird-support] > wrote: > &g

Re: [firebird-support] Re: UPDATE OR INSERT in Firebird 3

2020-11-24 Thread 'Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
;re much better off explicitly writing > the appropriate insert and update triggers. Possibly version 4 will > implement IDENTITY better but I don't use it all now. > > Daniel > > On 11/20/2020 5:59 AM, 'Walter R. Ojeda Valiente' > sistemas2000profesio...@gmail.com [firebird-support] wrote: > > >

Re: [firebird-support] Re: UPDATE OR INSERT in Firebird 3

2020-11-20 Thread 'Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
u very much for your answer. Greetings. Walter. On Fri, Nov 20, 2020 at 6:16 AM Herman Viaene herman.via...@edpnet.be [firebird-support] wrote: > > > Op 20/11/2020 om 01:04 schreef 'Walter R. Ojeda Valiente' > sistemas2000profesio...@gmail.com [firebird-support]: > >

[firebird-support] Re: UPDATE OR INSERT in Firebird 3

2020-11-19 Thread 'Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
CREATE TABLE MYTABLE ( COLUMN1 INTEGER GENERATED BY DEFAULT AS IDENTITY (START WITH 1) NOT NULL, COLUMN2 VARCHAR(20)); ALTER TABLE MYTABLE ADD CONSTRAINT PK_MYTABLE PRIMARY KEY (COLUMN1); Then, is I write it: UPDATE OR INSERT INTO MYTABLE (COLUMN1, COLUMN2) VALUES (NULL, 'TEST') The message

[firebird-support] Re: UPDATE OR INSERT in Firebird 3

2020-11-19 Thread 'Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
I forget to say that my IDENTITY column is the Primary Key of MyTable, therefore if I don't write it an error happens because...the table needs a Primary Key. On Thu, Nov 19, 2020 at 8:52 PM Walter R. Ojeda Valiente < sistemas2000profesio...@gmail.com> wrote: > Hello everybody > > A long, long ti

[firebird-support] UPDATE OR INSERT in Firebird 3

2020-11-19 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Hello everybody A long, long time without writing neither reading this group, mostly because all that I need about Firebird I knew. But now, I have a doubt. With Firebird 2.5.x I can have an auto-incremental column and use it in an UPDATE OR INSERT, but such thing is not possible with Firebird 3

Re: [firebird-support] Impossible to create a new database from a script

2018-03-17 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
gt; <#DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2> On Sat, Mar 17, 2018 at 1:12 PM, Dimitry Sibiryakov s...@ibphoenix.com [firebird-support] wrote: > 17.03.2018 18:07, 'Walter R. Ojeda Valiente' > sistemas2000profesio...@gmail.com > [firebird-support] wrote: > > Sorry, but

Re: [firebird-support] Impossible to create a new database from a script

2018-03-17 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Thank you Dimitri for your answer. Greetings. Walter. Libre de virus. www.avast.com

Re: [firebird-support] Impossible to create a new database from a script

2018-03-17 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
m_source=link&utm_campaign=sig-email&utm_content=webmail> <#DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2> On Sat, Mar 17, 2018 at 11:30 AM, Mark Rotteveel m...@lawinegevaar.nl [firebird-support] wrote: > > > On 17-3-2018 16:21, 'Walter R. Ojeda Valiente' > sistemas

Re: [firebird-support] Impossible to create a new database from a script

2018-03-17 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
w.avast.com <https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail> <#DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2> On Sat, Mar 17, 2018 at 9:50 AM, Mark Rotteveel m...@lawinegevaar.nl [firebird-support] wrote: > >

[firebird-support] Impossible to create a new database from a script

2018-03-17 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Hello everybody I am using Firebird 2.5.8 in Windows 7. I have a script file which contains the lines for create a database and theirs domains, tables, triggers, and so on. The problem is in the lines of comments. CREATE DATABASE '127.0.0.1/3050:E :\SQL\SQL_MUAN\DATABASES\MUAN_MASTER_21.FDB'

Re: Re[2]: [firebird-support] select column if it exists

2018-01-02 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
What about: SELECT A, B, COALESCE(C, 'some value here') FROM MyTable Greetings. Walter. On Tue, Oct 10, 2017 at 2:56 PM, 'Daniel Miller' dmil...@amfes.com [firebird-support] wrote: > > > I don't think you could express it in the SELECT directly (someone else > will probably build

Re: [firebird-support] detect if database has changed

2018-01-02 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
There are several ways for doing that. One of them, is to create a table, called CHANGES, by example, and with the columns: TABLENAME, USERNAME, DATEANDTIME, etc. Then, for each table of your interest, you create a trigger which inserts a row in the table CHANGES when a user do an INSERT, UPDATE,

Re: [firebird-support] Connected databases to the Server

2018-01-02 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Doesn't work, always shows just 1 database, the current one. Sometimes with several instances, but always the same database name. Greetings. Walter. On Sun, Oct 8, 2017 at 5:25 AM, Dimitry Sibiryakov s...@ibphoenix.com [firebird-support] wrote: > 07.10.2017 22:57, 'Walter R. O

[firebird-support] Connected databases to the Server

2017-10-07 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Hello everyone There is some way to know which databases are connected actually at the Server? Maybe 3 databases are connected now, or maybe 17, or maybe 83, how can I know that? Which databases are connected, right now? Thanks in advance. Greetings. Walter.

Re: [firebird-support] How to get the the tables and the columns of a Foreign Key?

2017-05-30 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
hild.rdb$index_name = 'FK_ADHERENTES' > > HTH, > Set > > 2017-05-30 7:10 GMT+02:00 'Walter R. Ojeda Valiente' > sistemas2000profesio...@gmail.com [firebird-support] < > firebird-support@yahoogroups.com>: > >> >> >> Hello everybody

[firebird-support] How to get the the tables and the columns of a Foreign Key?

2017-05-29 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Hello everybody I had defined a Foreign Key as: ALTER TABLE ADHERENTES ADD CONSTRAINT FK_ADHERENTES FOREIGN KEY (ADH_SERVID, ADH_IDECAB) REFERENCES CLIENTES(CLI_SERVID, CLI_IDENTI) ON DELETE CASCADE ON UPDATE CASCADE; Of course, that work very well. However, after watching the system tables I c

[firebird-support] Entity Relationship Diagram

2017-04-14 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Hello everyone Excuse me if it is an off-topic. Do you know some good program for Entity Relationship Diagram using Firebird databases? I mean, having a Firebird database get its ERD Mister Google can answer that question but is not the same as comments of people who are using such programs. G

Re: [firebird-support] Is there an easy way for input rows from a script file?

2017-02-16 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
gt;> >> Walter. >> >> >> On Wed, Feb 15, 2017 at 6:31 PM, setysvar setys...@gmail.com >> [firebird-support] wrote: >> >>> >>> >>> Den 15.02.2017 17:07, skrev 'Walter R. Ojeda Valiente' >>> sistemas2000profesio...@

Re: [firebird-support] Re: Is there an easy way for input rows from a script file?

2017-02-16 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Thank you Vlad, but is not for me, is for an article of my blog, I am showing the alternatives for exporting data. firebird21.wordpress.com Greetings. Walter. On Thu, Feb 16, 2017 at 3:44 AM, hv...@users.sourceforge.net [firebird-support] wrote: > > > ---In firebird-support@yahoogroups.com,

Re: [firebird-support] Is there an easy way for input rows from a script file?

2017-02-15 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Thank you, Sean Greetings. Walter. On Wed, Feb 15, 2017 at 6:43 PM, 'Leyne, Sean' s...@broadviewsoftware.com [firebird-support] wrote: > > > Walter, > > > If I connect to a database "Database1" using ISQL, I can write something > like: > > > > OUTPUT MyFile.DAT; > > SELECT * FROM MyTable; > >

Re: [firebird-support] Is there an easy way for input rows from a script file?

2017-02-15 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Thank you very much Set, I will try your advice. Off topic: can you say me what the letters HTH means? Greetings. Walter. On Wed, Feb 15, 2017 at 6:31 PM, setysvar setys...@gmail.com [firebird-support] wrote: > > > Den 15.02.2017 17:07, skrev 'Walter R.

[firebird-support] Is there an easy way for input rows from a script file?

2017-02-15 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Hello everybody If I connect to a database "Database1" using ISQL, I can write something like: OUTPUT MyFile.DAT; SELECT * FROM MyTable; OUTPUT; And all the rows of "MyTable" will go to the text file "MyFile.DAT". That's ok and works fine. But now, I want to connect to "Database2", which also h

Re: [firebird-support] Is this a bug of Firebird?

2017-02-10 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
A warning would be enough. If after the INTO clause there are 2 or 3 variables, no problem, it will be very easy to detect the mistake. But sometimes that is not the case because there are 20+ variables and if variable 3 is called "lcName" and variable 24 is called "lcName" too, the programmer can

Re: [firebird-support] Is this a bug of Firebird?

2017-02-08 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
The error is of the programmer, I agree with you, but to repeat the name of a variable without the Firebird showing any message of error is, at least for me, a bug. To have 2 or more variables with the same name after the INTO clause is useless. The compiler can be smart enough to detect such thin

Re: [firebird-support] Is this a bug of Firebird?

2017-02-08 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
ebird-support] wrote: > 08.02.2017 16:55, 'Walter R. Ojeda Valiente' > sistemas2000profesio...@gmail.com > [firebird-support] wrote: > > Of course, the fault is of the programmer, but it can be detected at > compilation time. > >Why? It is expanded into co

[firebird-support] Is this a bug of Firebird?

2017-02-08 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
CREATE PROCEDURE TEST RETURNS( lcName VARCHAR(40)) AS BEGIN FOR SELECT ALU_NOMBRE, ALU_APELLD FROM ALUMNOS INTO :lcName, :lcName DO SUSPEND; END; In the above stored procedure there are 2 columns in the FOR SELECT but just 1 variable name. It see

Re: [firebird-support] Re: Data pages and data page slots

2016-12-13 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Thank you very much Vlad, that is what I was thinking but always is very better to have the explanation of one expert. Greetings. Walter. On Tue, Dec 13, 2016 at 11:25 AM, hv...@users.sourceforge.net [firebird-support] wrote: > > > ---In firebird-support@yahoogroups.com, > wrote : > > > When

[firebird-support] Data pages and data page slots

2016-12-12 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Hello everybody When I run GSTAT with the switch -data it shows me numbers after "data pages" and "data page slots". Usually these numbers are the same, but ... what happen when they are different? I understood that the difference between them means the count of pages without any relevant data.

Re: [firebird-support] Speed of comparing one field to another

2016-11-28 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Yes, you can, using an expression index CREATE INDEX IDX_MYINDEX ON MY_TABLE COMPUTED BY (INVOICED - RECEIVED); and your SELECT would be: SELECT * FROM MY_TABLE WHERE INVOICED - RECEIVED < 0 That way you will not need to create an additional column neither to do an UPDATE neither to cr

Re: [firebird-support] Database design. Simple question!

2016-07-25 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
To have a separate table for a single column is a good idea if the column will be of type BLOB and will be used just sometimes. Greetings. Walter. On Mon, Jul 25, 2016 at 5:51 PM, shg_siste...@yahoo.com.ar [firebird-support] wrote: > > > Hello! I have a FB 2.5 database with a tabla "invoic

Re: [firebird-support] Update table column from another table

2016-01-02 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Floating point values are not exact values, there is not guarantee. If you need exact values, use NUMERIC or DECIMAL instead. Greetings. Walter. On Sat, Jan 2, 2016 at 11:28 AM, Sonya Blade sonyablade2...@hotmail.com [firebird-support] wrote: > > > > Yes I tried that it wasn't selecting at a

Re: [firebird-support] access column by column name

2015-12-26 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
You can use EXECUTE STATEMENT for that. Greetings. Walter. On Sat, Dec 26, 2015 at 1:50 PM, slucas slu...@iquanta.com [firebird-support] wrote: > > > hello one and all, > > i would like to write a stored procedure which looks something like: > > CREATE PROCEDURE IC_INITIATE(d CHAR(3), CN CHAR

Re: [firebird-support] Numeration without hole, Is right Before Insert Trigger?

2015-12-25 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Hello Luigi If you can read Spanish, this article can be useful: https://firebird21.wordpress.com/2014/09/11/algo-mas-sobre-transacciones-optimistas-y-transacciones-pesimistas/ Greetings. Walter. On Thu, Dec 24, 2015 at 7:05 AM, Svein Erling Tysvær setys...@gmail.com [firebird-support] wrote

Re: [firebird-support] error writing data to the connection

2015-12-25 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
You can know that the connection is active sending a request to the Server, something like: SELECT CURRENT_TIME FROM RDB$DATABASE In your application, using a control Timer, you can send such command each minute or so. If there is not response then connection is dead. For connecting again

Re: [firebird-support] Writing to Aliases.conf in non-admin mode

2015-11-02 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Well, the more easy answer is not install Firebird under the folder "Program files", because Windows since its Vista version has protected that folder. You can install Firebird in C:\FIREBIRD\ or something so and no problems writing to any of its files. Greetings. Walter. On Sat, Oct 24, 2015

Re: [firebird-support] Sort hierarchical data

2015-10-30 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
If you can read Spanish, there are several articles about that topic: https://firebird21.wordpress.com/2013/10/10/stored-procedures-recursivos/ https://firebird21.wordpress.com/2015/08/22/usando-recursividad-con-cte/ https://firebird21.wordpress.com/2015/08/27/ejemplo-de-recursion-1/ https://fi

Re: [firebird-support] Order by

2015-10-07 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
gt; El Martes, 6 de octubre, 2015 21:02:31, "'Walter R. Ojeda Valiente' > sistemas2000profesio...@gmail.com [firebird-support]" < > firebird-support@yahoogroups.com> escribió: > > > > > > Germán, as you can read Spanish, this article can be usef

Re: [firebird-support] Order by

2015-10-06 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Germán, as you can read Spanish, this article can be useful: https://firebird21.wordpress.com/2014/11/20/mostrando-los-resultados-ordenados-por-cualquier-criterio/ Greetings. Walter. On Tue, Oct 6, 2015 at 6:17 PM, Germán Balbi bal...@yahoo.com [firebird-support] wrote: > > > Excellent, very

Re: Re: [firebird-support] How To Get Entire Linked Group Details

2015-10-02 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
ilsh ? so would be easy to learn for me. I am very > much interested to learn recursive SQL. > > Karol, but please help me in getting base leaf also in the output. > > Thank You to both of You. > > With Best Regards. > > Vishal > > > > On Friday, 2

Re: Re: [firebird-support] How To Get Entire Linked Group Details

2015-10-02 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
If you want to learn about recursivity with Firebird and you can read Spanish, there are several articles that can teach you: https://firebird21.wordpress.com/2015/08/22/usando-recursividad-con-cte/ https://firebird21.wordpress.com/2015/08/25/entendiendo-la-recursividad-en-los-select/ https://fi

Re: [firebird-support] Firebird 2.5 Language Reference

2015-09-29 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Thank you very much Germán Greetings. Walter. On Tue, Sep 29, 2015 at 10:10 PM, Germán Balbi bal...@yahoo.com [firebird-support] wrote: > > > Para una mucho mejor traducción usa el traductor de Microsoft > http://www.bing.com/translator/ > > > [image: image]

Re: [firebird-support] Firebird 3 compression data

2015-09-28 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Thank you very much Carlos. In the document: http://web.firebirdsql.org/download/prerelease/rlsnotes/Firebird-3.0.0_Beta2-ReleaseNotes.pdf Which I take as my reference, there is not a single word about the parameter WireCompression. It's clear now. Greetings. Walter. On Mon, Sep 28, 2015 at

Re: [firebird-support] Firebird 3 compression data

2015-09-27 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Hello Carlos Thank you for your answer. In your article you has written about the benchmark with and without compression. How you did that? You have "FB 3 padrao" and "FB 3 compressao". If I want to compare FB 3 against MySQL, Postegre, or whatever: how I can have compression enabled or disabl

Re: [firebird-support] Re: SELECT for get the number of contexts

2015-09-27 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Thank you very much Ann, it's very clear now. Greetings. Walter. On Sun, Sep 27, 2015 at 5:23 PM, Ann Harrison aharri...@ibphoenix.com [firebird-support] wrote: > > > > > On Sun, Sep 27, 2015 at 1:37 PM, 'Walter R. Ojeda Valiente' > sistemas2000profes

[firebird-support] Firebird 3 compression data

2015-09-27 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
According to this (very good) news, http://www.firebirdnews.org/firebird-3-protocol-benchmark/ Firebird 3 can have compression of data. Excellent!!! However neither in the above page neither in the "Firebird 3.0 Release Notes" http://web.firebirdsql.org/download/prerelease/rlsnotes/Firebird-3.

Re: [firebird-support] Re: SELECT for get the number of contexts

2015-09-27 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Thank you very much Dmitry for your answer, it is more clear now, however I still have some doubts. According to Vlad Khorsun, each INSERT, UPDATE or DELETE has 2 contexts, cause of the variables NEW and OLD of the triggers. Is that not true? The only way to know how many contexts a stored proced

[firebird-support] SELECT for get the number of contexts

2015-09-25 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Hello everybody Is there some SELECT that can give me the number of context a stored procedure has? As you know the maximum number of contexts is 255. And it would be interesting to know how many contexts a stored procedure has, without counting with the finger. Other question: Which are the c

Re: [firebird-support] Firebird 2.5 Language Reference

2015-09-16 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Thank you very much, Alexey Is there an estimated date for the publication? Greetings. Walter. On Wed, Sep 16, 2015 at 2:34 PM, Alexey Kovyazin a...@ib-aid.com [firebird-support] wrote: > > > Hi, > > Translation was completed several weeks ago, now Helen Borrie performs > proof-reading and e

[firebird-support] Firebird 2.5 Language Reference

2015-09-16 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Hello everybody Do you know what has happened with the translation of the document "Firebird 2.5 Language Reference" from Russian to English? They had requested for donation with the promise that their work would be ready in February 2015. The donation was made, now it is September 2015, but wit

Re: [firebird-support] What is better: UPDATE or DELETE + INSERT?

2015-09-16 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Thank you very much, Alexey. Greetings. Walter. On Wed, Sep 16, 2015 at 1:36 PM, Alexey Kovyazin a...@ib-aid.com [firebird-support] wrote: > > > Hi, > > See page 20-21 here > > http://ru.scribd.com/doc/20128182/The-InterBase-and-Firebird-Developer-Magazine-Issue-2-2005 > > Regards, > Alexey K

Re: [firebird-support] What is better: UPDATE or DELETE + INSERT?

2015-09-16 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Hello Sean, and everybody That's a very interesting and very important theme: "the new record version will only include the updated fields -- not a full copy of the row" Do you know where I can find a document, web-page, book or video that explains that? If it has images or graphics, much better.

Re: [firebird-support] Strategy to get a sequence in a strict ascending order for a log table

2015-09-01 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Why you don't use IN AUTONOMOUS TRANSACTION DO? So, when the sequence get its value you insert the row in the log table. Greetings. Walter. On Tue, Sep 1, 2015 at 12:26 PM, kokok_ko...@yahoo.es [firebird-support] < firebird-support@yahoogroups.com> wrote: > > > I am trying to create a log tab

Re: [firebird-support] Expression index for use with the GROUP BY clause

2015-08-24 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Ok, thank you Karol. Greetings. Walter. On Mon, Aug 24, 2015 at 2:32 PM, liviusliv...@poczta.onet.pl [firebird-support] wrote: > > > Hi, > > as i say previously you can not do this > as index can not be updated if something was changed in ASIENTOSCAB. > And any subseclect is not recognized by

Re: [firebird-support] Expression index for use with the GROUP BY clause

2015-08-24 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Hello Karol Thank you for your answer. The query is a very simplified one, just for show the idea. I can create an index as the following: CREATE INDEX IDX_ASIENTOSDET1 ON ASIENTOSDET COMPUTED BY ( CAST(ASI_ANOEJE AS CHAR(5)) || CAST(ASI_CODSUC AS CHAR(5)) || CAST(EXTRACT(MONTH FROM (S

Re: [firebird-support] Re: Differences when adding a Primary Key

2015-08-24 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
>> The question is: >>> >>> Why without using CONSTRAINT appears that message but using CONSTRAINT >>> all works fine? >>> >>> And there are not row/s with a NULL value in the column ID. >>> >>> At least, they are not showed with the follo

[firebird-support] Expression index for use with the GROUP BY clause

2015-08-24 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Hello everybody I had the following query: SELECT D.ASI_ANOEJE, D.ASI_CODSUC, EXTRACT(MONTH FROM C.ASC_FECHAX) AS ASI_NUMMES, D.ASI_NUMCUE, D.ASI_NUMSUB FROM ASIENTOSDET D JOIN ASIENTOSCAB C ON D.ASI_CODSUC = C.ASC_CODSUC AND D.ASI_IDECAB = C.ASC_IDENTI GROUP B

Re: [firebird-support] Re: Differences when adding a Primary Key

2015-08-24 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
are not showed with the following query: >> >> SELECT >>* >> FROM >>MyTable >> WHERE >>ID IS NULL >> >> So, it seems very strange to me. The logic for me is: both works or both >> fails, but why one fails and the other

Re: [firebird-support] Re: Differences when adding a Primary Key

2015-08-24 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
the following query: >> >> SELECT >>* >> FROM >>MyTable >> WHERE >>ID IS NULL >> >> So, it seems very strange to me. The logic for me is: both works or both >> fails, but why one fails and the other works? >> >> Gre

Re: [firebird-support] Re: Differences when adding a Primary Key

2015-08-22 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
> So, it seems very strange to me. The logic for me is: both works or both > fails, but why one fails and the other works? > > Greetings. > > Walter. > > > > > > > On Fri, Aug 21, 2015 at 2:43 PM, Ann Harrison aharri...@ibphoenix.com > [firebird-suppor

Re: [firebird-support] Re: Differences when adding a Primary Key

2015-08-21 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
me is: both works or both fails, but why one fails and the other works? Greetings. Walter. On Fri, Aug 21, 2015 at 2:43 PM, Ann Harrison aharri...@ibphoenix.com [firebird-support] wrote: > > > > On Aug 21, 2015, at 2:13 PM, 'Walter R. Ojeda Valiente' > sistem

Re: [firebird-support] Re: Differences when adding a Primary Key

2015-08-21 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
wrote: > > > hi. Maybe you post an ilegal name or this name are not unique for entery > database objects name's. every object in firebird database must be unique. > no matters if the same name is used on diferent tables. > > On Fri, Aug 21, 2015 at 12:2

[firebird-support] Re: Differences when adding a Primary Key

2015-08-21 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Nobody knows? Nobody has any idea? Greetings. Walter. On Thu, Aug 20, 2015 at 10:45 AM, Walter R. Ojeda Valiente < sistemas2000profesio...@gmail.com> wrote: > Hello everybody > > For add a Primary Key to a table we can write: > > ALTER TABLE MyTable ADD PRIMARY KEY (ID); > > or we can write:

[firebird-support] Differences when adding a Primary Key

2015-08-20 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Hello everybody For add a Primary Key to a table we can write: ALTER TABLE MyTable ADD PRIMARY KEY (ID); or we can write: ALTER TABLE MyTable ADD CONSTRAINT MyPK PRIMARY KEY (ID); In the first case, the Firebird puts the name of the Primary Key, in the second case we choose that name, but...

Re: [firebird-support] What is the best way to re-write this Stored Procedure that seems to be SLOW processing?

2015-08-15 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
ysvar setys...@gmail.com [firebird-support] wrote: > > > Den 15.08.2015 06:14, skrev 'Walter R. Ojeda Valiente' > sistemas2000profesio...@gmail.com [firebird-support]: > > Hello Set > > > > Why writing: PP.STATUS_CODE || '' will improve the SELECT,

Re: [firebird-support] What is the best way to re-write this Stored Procedure that seems to be SLOW processing?

2015-08-14 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Hello Set Why writing: PP.STATUS_CODE || '' will improve the SELECT, can you explain me? As far I know, adding '' is for use NATURAL in the PLAN, why the use of NATURAL will do a better response time? Thanks in advance. Greetings. Walter. On Thu, Aug 13, 2015 at 4:49 PM, setysvar setys...@gm

Re: [firebird-support] Knowing the previous rows

2015-08-08 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
6:36 AM, Mark Rotteveel m...@lawinegevaar.nl [firebird-support] wrote: > > > On 7-8-2015 22:50, 'Walter R. Ojeda Valiente' > sistemas2000profesio...@gmail.com [firebird-support] wrote: > > I just was a bit curious about that possibility, which seems interesting > &g

Re: [firebird-support] Problem with AUTONOMOUS TRANSACTION

2015-08-07 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Ha, ha, ha, ha, ha, ha, ha, ha. Thank you very much Helen, sometimes the memory is not so good as was some years ago. Ok, I now know and hope not forget again: "NEVER USE IN AUTONOMOUS TRANSACTION INSIDE A TRANSACTION RELATED DATABASE TRIGGER". Greetings. Walter. On Fri, Aug 7, 2015 at 11:20

[firebird-support] Problem with AUTONOMOUS TRANSACTION

2015-08-07 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Hello everybody Do you know why this simple trigger "hang-up" the database? CREATE TRIGGER TRANSACCION_INICIA ACTIVE ON TRANSACTION START POSITION 0 AS BEGIN IN AUTONOMOUS TRANSACTION DO BEGIN END END; Always when I put "IN AUTONOMOUS TRANSACTION" the database crash. Without those word

Re: [firebird-support] Knowing the previous rows

2015-08-07 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
at 4:14 PM, Ann Harrison aharri...@ibphoenix.com [firebird-support] wrote: > > > > > On Aug 7, 2015, at 1:56 PM, 'Walter R. Ojeda Valiente' > sistemas2000profesio...@gmail.com [firebird-support] < > firebird-support@yahoogroups.com> wrote: > > > >

Re: [firebird-support] Knowing the previous rows

2015-08-07 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Well, after run GSTAT and reading the output I can see how many garbage a whole table has, but it don't shows me the "story" of a row. ¿How many COMMITs and how many ROLLBACKs the row with ID 1234 of the table CLIENTS had had? Greetings. Walter. On Fri, Aug 7, 2015 at 1:42 PM, Walter R. Ojeda V

Re: [firebird-support] Knowing the previous rows

2015-08-07 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Thank you Ann, I shall investigate that. Greetings. Walter. On Fri, Aug 7, 2015 at 1:10 PM, Ann Harrison aharri...@ibphoenix.com [firebird-support] wrote: > > > > > > The idea is to know how many garbage a table has. Or several tables. Or > the whole database. > > > That you can find out with

Re: [firebird-support] Knowing the previous rows

2015-08-07 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
tings. Walter. On Fri, Aug 7, 2015 at 1:32 AM, liviuslivius liviusliv...@poczta.onet.pl [firebird-support] wrote: > > > Hi, > > What about triggers? > > Regards, > Karol Bieniaszewski > > > Oryginalna wiadomość -------- > Od: "'Walter R

[firebird-support] Knowing the previous rows

2015-08-06 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Hello everbody Always that a transaction that did an UPDATE ends with a COMMIT or a ROLLBACK this left back a row. So, my question is: There is some way to know those previous rows? This can be very useful for me because I shall know how many garbage a table has. For example, if a row has the I

Re: [firebird-support] Re: Firebird 3, execution modes

2015-07-14 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
s are off topic on firebird-support. > > Mark > > > ----- Reply message - > Van: "'Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com > [firebird-support]" > Aan: > Onderwerp: [firebird-support] Re: Firebird 3, execution modes > Datum: d

[firebird-support] Re: Firebird 3, execution modes

2015-07-14 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
¿Nobody has answers to my questions? Greetings. Walter. On Fri, Jul 10, 2015 at 10:39 PM, Walter R. Ojeda Valiente < sistemas2000profesio...@gmail.com> wrote: > Reading the excellent (as usual) document of Helen Borrie: Firebird 3.0 > Release Notes (for Firebird 3.0 Beta 2) I had some doubts:

[firebird-support] Firebird 3, execution modes

2015-07-10 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Reading the excellent (as usual) document of Helen Borrie: Firebird 3.0 Release Notes (for Firebird 3.0 Beta 2) I had some doubts: First, it says that for choicing the working modes (models) I need to put values 0 or 1 at SharedCache and SharedDatabase. Ok with that. But then it says that the exe

Re: [firebird-support] Altering a domain

2015-06-20 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Thank you Ann. Greetings. Walter. On Sat, Jun 20, 2015 at 9:04 AM, Ann Harrison aharri...@ibphoenix.com [firebird-support] wrote: > > > > > On Jun 19, 2015, at 3:32 PM, 'Walter R. Ojeda Valiente' > sistemas2000profesio...@gmail.com [firebird-support] < >

Re: [firebird-support] Altering a domain

2015-06-19 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Excellent explanation Ann, as always. Just one doubt: After a cycle backup/restore: the restored database will have all the rows with the new domain? All columns with domain D_CURRENCY that were created with DECIMAL(9, 2) now will be DECIMAL(18, 2) ? Greetings. Walter. On Tue, Jun 16, 2015 at

Re: [firebird-support] Database restore speed with IBExpert and Gbak

2015-05-26 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Thank you very much, Thomas. Very useful. Greetings. Walter. On Tue, May 26, 2015 at 1:02 PM, Thomas Steinmaurer t...@iblogmanager.com [firebird-support] wrote: > > > Hello Walter, > > > Hello Thomas > > > > That seems an interesting idea. Can you explain it with more details? > > For the res

Re: [firebird-support] Database restore speed with IBExpert and Gbak

2015-05-26 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Hello Thomas That seems an interesting idea. Can you explain it with more details? Greetings. Walter. On Tue, May 26, 2015 at 12:25 PM, Thomas Steinmaurer t...@iblogmanager.com [firebird-support] wrote: > > > Halim, > > > Thank you for your reply. > > I just tested a GBAK restore using -se(r

Re: [firebird-support] GBAK - validation error for column X, value "*** null ***"

2015-05-23 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
If you only have a backup and the backup is corrupted then very bad news. The best politic is always to do a backup/restore cycle inmediatly. So, if an error is detected when the backup is being restored you can take actions at that right moment. If your operating system is Windows, you can

Re: [firebird-support] Test VARCAHR for numeric

2015-04-25 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Very interesting Mark, I shall remember that for the time when Firebird3 is coming here. Greetings. Walter. On Sat, Apr 25, 2015 at 3:14 AM, Mark Rotteveel m...@lawinegevaar.nl [firebird-support] wrote: > > > On 25-4-2015 08:08, 'Walter R. Ojeda Valiente' > sistemas200

Re: [firebird-support] Test VARCAHR for numeric

2015-04-24 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
. Walter. On Fri, Apr 24, 2015 at 2:53 AM, Mark Rotteveel m...@lawinegevaar.nl [firebird-support] wrote: > > > On Thu, 23 Apr 2015 20:00:32 -0400, "'Walter R. Ojeda Valiente' > sistemas2000profesio...@gmail.com [firebird-support]" > wrote: > >

Re: [firebird-support] Test VARCAHR for numeric

2015-04-23 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Again, if you can read Spanish then the following article has more examples: https://firebird21.wordpress.com/2015/04/23/validando-que-el-contenido-de-un-char-o-varchar-sea-numerico/ Greetings. Walter. On Thu, Apr 23, 2015 at 8:03 PM, Walter R. Ojeda Valiente < sistemas2000profesio...@gmail.co

Re: [firebird-support] Test VARCAHR for numeric

2015-04-23 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Sorry, typo in the SELECT, just one comma after MyColumn2. Greetings. Walter. On Thu, Apr 23, 2015 at 8:00 PM, Walter R. Ojeda Valiente < sistemas2000profesio...@gmail.com> wrote: > You can use SIMILAR TO, something like it: > > SELECT >MyColumn1, >MyColumn2,, >MyColumn3 > FROM >

Re: [firebird-support] Test VARCAHR for numeric

2015-04-23 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
You can use SIMILAR TO, something like it: SELECT MyColumn1, MyColumn2,, MyColumn3 FROM MyTable WHERE MyColumn1 SIMILAR TO '[[:DIGIT:]]*' Where just the digits 0, 1, 2, 3, 4, 5, 6, 7, 8, 9 are valid. If you need the decimal point too, try something like it, where the decimail poin

Re: [firebird-support] Re: Awaiting Garbage Collector

2015-04-04 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Thank you very much for your answer Alexey, I was very bussy these days. Looking at the page 46 it seems more understandable now. Greetings. Walter. On Wed, Mar 25, 2015 at 2:02 PM, Alexey Kovyazin a...@ib-aid.com [firebird-support] wrote: > > > Hi Walter, > > On slide 46 of http://www.slides

Re: [firebird-support] Re: Awaiting Garbage Collector

2015-03-25 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Hi Alexey Yes, that's right, I can not understand well the page 46. I suppose that R1 means "record version 1", R2 means "record version 2", etc. Tx16 did the INSERT? Tx12 can do a COMMIT although it had started before Tx16 and Tx18 is still active? Tx25 can change what Tx14 did although Tx14 is

Re: [firebird-support] Re: Awaiting Garbage Collector

2015-03-24 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Hello Alexey Your presentation is an excellent work, as ever. I had wrote an article in my blog about it: https://firebird21.wordpress.com/2015/03/23/presentacion-sobre-transacciones-de-alexey-kovyazin/ You had explained very well everything and all can be easily understood. Thank you very much

Re: [firebird-support] Get/set context in derived table context

2015-03-19 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
If you can read Spanish, this article shows several methods for having row numbers in the SELECT. https://firebird21.wordpress.com/2013/05/13/numerando-las-filas-de-un-select/ Greetings. Walter. On Thu, Mar 19, 2015 at 5:28 AM, masb...@za-management.com [firebird-support] wrote: > > > Hi all

Re: [firebird-support] Multiple WHERE clauses

2015-02-25 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Sean: Which is the difference between it: WHERE 1 = CASE WHEN (Param <> 0) THEN 1 WHEN (Some OtherTest) THEN 1 WHEN (Yet another Test) THEN 1 ELSE 0 END and it: Param <> 0 OR SomeOtherTest OR YetAnotherTest ? Because I get the same result with both ways. Greetings. Walter. On Wed, Feb 25,

[firebird-support] Problem with a trigger

2015-02-03 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Hello everybody In a before insert or update trigger I have the following cases: *Case 1:* IF (NEW.MVC_TIPMOV = 'SVT' AND INSERTING AND NEW.MVC_NRODOC = '1') THEN BEGIN END *Case 2:* IF (NEW.MVC_TIPMOV = 'SVT' AND INSERTING OR UPDATING AND NEW.MVC_NRODOC = '1') THEN BEGIN END *Case

Re: [firebird-support] Unlock record

2015-01-23 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Hm, maybe I am doing something wrong, but - I open 2 instances of ISQL.EXE - In ISQL1 I write: SELECT * FROM CLIENTS; - In ISQL2 I write: SELECT MON$TIMESTAMP, MON$TRANSACTION_ID FROM MON$STATEMENTS; - In ISQL1 I write: COMMIT; - In ISQL2 I write: SELECT MON$TIMESTAMP, MON$TRANSACTION_

Re: [firebird-support] Re: Deadlock exception occurs but it shouldn't?

2014-12-29 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Thank you for your explanation Vlad, the proccess is more clear for me now. Greatings. Walter. On Mon, Dec 29, 2014 at 4:55 AM, hv...@users.sourceforge.net [firebird-support] wrote: > > > Walter, > > there are few reasons: > > a) MVCC engine never block records - it just can't :) > > b) the o

Re: [firebird-support] Deadlock exception occurs but it shouldn't?

2014-12-28 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Vlad, your explanation is very good, but I still don't understand something: Why before step 1 the engine does not blocks the record avoiding such problem? Greetings. Walter. On Sat, Dec 27, 2014 at 5:19 AM, hv...@users.sourceforge.net [firebird-support] wrote: > > > Update, internally, con

Re: [firebird-support] Deadlock exception occurs but it shouldn't?

2014-12-26 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Hello Ann Maybe I am not understanding correctly, but: *Case 1:* - Transaction T1 starts with settings: READ WRITE WAIT READ COMMITTED - Transaction T1 updates a record which ID is 23 - Transaction T2 starts with settings: READ WRITE WAIT READ COMMITTED - Transaction T2 updates the s

Re: [firebird-support] Re: Deadlock exception occurs but it shouldn't?

2014-12-25 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Yes, you are right. I had a misconcept. Sorry. Greetings. Walter. On Thu, Dec 25, 2014 at 12:00 PM, Walter R. Ojeda Valiente < sistemas2000profesio...@gmail.com> wrote: > Strange, I will test it, too. Maybe I have a misconcept. > > Greetings. > > Walter. > > > On Thu, Dec 25, 2014 at 11:36 AM

Re: [firebird-support] Re: Deadlock exception occurs but it shouldn't?

2014-12-25 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Strange, I will test it, too. Maybe I have a misconcept. Greetings. Walter. On Thu, Dec 25, 2014 at 11:36 AM, brucedickin...@wp.pl [firebird-support] < firebird-support@yahoogroups.com> wrote: > > > Walter, > > I've tested what you've said. But it does not matter which transactions > blocks re

Re: [firebird-support] Re: Deadlock exception occurs but it shouldn't?

2014-12-25 Thread &#x27;Walter R. Ojeda Valiente' sistemas2000profesio...@gmail.com [firebird-support]
Hello Bruce Yes, transaction T1 can block a row and transaction T2 will wait. But if transaction T2 blocks a row then transaction T1 can not wait and dead. Greetings. Walter. On Thu, Dec 25, 2014 at 7:27 AM, brucedickin...@wp.pl [firebird-support] < firebird-support@yahoogroups.com> wrote: >

  1   2   >