[firebird-support] Re: Firebird::UtilInterfacePtr()->getPerfCounters

2018-05-31 Thread Norbert Saint Georges n...@tetrasys.eu [firebird-support]
Norbert Saint Georges n...@tetrasys.eu [firebird-support] a écrit :
> where can I find them?

ok in ../../yvalve/perf.cpp

#define TOTAL_COUNTERS 11

// we use case-insensitive names, here they are written with capital 
letters for human readability
KnownCounters knownCounters[TOTAL_COUNTERS] = {
{"RealTime", CNT_TIMER, CNT_TIME_REAL},
{"UserTime", CNT_TIMER, CNT_TIME_USER},
{"SystemTime", CNT_TIMER, CNT_TIME_SYSTEM},
{"Fetches", CNT_DB_INFO, isc_info_fetches},
{"Marks", CNT_DB_INFO, isc_info_marks},
{"Reads", CNT_DB_INFO, isc_info_reads},
{"Writes", CNT_DB_INFO, isc_info_writes},
{"CurrentMemory", CNT_DB_INFO, isc_info_current_memory},
{"MaxMemory", CNT_DB_INFO, isc_info_max_memory},
{"Buffers", CNT_DB_INFO, isc_info_num_buffers},
{"PageSize", CNT_DB_INFO, isc_info_page_size}
};

-- 
Norbert Saint Georges
http://tetrasys.fi







++

Visit http://www.firebirdsql.org and click the Documentation item
on the main (top) menu.  Try FAQ and other links from the left-side menu there.

Also search the knowledgebases at http://www.ibphoenix.com/resources/documents/ 

++


Yahoo Groups Links

<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/firebird-support/

<*> Your email settings:
Individual Email | Traditional

<*> To change settings online go to:
http://groups.yahoo.com/group/firebird-support/join
(Yahoo! ID required)

<*> To change settings via email:
firebird-support-dig...@yahoogroups.com 
firebird-support-fullfeatu...@yahoogroups.com

<*> To unsubscribe from this group, send an email to:
firebird-support-unsubscr...@yahoogroups.com

<*> Your use of Yahoo Groups is subject to:
https://info.yahoo.com/legal/us/yahoo/utos/terms/



Re: [firebird-support] Re: Firebird 3: Not able to UPDATE RDB$Procedures

2018-05-31 Thread Helen Borrie hele...@iinet.net.au [firebird-support]

> Also, apparently, this is not a blanket restriction, since I can   
> successfully run the UPDATE RDB$PROCEDURES on at least 1 other  
> converted DB (that is essentially the same as the DB I cannot runthis 
> UPDATE on).

Smells like a privileges problem.  The updater has to be SYSDBA,
rdb$owner_name or (on POSIX) root.  Could also be a regular user that
has been granted and is logged in under the RDB$ADMIN role, or one that
has been granted metadata privs on procedures through user name or
role.

HB


---
This email has been checked for viruses by AVG.
https://www.avg.com



Re: [firebird-support] Re: Firebird 3: Not able to UPDATE RDB$Procedures

2018-05-31 Thread blackfalconsoftw...@outlook.com [firebird-support]
Thanks for the heads up, Mark...
 

 However, Carlos' explanation when I read through it again, does appear to be a 
little confusing at the least.
 

 Why not simply disallow it altogether and be consistent?
 

 As I just mentioned in another reply to you, no one breaks into databases to 
steal stored procedure source code...



Re: [firebird-support] Firebird 3: Not able to UPDATE RDB$Procedures

2018-05-31 Thread blackfalconsoftw...@outlook.com [firebird-support]
My thoughts exactly...  
 

 Even with scripting out all the database objects before the sources are 
deleted, sorting through them on large database can become a timely effort if 
you need to recompile only a few.
 

 Besides, who breaks into a database to steal stored procedure code???  And if 
you can disassemble the BLR to get the original code, the crooks can also..



Re: [firebird-support] Firebird 3: Not able to UPDATE RDB$Procedures

