Re: [Firebird-devel] Start transaction from base transaction

2017-04-18 Thread Dimitry Sibiryakov
18.04.2017 21:30, Leyne, Sean wrote: >>With current Firebird architecture - yes. It can be changed. > Really, then why have we been living with that @#$@#$@# limitation for more > than 10 years! Hmmm... Probably, because it is not limitation for real applications? Or because four develop

Re: [Firebird-devel] Start transaction from base transaction

2017-04-18 Thread Dimitry Sibiryakov
18.04.2017 21:13, Leyne, Sean wrote: > I want to push data to another database as fast as possible, I want to have 5 > connections walk the list of tables and read the rows and push them to the > target DB. BTW, for such purpose Oracle have detached tablespaces. You detach such tablespace fr

Re: [Firebird-devel] Start transaction from base transaction

2017-04-18 Thread Dimitry Sibiryakov
18.04.2017 21:13, Leyne, Sean wrote: > No -- with a single connection only 1 SQL can be executed at a time -- > regardless of the number of threads to your process. With current Firebird architecture - yes. It can be changed. > Scenario: > > I want to push data to another database as fast as

Re: [Firebird-devel] Start transaction from base transaction

2017-04-18 Thread Dimitry Sibiryakov
18.04.2017 20:56, Leyne, Sean wrote: > You want a single "view" of the database from multiple _connections_. I still see no point for _multiple_ connections. Isn't one enough? > There is nothing that provides this, today -- There is no way to ensure that > all connections have that same view.

Re: [Firebird-devel] Start transaction from base transaction

2017-04-18 Thread Dimitry Sibiryakov
18.04.2017 18:28, Adriano dos Santos Fernandes wrote: > 2) A multi-threaded program (may be a future version of gbak) wants to > dispatch simultaneous queries to Firebird, so need to use more than one > attachment and transaction and then do not have transaction consistency. I don't see logical

Re: [Firebird-devel] Changing IRoutineMetadata in Plugin::makeProcedure

2017-04-18 Thread Dimitry Sibiryakov
18.04.2017 17:23, Mark Rotteveel wrote: > Real length in characters of a CHAR is length / max bytes per character, > so for UTF-8: length / 4. But if you count real character in this buffer, you can get up to 80 of them. -- WBR, SD. ---

Re: [Firebird-devel] Changing IRoutineMetadata in Plugin::makeProcedure

2017-04-18 Thread Dimitry Sibiryakov
18.04.2017 17:13, Jiří Činčura wrote: > Hmm. Can you elaborate on that? Server doesn't determine real length of string in characters, so it just pad string up to 4*MaxChars bytes with spaces. That's why for CHAR(20) you always get 80 bytes of data, which can contain more that 20 characters

Re: [Firebird-devel] Changing IRoutineMetadata in Plugin::makeProcedure

2017-04-18 Thread Dimitry Sibiryakov
18.04.2017 17:03, Jiří Činčura wrote: > So for CHAR(20) UTF8 CHAR and UTF-8 (generally, any variable character length charset) must never be used together. -- WBR, SD. -- Check out the vibrant tech community on

Re: [Firebird-devel] Changing IRoutineMetadata in Plugin::makeProcedure

2017-04-18 Thread Dimitry Sibiryakov
18.04.2017 16:52, Dmitry Yemanov wrote: > Generally it is, unless SQL_TEXT is of length 32766 or 32767. Isn't vary.vary_length declared as unsigned short? -- WBR, SD. -- Check out the vibrant tech community on on

Re: [Firebird-devel] Changing IRoutineMetadata in Plugin::makeProcedure

2017-04-18 Thread Dimitry Sibiryakov
18.04.2017 16:40, Jiří Činčura wrote: > Isn't there a constant for i.e. > SQL_TIMESTAMP? Because it's always 8 bytes, but feels wrong to hardcode > it manually myself. sizeof(ISC_TIMESTAMP) -- WBR, SD. -- Check o

Re: [Firebird-devel] Fwd: Firebird 3 in the Repositorys Linux

2017-03-31 Thread Dimitry Sibiryakov
31.03.2017 16:10, Julio Sardenberg wrote: > I am a Linux and Firebird user / administrator and I see that version 3 still > does not > exist in the default repository of Linux distributions today. In most of Linux distributions it is already in default repository. Only slow distros like Debi

Re: [Firebird-devel] Some ideas about PSQL debugger feature

2017-03-30 Thread Dimitry Sibiryakov
30.03.2017 20:13, Adriano dos Santos Fernandes wrote: > Debugging features are well-know. GDB, MSVC and Delphi all have very different debugging features. Which one is well know for you? -- WBR, SD. -- Check ou

Re: [Firebird-devel] Some ideas about PSQL debugger feature

2017-03-30 Thread Dimitry Sibiryakov
30.03.2017 20:16, Alex Peshkoff wrote: > Use more or less same technique which is used by trace. The simplest way is to expand trace capacities with information required for debugging. And even if "debugging" is "well-known" it still must be exactly defined before implementation. --