2018-05-31 Thread Mark Rotteveel m...@lawinegevaar.nl [firebird-support]
On 2018-05-31 17:51, Chuck Belanger phytot...@lanset.com 
[firebird-support] wrote:
> Hello:
> 
> Per googling and Carlos Cantu's FB3 Migration Guide (page: 110), we are
> still allowed to set RDB$PROCEDURE_SOURCE = null, and yet when trying 
> to
> do just that on my app's converted FB2.5 to FB3 database, I am getting
> "update not allowed on Systems tables." ISC ERROR CODE 335545030
> 
> I noticed a mention that at some point there will be another option to
> blank out this metadata information, but more likely in FB4.
> 
> To make this issue more interesting, from within IB_Expert, I can do an
> update of the RDB$Procedures table on one converted DB, but not on the
> working DB. As far as I can tell the tables and DB are essentially the 
> same.
> 
> Does anyone know what is going on here? Is there another way to blank
> out the Procedure source code?

What is the full Firebird version used, and exactly what was the 
statement used?

As an aside, deleting those sources may make it harder to find out 
exactly what the stored procedure etc does, but a determined person can 
still reverse engineer it from the BLR. You should ask yourself if you 
should go through the trouble of deleting, and why.

Mark


Re: [firebird-support] Re: Firebird 3: Not able to UPDATE RDB$Procedures

2018-05-31 Thread Mark Rotteveel m...@lawinegevaar.nl [firebird-support]
On 2018-05-31 18:14, blackfalconsoftw...@outlook.com [firebird-support] 
wrote:
> I just finished a complete review of Carlos' migration guide.  I read
> it quite carefully but completely missed what appears to be a
> contradiction in his explanations for the updating of the source-code
> fields in the system tables.  See the following extract below...
> 
 
> With the expansion of SQL DDL statements in Firebird 3, virtually all
> operations that could be done only through direct changes to the
> system tables can now be done in "official" ways, via SQL DDL.
> The only exceptions are the fields that store the source code of
> procedures and triggers, located in the RDB$PROCEDURES and
> RDB$TRIGGERS tables, respectively.
> 
> Application developers often want to hide the human readable version
> of their procedures and triggers to protect their intellectual
> property.SQL DDL offers no way to delete or hide that sourc e code. As
> an accommodation to that business need, Firebird 3 allows you to
> manipulate those two fields.
> <<<
> 
> On the one hand Carlos is saying you can alter such fields with SQL
> DDL statements and on the other he is saying you can't; then goes on
> to provide SQL code that does just that.  This explanation is somewhat
> confusing to say the least.
> 
> However, maybe Firebird 3.x.x does NOT allow this as Carlos' manual
> suggests...

There is no contradiction. Firebird 3 no longer allows direct 
manipulation of the system tables, but nulling the source columns of 
procedures (and triggers and views) is explicitly allowed for the time 
being. IIRC, there was discussion whether deleting sources should be 
allowed at all, and if so in what form. So until a decision was reached, 
the old 'feature' of direct manipulation of specifically those columns 
is retained (although discouraged).

Mark


[firebird-support] How to detect the source of a "firebird terminated abnormally (-1)" error?

2018-05-31 Thread Gabor Boros mlngl...@bgss.hu [firebird-support]
Hi All,

I found some "firebird terminated abnormally (-1)" errors in 
firebird.log on my development machine.  How can I detect it's source? 
My tip is a self made UDF (no input parameter, one TIMESTAMP output and 
written with Free Pascal). Can I stress test the UDF/problem somehow? (I 
know the problem only from the log and use 3.0.3 SuperServer and Linux 
64bit.)

Gabor






++

Visit http://www.firebirdsql.org and click the Documentation item
on the main (top) menu.  Try FAQ and other links from the left-side menu there.

Also search the knowledgebases at http://www.ibphoenix.com/resources/documents/ 

++


Yahoo Groups Links

<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/firebird-support/

<*> Your email settings:
Individual Email | Traditional

<*> To change settings online go to:
http://groups.yahoo.com/group/firebird-support/join
(Yahoo! ID required)

<*> To change settings via email:
firebird-support-dig...@yahoogroups.com 
firebird-support-fullfeatu...@yahoogroups.com

<*> To unsubscribe from this group, send an email to:
firebird-support-unsubscr...@yahoogroups.com

<*> Your use of Yahoo Groups is subject to:
https://info.yahoo.com/legal/us/yahoo/utos/terms/



Re: [firebird-support] Re: Firebird 3: Not able to UPDATE RDB$Procedures