Re: [Firebird-devel] Some ideas about PSQL debugger feature

2017-03-30 Thread Dimitry Sibiryakov
30.03.2017 19:50, Adriano dos Santos Fernandes wrote: > Currently missing (official / really correct) support for PSQL debugging > is IMO something about trick decisions to make a really useful tool. I would prefer at first to figure out what functionality is required for such tool. Perhaps,

Re: [Firebird-devel] GPRE and Pascal

2017-03-30 Thread Dimitry Sibiryakov
30.03.2017 18:19, Frank Schlottmann-Gödde wrote: > From the stone age: > > http://firebird.cvs.sourceforge.net/viewvc/firebird/interbase/examples/ Wow! I thought that I know Pascal before I've seen this: > var > blanks: array [1..40] of char := [* of ' ']; -- WBR, SD. -

[Firebird-devel] GPRE and Pascal

2017-03-29 Thread Dimitry Sibiryakov
Hello, All. Which Pascal compiler is supposed to be used with GPRE'd programs? Is there an example of a Pascal program with ESQL? -- WBR, SD. -- Check out the vibrant tech community on one of the world's most

[Firebird-devel] blr_varying2 format

2017-03-28 Thread Dimitry Sibiryakov
Hello, All. For blr_varying2 correct BLR format is <2 bytes charset><2 bytes length> and the length is expected to be _without_ additional 2 bytes, right? Does anyone know? -- WBR, SD. -- Check out the vib

[Firebird-devel] blr_varying2 format

2017-03-27 Thread Dimitry Sibiryakov
Hello, All. For blr_varying2 correct BLR format is <2 bytes charset><2 bytes length> and the length is expected to be _without_ additional 2 bytes, right? -- WBR, SD. -- Check out the vibrant tech community o

Re: [Firebird-devel] x64 fblient.dll ISC_STATUS data type vs. lib version

2017-03-25 Thread Dimitry Sibiryakov
25.03.2017 18:24, malloc meyer wrote: > I identified that Firebird 1.5 and 2.0 defines ISC_STATUS as long, 2.1 and > newer as > intptr_t. Is there an easy way to ask the lib to which version it belongs? You don't need that. Always define ISC_STATUS as something of pointer size. -- WBR, S

Re: [Firebird-devel] [FB-Tracker] Created: (CORE-5507) Wrong value of the new field at the old records, created before that new field was added.

2017-03-24 Thread Dimitry Sibiryakov
24.03.2017 10:29, Vlad Khorsun wrote: >Not sure i understand what you mean but sweep never updates records. My knowledge of Firebird is overestimated, you know. Isn't there an internal routine that converts records into the latest format whenever it reads them? -- WBR, SD.

Re: [Firebird-devel] [FB-Tracker] Created: (CORE-5507) Wrong value of the new field at the old records, created before that new field was added.

2017-03-24 Thread Dimitry Sibiryakov
24.03.2017 6:53, Vlad Khorsun wrote: >Engine doesn't assing values to a new field, i.e. there is no implicit > UPDATE of > the existing records. This is strong point of the engine, btw. Is it possible that in your testcase sweep performed implicit update between DDLs? -- WBR, SD. -

Re: [Firebird-devel] x64 fblient.dll ISC_STATUS data type vs. lib version

2017-03-23 Thread Dimitry Sibiryakov
23.03.2017 21:47, malloc meyer wrote: > My question ist, was there any version in past of the fbclient API for x64 > windows which defines ISC_STATUS as a 32 bit integer ? No. Status array contains (among other information) also pointers. -- WBR, SD.

Re: [Firebird-devel] unix2dos

2017-03-23 Thread Dimitry Sibiryakov
23.03.2017 16:09, Paul Reeves wrote: > The reason we need it is because git seems to check (some) files out > with LF eols and we need to deploy all text files with CR LF eols. It can be changed in .gitattributes. > Yes, weirdly, gnuwin32 seems to implement non-standard parameters, at > least

Re: [Firebird-devel] unix2dos

2017-03-23 Thread Dimitry Sibiryakov
23.03.2017 16:13, Alex Peshkoff wrote: > What? git unable to treat .bat file as normal text and can't checkout it > according to OS rules? > (like it does for .cpp, .h and a lot of other files) > Sorry, hard to believe... Sooner that's our configuration error somewhere. Yes, it is configurable.

Re: [Firebird-devel] unix2dos

2017-03-23 Thread Dimitry Sibiryakov
23.03.2017 15:58, Alex Peshkoff wrote: > Occasionally BuildExecutableInstall.bat itself was wrongly committed to > git - checked outon linux it has CR-LF lineend instead just LF. I.e. > itself needs unix2dos ;) Luckily it does not actually matter. Actually, it does matter. Stupid Windows comman