2018-05-31 Thread Dimitry Sibiryakov s...@ibphoenix.com [firebird-support]
31.05.2018 18:14, blackfalconsoftw...@outlook.com [firebird-support] wrote:
> However, maybe Firebird 3.x.x does NOT allow this as Carlos' manual 
> suggests...

   I've just trued:

SQL> show version;
Server version:
Firebird/Windows/Intel/i386 (access method), version "WI-V3.0.2.32703 Firebird 
3.0"
on disk structure version 12.0
SQL> create procedure aa as begin /* */ end;
SQL> select rdb$procedure_source from rdb$procedures where 
rdb$procedure_name='AA';

RDB$PROCEDURE_SOURCE

   1a:1e0
==
RDB$PROCEDURE_SOURCE:
begin /* */ end
==

SQL> update rdb$procedures set rdb$procedure_source=null where 
rdb$procedure_name='AA';
SQL> commit;
SQL> select rdb$procedure_source from rdb$procedures where 
rdb$procedure_name='AA';

RDB$PROCEDURE_SOURCE

   


-- 
   WBR, SD.






++

Visit http://www.firebirdsql.org and click the Documentation item
on the main (top) menu.  Try FAQ and other links from the left-side menu there.

Also search the knowledgebases at http://www.ibphoenix.com/resources/documents/ 

++


Yahoo Groups Links

<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/firebird-support/

<*> Your email settings:
Individual Email | Traditional

<*> To change settings online go to:
http://groups.yahoo.com/group/firebird-support/join
(Yahoo! ID required)

<*> To change settings via email:
firebird-support-dig...@yahoogroups.com 
firebird-support-fullfeatu...@yahoogroups.com

<*> To unsubscribe from this group, send an email to:
firebird-support-unsubscr...@yahoogroups.com

<*> Your use of Yahoo Groups is subject to:
https://info.yahoo.com/legal/us/yahoo/utos/terms/



Re: [firebird-support] Re: Firebird 3: Not able to UPDATE RDB$Procedures

2018-05-31 Thread Chuck Belanger phytot...@lanset.com [firebird-support]

Thank you. However, I am not clear at all about how to do this with SQL DDL.

Also, apparently, this is not a blanket restriction, since I can 
successfully run the UPDATE RDB$PROCEDURES on at least 1 other converted 
DB (that is essentially the same as the DB I cannot run this UPDATE on).


Chuck


On 5/31/2018 9:14 AM, blackfalconsoftw...@outlook.com [firebird-support] 
wrote:



I just finished a complete review of Carlos' migration guide.  I read 
it quite carefully but completely missed what appears to be a 
contradiction in his explanations for the updating of the source-code 
fields in the system tables.  See the following extract below...


>>>
With the expansion of SQL DDL statements in Firebird 3, virtually all 
operations that could be done only through direct changes to the 
system tables can now be done in "official" ways, via SQL DDL.
The only exceptions are the fields that store the source code of 
procedures and triggers, located in the RDB$PROCEDURES and 
RDB$TRIGGERS tables, respectively.


Application developers often want to hide the human readable version 
of their procedures and triggers to protect their intellectual 
property.SQL DDL offers no way to delete or hide th at source code. As 
an accommodation to that business need, Firebird 3 allows you to 
manipulate those two fields.

<<<

On the one hand Carlos is saying you can alter such fields with SQL 
DDL statements and on the other he is saying you can't; then goes on 
to provide SQL code that does just that.  This explanation is somewhat 
confusing to say the least.


However, maybe Firebird 3.x.x does NOT allow this as Carlos' manual 
suggests...


Steve Naidamast
http://www.blackfalconsoftware.com









---
This email has been checked for viruses by Avast antivirus software.
https://www.avast.com/antivirus


[firebird-support] Firebird 3: Not able to UPDATE RDB$Procedures

2018-05-31 Thread Chuck Belanger phytot...@lanset.com [firebird-support]
Hello:

Per googling and Carlos Cantu's FB3 Migration Guide (page: 110), we are 
still allowed to set RDB$PROCEDURE_SOURCE = null, and yet when trying to 
do just that on my app's converted FB2.5 to FB3 database, I am getting 
"update not allowed on Systems tables." ISC ERROR CODE 335545030

I noticed a mention that at some point there will be another option to 
blank out this metadata information, but more likely in FB4.