Re: [Firebird-devel] unix2dos

2017-03-23 Thread Dimitry Sibiryakov
23.03.2017 15:44, Alex Peshkoff wrote: > I wonder - what scripts do you mean, grepping in our > master/builds/install does not find unix2dos. B3_0_Release branch, install/arch-specific/win32/BuildExecutableInstall.bat -- WBR, SD. --

[Firebird-devel] unix2dos

2017-03-23 Thread Dimitry Sibiryakov
Hello, All. What version/build of subj supports '-D' switch and what it is supposed to do in installation build script? If only to convert EOL marks, it is job for '-ascii' switch... -- WBR, SD. -- Check out

Re: [Firebird-devel] NBAK simplification RFC

2017-03-20 Thread Dimitry Sibiryakov
20.03.2017 18:06, Dmitry Yemanov wrote: > I suppose Nickolay means replacing GlobalRWLock with native OS-level RW > primitives used similar to shared memory mutexes. For Windows, they're > just shared as named objects, for POSIX they're stored in shmem. On Windows they also could be Critical Se

Re: [Firebird-devel] [SPAM] Re: GPRE and VARBINARY

2017-03-07 Thread Dimitry Sibiryakov
05.03.2017 17:05, Vlad Khorsun wrote: >>I'll try to implement support for varying string in GPRE, but it can take >> time. In >Not sure it is requred at all... after so many years Support of BOOLEAN was added. Why not to support (VAR)BINARY as well?.. >> meantime I'd suggest to change

Re: [Firebird-devel] GPRE and VARBINARY

2017-03-05 Thread Dimitry Sibiryakov
05.03.2017 16:59, Adriano dos Santos Fernandes wrote: > Wasn't VARBINARY a syntatic sugar for VARCHAR CHARACTER SET OCTETS? It was supposed to be so. But one little thing make difference: subtype. > It looks like if things works different (even in a non ideal condition), > there is a bug in th

Re: [Firebird-devel] GPRE and VARBINARY

2017-03-05 Thread Dimitry Sibiryakov
05.03.2017 16:34, Adriano dos Santos Fernandes wrote: >>I don't know BLR, so I can't say what verb must be used for VARYING. >> > blr_varying ? Yes, it looks like a right thing. Unfortunately, currently GPRE doesn't support this verb at all. The only types that it can handle is blr_text f

Re: [Firebird-devel] GPRE and VARBINARY

2017-03-05 Thread Dimitry Sibiryakov
05.03.2017 14:09, Vlad Khorsun wrote: >I see blr_cstring in fb3 and blr_text in fb4. Yes, and this is the source of additional zeros in tail of legacy hash if I'm not mistaken. Besides, char[256] is a too big buffer for VARBINARY(64). I don't know BLR, so I can't say what verb must b

[Firebird-devel] GPRE and VARBINARY

2017-03-05 Thread Dimitry Sibiryakov
Hello, All. What BLR and data type must generate GPRE for retrieving/storage of VARBINARY fields? For VARCHAR CHARACTER SET OCTETS it used to generate blr_cstring and plain char[], which is, IMHO, incorrect because binary strings can contain '\0' characters. Opinions? -- WBR, S

Re: [Firebird-devel] Legacy usermanager broken in Firebird 4?

2017-03-05 Thread Dimitry Sibiryakov
04.03.2017 23:37, Dimitry Sibiryakov wrote: > It is because of use fb_utils::copy_terminate() instead of strStore() for > storing password > in LegacyManagement.epp. I'm sorry, I was wrong. Perhaps, indeed, introducing of VARBINARY caused GPRE to generate wrong BLR

Re: [Firebird-devel] Legacy usermanager broken in Firebird 4?

2017-03-04 Thread Dimitry Sibiryakov
04.03.2017 22:52, Vlad Khorsun wrote: > The reason is that hash of encrypted > passwords is stored with trailing zero's now (guess it was due to recently > introduced support of BINARY chars). No. It is because of use fb_utils::copy_terminate() instead of strStore() for storing password in Le

Re: [Firebird-devel] [FB-Tracker] Created: (CORE-5493) Add context variable about transaction start timestamp

2017-03-03 Thread Dimitry Sibiryakov
03.03.2017 12:48, Vlad Khorsun wrote: >Should we never add new non-standard system functions because of this ? May be you should give them RDB$ prefix. -- WBR, SD. -- Check out the vibrant tech community on o

Re: [Firebird-devel] [FB-Tracker] Created: (CORE-5493) Add context variable about transaction start timestamp

2017-03-01 Thread Dimitry Sibiryakov
01.03.2017 17:38, Dmitry Yemanov wrote: > It could be confused with attachment-start timestamp. Add both. ;-) -- WBR, SD. -- Check out the vibrant tech community on one of the world's most engaging tech sites, Sl

Re: [Firebird-devel] [FB-Tracker] Created: (CORE-5493) Add context variable about transaction start timestamp

2017-03-01 Thread Dimitry Sibiryakov
01.03.2017 17:24, Vlad Khorsun wrote: > As for the name, i prefer CURRENT_TRANSACTION_TIME or > CURRENT_TRANSACTION_TIMESTAMP. If this variable is added as a context variable into "SYSTEM" namespace, simple "START_TIMESTAMP" should be enough, as none of transaction-related variables there h

Re: [Firebird-devel] [FB-Tracker] Created: (CORE-5493) Add context variable about transaction start timestamp

2017-03-01 Thread Dimitry Sibiryakov
01.03.2017 17:24, Vlad Khorsun wrote: >Is there any objection to add it into upcoming v3.0.2 and v4 ? 3.0 is supposed to be a feature-stable branch. -- WBR, SD. -- Check out the vibrant tech community on one

Re: [Firebird-devel] RFC: Timeouts

2017-02-26 Thread Dimitry Sibiryakov
26.02.2017 12:39, Simonov Denis wrote: > However, bidirectional cursors are still not supported on the > client side. Yes. But still a new feature must be made with taking into account not only current features but future ones as well. Otherwise it could block development of them or will ha

Re: [Firebird-devel] RFC: Timeouts

2017-02-26 Thread Dimitry Sibiryakov
26.02.2017 11:55, Simonov Denis wrote: > In terms of > engine SQL statement must be completed to stop the timer, if it is a > select query to include fetches of all records. Shouldn't this timer run till call isc_free_statement(..., DSQL_close) instead of fetch of the last record? Bidirection

Re: [Firebird-devel] RFC: Timeouts

2017-02-25 Thread Dimitry Sibiryakov
25.02.2017 10:49, Dmitry Yemanov wrote: > Depending on the plan, statement may take 99% of its "working" time > inside execute() or inside fetch() or that time could be distributed > among the API calls. Neither client nor DBA has any control on that. So > I consider seriously wrong removing fetchi

[Firebird-devel] [FB-Tracker] Created: (CORE-5483) Expand functionality of null indicator in API

2017-02-13 Thread Dimitry Sibiryakov (JIRA)
/ Client Library Reporter: Dimitry Sibiryakov Currently in input SQLDA/messsage null indicator can have two meaningful values: 0 for not null data and -1 for null indication. It would be useful to add more: 1) A value indicating "set field to default", which is API support for CO

Re: [Firebird-devel] New BLR encoding

2017-02-10 Thread Dimitry Sibiryakov
10.02.2017 16:32, Adriano dos Santos Fernandes wrote: > Firebird BLR must be improved to be easier to read (the code), to be > easier to generate and parse and to be extensible. Why to improve something that must die?.. -- WBR, SD.

[Firebird-devel] [FB-Tracker] Created: (CORE-5469) Statement handles allocated with isc_dsql_alloc_statement2() are not cleaned on detach

2017-01-25 Thread Dimitry Sibiryakov (JIRA)
: Firebird Core Issue Type: Bug Components: API / Client Library Affects Versions: 3.0.1, 3.0.0, 4.0 Initial Reporter: Dimitry Sibiryakov Attachments: alloc2.cpp.7z According to API Guide, "the isc_dsql_allocate_statement2() function is similar t

Re: [Firebird-devel] -std=c++11 added to CXXFLAGS in 3.0 on linux

2017-01-20 Thread Dimitry Sibiryakov
20.01.2017 11:25, Treeve Jelbert wrote: > The latest git version, e8dd0b1, crashes when -msse4 is specified. > > boot_isql : llegal instruction Which exactly instruction is illegal? What bits are returned in ecx by __cpuid() function on your notebook? -- WBR, SD. -

Re: [Firebird-devel] [FB-Tracker] Created: (CORE-5460) Insert NULL into identity column with auth generated value

2017-01-19 Thread Dimitry Sibiryakov
19.01.2017 11:03, Adriano dos Santos Fernandes wrote: > c) If for some n, some underlying column of the column referenced by the > CN contained > in the n-th ordinal position in is an identity > column whose descriptor includes an > indication that values are generated by default, then if claus

[Firebird-devel] Looking for new object id

2017-01-18 Thread Dimitry Sibiryakov
Hello, All. When Firebird looks for free id for a new object it does not recognize which unique constraint is violated. As the result, following script takes quite much time before showing error: create database "test"; create or alter sequence aaa start with 1000; set autoddl off; crea

Re: [Firebird-devel] Virtual metadata

2017-01-18 Thread Dimitry Sibiryakov
18.01.2017 11:09, Dmitry Yemanov wrote: > I would seriously question the need to allow concurrent DDL against the > same objects. This is simply not the way people work with the relational > databases. I'd rather lock the metadata being changed at the DDL time > and until commit. +1 -- WB

Re: [Firebird-devel] Virtual metadata