To make this issue more interesting, from within IB_Expert, I can do an 
update of the RDB$Procedures table on one converted DB, but not on the 
working DB. As far as I can tell the tables and DB are essentially the same.

Does anyone know what is going on here? Is there another way to blank 
out the Procedure source code?

Thank you!

Chuck Belanger


---
This email has been checked for viruses by Avast antivirus software.
https://www.avast.com/antivirus



[firebird-support] Firebird::UtilInterfacePtr()->getPerfCounters

2018-05-31 Thread Norbert Saint Georges n...@tetrasys.eu [firebird-support]
Hello,

I only found that in isql.epp

const char* ISQL_COUNTERS_SET = "CurrentMemory, MaxMemory, RealTime, 
UserTime, Buffers, Reads, Writes, Fetches";

what are the other possibilities or where can I find them?

-- 
Norbert Saint Georges
http://tetrasys.fi







++

Visit http://www.firebirdsql.org and click the Documentation item
on the main (top) menu.  Try FAQ and other links from the left-side menu there.

Also search the knowledgebases at http://www.ibphoenix.com/resources/documents/ 

++


Yahoo Groups Links

<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/firebird-support/

<*> Your email settings:
Individual Email | Traditional

<*> To change settings online go to:
http://groups.yahoo.com/group/firebird-support/join
(Yahoo! ID required)

<*> To change settings via email:
firebird-support-dig...@yahoogroups.com 
firebird-support-fullfeatu...@yahoogroups.com

<*> To unsubscribe from this group, send an email to:
firebird-support-unsubscr...@yahoogroups.com

<*> Your use of Yahoo Groups is subject to:
https://info.yahoo.com/legal/us/yahoo/utos/terms/



Re: [firebird-support] Error creating Foreign key

2018-05-31 Thread Mourad Hedfi mou...@bilog.fr [firebird-support]
Hello,

Thanks for your reply.

1. Why do you remove all FK?
--> Data update covers all data's tables. I must remove all FK to be able
to insert, delete records.


2. Why do you still use such old Firebird version?
--> You are wright. It's a big client database and I mist have it's
agreement to use a recent version.


Many things was fixed since FB1.5 and i suppose that only real fix to your
problem is using recent FB.

You can try disconnect after every FK.

--> I'll try this and tell you if it resolve the problem. Note that on 477
deleted FK, 326 are created.


You can also try do select count(*) from updated tables but you say that
you do backup and restore...



Bien cordialement.

*Mourad **Hedfi*
Directeur de projets
Tél. : 01 83 62 36 85

2018-05-31 8:42 GMT+01:00 liviuslivius liviusliv...@poczta.onet.pl
[firebird-support] :

>
>
> Hi,
>
> Two questions
> 1. Why do you remove all FK?
> 2. Why do you still use such old Firebird version?
>
> Many things was fixed since FB1.5 and i suppose that only real fix to your
> problem is using recent FB.
>
> You can try disconnect after every FK.
> You can also try do select count(*) from updated tables but you say that
> you do backup and restore...
>
>
>
> Regards,
> Karol Bieniaszewski
>
> 
>


Re: [firebird-support] Error creating Foreign key

2018-05-31 Thread liviuslivius liviusliv...@poczta.onet.pl [firebird-support]
Hi,
Two questions 1. Why do you remove all FK?2. Why do you still use such old 
Firebird version?
Many things was fixed since FB1.5 and i suppose that only real fix to your 
problem is using recent FB.
You can try disconnect after every FK.You can also try do select count(*) from 
updated tables but you say that you do backup and restore...


Regards,Karol Bieniaszewski
null

[firebird-support] Error creating Foreign key

2018-05-31 Thread Mourad Hedfi mou...@bilog.fr [firebird-support]
Hello everybody,

I've an application witch update a database data.

The process to update data is :

   1. Delete all foreign keys
   2. Execute all update commands (insert, update, delete)
   3. Create  foreign keys

The problem is that foreign key creation return an error for some FK (50
from 477).

"-607-This operation is not defined for system tables."
"Table is in use."

It's a strange error because I've only one connection to the database in
the application and database is not opened in any other editor.

I've tried the following solutions :

   - In the application, before creating FK, I close the database connecion
   and I reopen it
   - I've backuped and restored the database

but always the same error.

I'm on Firebird 1.5 on Windows.

Can anyone tell me what's wrong and how to fix this problem


​Best regards.