2017-01-18 Thread Dimitry Sibiryakov
18.01.2017 10:53, Alex Peshkoff wrote: > Statements prepared in a transaction performing DDL changes should not > be usable in context of other transactions. Reverse rule should also be > true - statement prepared outside particular DDL transaction is not > usable in it. This will be new restrictio

Re: [Firebird-devel] Virtual metadata

2017-01-17 Thread Dimitry Sibiryakov
17.01.2017 17:24, Adriano dos Santos Fernandes wrote: >>From these two, I know the later is the worse thing can happen in a > production environment: > > - A database with can't be updated due to locks > > - A updated database which code running various versions of changed > logic depending on when

Re: [Firebird-devel] Virtual metadata

2017-01-17 Thread Dimitry Sibiryakov
17.01.2017 17:07, Adriano dos Santos Fernandes wrote: > Statement may already be prepared and allowed to be used not only in > this dirty transaction, but in others one. I would say that some kind "statement-level metadata consistency" should be used for such cases: statement to see metadata

Re: [Firebird-devel] Virtual metadata

2017-01-17 Thread Dimitry Sibiryakov
17.01.2017 16:35, Adriano dos Santos Fernandes wrote: > Temporary invalidated state is incompatible with DDL+DML using the > being-changed DDL: It just require some decisions. > create table t (n integer, c computed by (f(n))); > -- create function f ... > commit; > > drop function f; > s

Re: [Firebird-devel] linux build failure - security.sql (bisected)

2017-01-17 Thread Dimitry Sibiryakov
17.01.2017 15:00, Alex Peshkoff wrote: > This way reserved word becomes non-reserved. Looks at > > valid_symbol_name > : SYMBOL > | non_reserved_word > ; > > followed by list of non_reserved_word-s. Including "BINARY" into caused a lot of reduce/reduce conflicts. -- WBR,

Re: [Firebird-devel] Virtual metadata

2017-01-17 Thread Dimitry Sibiryakov
17.01.2017 14:29, Adriano dos Santos Fernandes wrote: >>>But what exactly "invalid state" means? I can't imagine anything but >>> violation of >>> "foreign key" on table rdb$dependencies. If Firebird ever is going to have >>> deferred >>> constraints, allowing some metadata to be inconsistent

Re: [Firebird-devel] linux build failure - security.sql (bisected)

2017-01-17 Thread Dimitry Sibiryakov
17.01.2017 14:13, Adriano dos Santos Fernandes wrote: > I believe this is the thing we need to do. > > Just something as "identifier | BINARY" rule. Better would be something like "identifier | ", but I have no idea how to do it with btyacc. -- WBR, SD.

Re: [Firebird-devel] linux build failure - security.sql (bisected)

2017-01-17 Thread Dimitry Sibiryakov
17.01.2017 13:19, Michal Kubecek wrote: > This does the trick, the build succeeds then. Good to know, thanks. I'll create pull request. -- WBR, SD. -- Check out the vibrant tech community on one of the world's mo

Re: [Firebird-devel] Virtual metadata

2017-01-17 Thread Dimitry Sibiryakov
17.01.2017 13:03, Adriano dos Santos Fernandes wrote: > If any other solution allows "valid state (initial) -> invalid state > (uncommitted) -> valid state (committed)" more DML changes in the same > objects, it's ok for me. Personally, I think the concepts does not match. But what exactly "inv

Re: [Firebird-devel] Virtual metadata

2017-01-17 Thread Dimitry Sibiryakov
17.01.2017 12:25, Dmitry Yemanov wrote: > Perhaps it's worth starting from deprecating DFW and only then come back > to the metadata versioning? I never suggested to run to everything at once. I don't know about Adriano's idea, but my one can be done step-by-step. -- WBR, SD. -

Re: [Firebird-devel] linux build failure - security.sql (bisected)

2017-01-17 Thread Dimitry Sibiryakov
17.01.2017 11:57, Adriano dos Santos Fernandes wrote: > Yep? Ok to break lots of applications? I, personally, always used "CHARACTER SET OCTETS" and never even heard about charset "BINARY". -- WBR, SD. -- Check

Re: [Firebird-devel] Virtual metadata

2017-01-17 Thread Dimitry Sibiryakov
17.01.2017 11:26, Dmitry Yemanov wrote: > Sounds too hackish to my taste I always feel the same when I see special treating of system tables and system transaction in VIO routines. -- WBR, SD. -- Check out the

Re: [Firebird-devel] linux build failure - security.sql (bisected)

2017-01-17 Thread Dimitry Sibiryakov
17.01.2017 9:47, Michal Kubecek wrote: > The offending line seems to be > > CREATE DOMAIN PLG$PASSWD AS VARCHAR(64) CHARACTER SET BINARY; > > I bisected it to commit > > 7b9b408658e1 Implementation of CORE-5064 (#73) > > I didn't look too deep but maybe newly introduced type "binary" collides

Re: [Firebird-devel] Virtual metadata

2017-01-17 Thread Dimitry Sibiryakov
17.01.2017 8:16, Dmitry Yemanov wrote: > Transaction creates a new format, stores some records using this new > format, then the server dies. After restart, changes in > RDB$FORMATS/RDB$RELATIONS are occasionally backed out. Then it could be > impossible to garbage collect the new record versions d

Re: [Firebird-devel] Virtual metadata

2017-01-17 Thread Dimitry Sibiryakov
17.01.2017 8:03, Dmitry Yemanov wrote: > You miss my point. It's written into RDB$FORMATS/RDB$RELATIONS but not > committed because transaction is still active. So concurrent > transactions cannot see these changes, accordingly to your versioning > approach. But VIO_get_current() must see them. Do

Re: [Firebird-devel] Virtual metadata

2017-01-17 Thread Dimitry Sibiryakov
17.01.2017 7:54, Dmitry Yemanov wrote: > How does your idea address this? Between CREATE TABLE and INSERT page > space (PP, IRP) must be allocated and initialized. And this cannot be > reverted via the undo log in the case of rollback. It can. PP is bound to RDB$RELATIONS and IRP to RDB$INDICES

Re: [Firebird-devel] Virtual metadata

2017-01-16 Thread Dimitry Sibiryakov
16.01.2017 22:26, Adriano dos Santos Fernandes wrote: > The semantics of this is even unthinkable, and I doubt anyone is doing > it in database world. PostgreSQL does IIRC. -- WBR, SD. -- Check out the vibrant te

Re: [Firebird-devel] Virtual metadata

2017-01-16 Thread Dimitry Sibiryakov
16.01.2017 21:52, Adriano dos Santos Fernandes wrote: > It wasn't in my requirements, but it would be possible. > > create table ... > as > select ... > > Would run the select and fill the table at commit time. Oh, then I misread your suggestion. I read it as "let's create table/view/sp in mem

Re: [Firebird-devel] Virtual metadata

2017-01-16 Thread Dimitry Sibiryakov
16.01.2017 21:08, Adriano dos Santos Fernandes wrote: > DML changes in the same transaction uses real metadata, i.e., DDL being > changed does not affect DML or metadata cache. > > Virtual metadata is specific to DDL. > > Record format will be generated when applying the changes in commit. Then

Re: [Firebird-devel] Virtual metadata

2017-01-16 Thread Dimitry Sibiryakov
16.01.2017 20:23, Dmitry Yemanov wrote: > But what about low-level logic like > VIO_get_current() which must see uncommitted changes? If format is created at the end of DDL execution (instead of DFW), it can/must be written into database before any DML can write any record with new format.

Re: [Firebird-devel] Virtual metadata

2017-01-16 Thread Dimitry Sibiryakov
16.01.2017 19:42, Dmitry Yemanov wrote: > But I fail to see how these ideas are > going to work for table format changes. How would records be stored > accordingly to the "virtual" formats? How are formats going to be > uniquely (but without gaps!) numbered across uncommitted transactions? Why

Re: [Firebird-devel] Virtual metadata

2017-01-16 Thread Dimitry Sibiryakov
15.01.2017 19:00, Adriano dos Santos Fernandes wrote: > So what I call virtual metadata and how would it solve the problems: > > When a DDL command is issued, it will not change metadata directly. It > will change metadata in a memory structure tied to the current transaction. > > It may read metad

Re: [Firebird-devel] Virtual metadata

2017-01-15 Thread Dimitry Sibiryakov
15.01.2017 19:00, Adriano dos Santos Fernandes wrote: > So what I call virtual metadata and how would it solve the problems: Sounds not bad, but requires more programming and is less effective than versioned metadata cache. > When a DDL command is issued, it will not change metadata directly

Re: [Firebird-devel] Code style - right margin

2017-01-15 Thread Dimitry Sibiryakov
15.01.2017 15:50, Adriano dos Santos Fernandes wrote: > What is our maximum code right margin? http://www.firebirdsql.org/en/coding-style/ -- WBR, SD. -- Developer Access Program for Intel Xeon Phi Processors Access

Re: [Firebird-devel] Firebird 4 identifier limits

2017-01-12 Thread Dimitry Sibiryakov
12.01.2017 13:27, Mark Rotteveel wrote: >> I just noticed that in Firebird 4 the identifier length limits are >> configurable. >> >> Is there a maximum length, or can I theoretically use a length of say >> 8191 characters for an identifier? >> >> Is there a quick and easy way to determine the maxim

Re: [Firebird-devel] [FB-Tracker] Created: (CORE-5419) Index garbage collection on varchar column causes server to hang

2017-01-11 Thread Dimitry Sibiryakov
11.01.2017 13:22, Alex Peshkoff wrote: > I've used embedded connections. That can make a difference as you excluded all operations with security database and connection handshaking from workflow. -- WBR, SD. --

Re: [Firebird-devel] [FB-Tracker] Created: (CORE-5419) Index garbage collection on varchar column causes server to hang

2017-01-11 Thread Dimitry Sibiryakov
11.01.2017 12:18, Alex Peshkoff wrote: > I can not reproduce initial issue in master branch on linux. Can it be issue specific to CentOS? -- WBR, SD. -- Developer Access Program for Intel Xeon Phi Processors Acce

Re: [Firebird-devel] Firebird 4 features

2017-01-04 Thread Dimitry Sibiryakov
04.01.2017 11:44, Alex Peshkoff wrote: > - why charset OCTETS should be represented as sybtype, not charset? Not charset, but type "BINARY". Even if it is just an alias, it deserves to be distinguishable from parent type the same way as are INTEGER/DECIMAL/NUMERIC. > - what else subtypes mak

Re: [Firebird-devel] Firebird 4 features

2017-01-04 Thread Dimitry Sibiryakov
04.01.2017 11:30, Dmitry Yemanov wrote: > AFAIU, ticket suggests to match API's subtype also to field's subtype, > in addition to matching it to the field's charset/collation. AFAIU, it was suggested only for compatibility with ISC API which is deprecated anyway. > But IMO it > means that we

Re: [Firebird-devel] Firebird 4 features

2017-01-04 Thread Dimitry Sibiryakov
04.01.2017 11:06, Alex Peshkoff wrote: > Sooner of all I'm missing something but please explain - what is the > difference between them? "RDB$FIELD_SUB_TYPE (in RDB$FIELDS and RDB$FUNCTION_ARGUMENTS)". > I'm not sure what do we win with suggested change. "This has the added benefit that to

Re: [Firebird-devel] Firebird 4 features

2017-01-03 Thread Dimitry Sibiryakov
30.12.2016 17:06, Dmitry Yemanov wrote: >> Do anybody object if I try to dig a little into CORE-5064? > No, feel free. I've managed to make binary strings accessible at sql level, but found that whole engine, starting from dsc is not prepared to handle sql_sub_type and character set separat

[Firebird-devel] Binary text subtype

2017-01-02 Thread Dimitry Sibiryakov
Hello, All. What would be the right constant for binary field subtype: ttype_binary, CS_BINARY or dsc_text_type_fixed? They all have value 1. -- WBR, SD. -- Check out the vibrant tech community on one of the

Re: [Firebird-devel] Firebird 4 features

2016-12-30 Thread Dimitry Sibiryakov
30.12.2016 15:59, Alex Peshkoff wrote: > Definitely not limited. But it's good idea to discuss new feature before > implementing it (specially if it's not already in the tracker). Ok. Do anybody object if I try to dig a little into CORE-5064? -- WBR, SD. -

Re: [Firebird-devel] Wire protocol changes in Firebird 4?

2016-12-30 Thread Dimitry Sibiryakov
30.12.2016 15:52, Kovalenko Dmitry wrote: > No. It need for resolve a problem with cancelation of operations. > > http://tracker.firebirdsql.org/browse/CORE-5152 I'm sorry, but could you explain a little: how packet length can help in this case? > It will allow with minimal efforts detect the

[Firebird-devel] Firebird 4 features

2016-12-30 Thread Dimitry Sibiryakov
Hello, All. Is list of features for version 4 limited to listed in roadmap? I.e. if I pull request for something else will it be rejected for sure? -- WBR, SD. -- Check out the vibrant tech community on one

Re: [Firebird-devel] Wire protocol changes in Firebird 4?

2016-12-30 Thread Dimitry Sibiryakov
30.12.2016 12:19, Dimitry Sibiryakov wrote: > 1) Core team have no time for it. > 2) Core team have no time to review big patches from outsiders. > 3) Backward compatibility has to be kept. 4) Knowledge of total length of packet is required only for current parser which need full pac

Re: [Firebird-devel] Wire protocol changes in Firebird 4?

2016-12-30 Thread Dimitry Sibiryakov
30.12.2016 12:10, Kovalenko Dmitry wrote: >>From my point of view, protocol must be rewrited > > At minimum: > 1. The each packet should contain the field with own size. > 2. It is necessary to solve the problems with LazySend mode. 1) Core team have no time for it. 2) Core team have no time to re

Re: [Firebird-devel] FB2.5.6 - '' = ' ' is evaluated as true

2016-12-07 Thread Dimitry Sibiryakov
07.12.2016 14:24, Slavomir Skopalik wrote: > is it correct Yes, it is correct according to collation definition. -- WBR, SD. -- Developer Access Program for Intel Xeon Phi Processors Access to Intel Xeon Phi proc

Re: [Firebird-devel] IUtil::formatMessage

2016-12-01 Thread Dimitry Sibiryakov
01.12.2016 18:01, Adriano dos Santos Fernandes wrote: > IStatus is meant to be implemented by who wants to have whatever way to > manage its memory. And whoever implements own way to keep status is in the best position to implement interpretation of the status, right? > And format does not d

[Firebird-devel] IUtil::formatMessage

2016-12-01 Thread Dimitry Sibiryakov
Hello, All. Reading of Helen's book made me wonder: why formatMessage is the method of IUtil, not IStatus? -- WBR, SD. -- Firebird-Devel mailing list, web interface at https://lists.sourceforge.net/lists/lis

Re: [Firebird-devel] arithmetic exception, numeric overflow, or string truncation after change column datatype and select from older format view

2016-11-23 Thread Dimitry Sibiryakov
23.11.2016 14:54, Adriano dos Santos Fernandes wrote: > But that (DDL changes with concurrent sessions) is unreliable. > > And if you change a single view that recompiles 100 views, you multiple > the unreliability by 100 in the production environment. That's why I, personally, prefer to prohib

Re: [Firebird-devel] [FirebirdSQL/firebird] 5aede1: Decimal floating point numbers - first draft

2016-11-13 Thread Dimitry Sibiryakov
13.11.2016 17:40, Dmitry Yemanov wrote: > I do see the difference with REAL but I'm asking for a difference with > NUMERIC backed by int32/int64. Most of compilers nowadays support int128 as well directly or via intrinsic. I would guess that to expand current arithmetic to int128 is simpler t

Re: [Firebird-devel] new API IMetadataBuilder Bigint[1:100]

2016-11-13 Thread Dimitry Sibiryakov
13.11.2016 11:50, Adriano dos Santos Fernandes wrote: > Old API is a client of the new API Yes, I know. I took part in it if you forget. > so you're totally wrong. Feel free to provide a better answer if you can. Can you?.. -- WBR, SD. ---

Re: [Firebird-devel] new API IMetadataBuilder Bigint[1:100]

2016-11-13 Thread Dimitry Sibiryakov
13.11.2016 10:24, Norbert Saint Georges wrote: > in new API, How to declare an array of bigint? New API does not work with arrays. -- WBR, SD. -- Developer Access Program for Intel Xeon Phi Processors Access to I

Re: [Firebird-devel] Fwd: [Firebird-checkins] [FirebirdSQL/firebird] 5aede1: Decimal floating point numbers - first draft

2016-11-11 Thread Dimitry Sibiryakov
11.11.2016 16:20, Alex Peshkoff wrote: > What's done: > - Added new datatypes: DECFLOAT(16) and DECFLOAT(34), using 64/128 bits > for numbers representation. What is the point of these new types? Cannot you just expand list of back-end storage for standard DECIMAL? -- WBR, SD.

Re: [Firebird-devel] (CORE-4563): Add support for Windows 8/2012 fast/low-latency "TCP Loopback Fast Path" functionality

2016-11-11 Thread Dimitry Sibiryakov
11.11.2016 10:06, Karsten Strobel wrote: > Compared to MS SQL, Firdbird’s localhost TCP roundtrips from Client to Server > for doing > things like single-row inserts or updates take significantly longer. There > may be a > several reasons for this. The most viable one that MS SQL uses shared

Re: [Firebird-devel] Coroutines

2016-10-26 Thread Dimitry Sibiryakov
26.10.2016 16:41, Adriano dos Santos Fernandes wrote: > We can't *callback* our caller. Why not? It is a matter of adding one method to your new API: class IEater { int pushData(IMessageMetadata* metadata, void* buffer); }; IStatus* IAttachment::execute(const char* SQL, IMessageMetada

Re: [Firebird-devel] Coroutines

2016-10-26 Thread Dimitry Sibiryakov
26.10.2016 13:33, Adriano dos Santos Fernandes wrote: > This is so nice (and apparent fast in Linux) that I'm going to > investigate further. It must be more than just nice to add gigabyte of boost sources or 30 megabytes library to Firebird. -- WBR, SD. ---

[Firebird-devel] [FB-Tracker] Created: (CORE-5376) New API example crashes

2016-10-14 Thread Dimitry Sibiryakov (JIRA)
Environment: Windows, Delphi 2006, Firebird 3.0.1 Reporter: Dimitry Sibiryakov Example 01.create.pas crashes on run because master.getUtilInterface returns nil. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators

Re: [Firebird-devel] Code readability

2016-10-13 Thread Dimitry Sibiryakov
13.10.2016 14:28, Alex Peshkoff wrote: > That's an answer. Could you explain how difference in one character makes "beautiful and sensitive" code "ugly and non-sense"? For me both these lines are ugly. > Rework your patch please. As you wish. -- WBR, SD. ---

Re: [Firebird-devel] Code readability

2016-10-13 Thread Dimitry Sibiryakov
13.10.2016 14:04, Adriano dos Santos Fernandes wrote: > This line is ugly and non-sense. That's not an answer to what I asked about. -- WBR, SD. -- Check out the vibrant tech community on one of the world's most

<    6   7   8   9   10   11   12   13   14   15   >