AW: [firebird-support] Index

2015-03-03 Thread 'checkmail' check_m...@satron.de [firebird-support]
Thank you set :)

 

Von: firebird-support@yahoogroups.com
[mailto:firebird-support@yahoogroups.com] 
Gesendet: Dienstag, 3. März 2015 10:07
An: firebird-support@yahoogroups.com
Betreff: RE: [firebird-support] Index

 

  

Hello everybody,

I'm looking in a table for an existing record bevore I insert it. Now I
would set some indices. There are 4 fields I compare. 
It is better I create one index with all 4 fields or for every field one?

Difficult question with several potential answers.

Generally, one combined index is a bit faster. So, if this is the only query
with any of these four fields in the WHERE or JOIN clause OR the fields have
lousy selectivity by themselves OR this is the one query where performance
is vital, then go for the combined index.

However, there are a few benefits from using single field indexes. 

-It is easy to understand which fields are used for a particular PLAN (hence
easier to optimize)
-It is easy to see whether you should consider adding new indexes
-Each index can be used in more scenarios (the first field of a multifield
index can be used for all queries with this field, the following fields only
if the first field is compared for equality by the query)

Generally, I find it simpler to generally have single field indexes and only
rarely use combined indexes myself.

So, I'm sorry to say there's no general answer for your question and that
you have to consider for yourself what is most important in your particular
case.

now I have insert an index for the first both fields, the ibexpert analysis
shows me non indexed reads, why? 

I don't know, sorry...

The stored procedure also looking for two other fields.
SELECT 1 FROM rdb$database WHERE EXISTS(SELECT * FROM t_errordata WHERE
kd_id = :t_timestamp
 and li_id = :i_li and ftyp = :i_ftyp and ((fnr = :i_fnr) and (fnr =
:i_fnr + (:fanzds-1 INTO :idexists;

kd_id and li_id now indexed (in one index) ftyp and fnr not. The analysis
said there are 1 indexed read, 
bevore I inserted the index there are thousends non indexed.

I assume kd_id or li_id are fairly selective. My guess is that without any
index, Firebird had to scan through thousands of pages before it found one
that matched your criteria, with the index, Firebird can go straight to the
correct kd_id and li_id and then the first matches with respect to i_fnr.

HTH,
Set





AW: [firebird-support] Index

2015-03-03 Thread 'checkmail' check_m...@satron.de [firebird-support]
Thank you :)

 

Von: firebird-support@yahoogroups.com [mailto:firebird-support@yahoogroups.com] 
Gesendet: Dienstag, 3. März 2015 09:35
An: firebird-support@yahoogroups.com
Betreff: Re: [firebird-support] Index

 

  

Hello Olaf,

 

A combined index, with the field that has the largest number of different 
values as the first indexed field.

 

With regards,

Martijn Tonies
Upscene Productions
 http://www.upscene.com http://www.upscene.com

Download Database Workbench for Oracle, MS SQL Server, Sybase SQL
Anywhere, MySQL, InterBase, NexusDB and Firebird!

 

 

From: mailto:firebird-support@yahoogroups.com 

Sent: Tuesday, March 03, 2015 9:29 AM

To: firebird-support@yahoogroups.com mailto:firebird-support@yahoogroups.com  

Subject: [firebird-support] Index

 






Hello everybody,

 

I’m looking in a table for an existing record bevore I insert it. Now I would 
set some indices. There are 4 fields I compare… It is better I create one index 
with all 4 fields or for every field one?

 

Thank your

Olaf

 

 





Re: [firebird-support] Re: error messages: client shows only templates

2015-03-03 Thread Wolfgang Rohdewald wolfgang....@rohdewald.de [firebird-support]
Am Dienstag, 3. März 2015, 20:26:50 schrieb i...@obmsoftware.com 
[firebird-support]:
 I have faced such error message as well, and what I found out is that I have
 multiple GDS32.DLL located in my computer.  I think somehow during my 
 uninstallation
 of previous version of FireBird, it didn't get removed.   

Thanks, that was it!

In my case I forgot to copy the latest fbclient.dll over the single existing
gds32.dll

-- 
Wolfgang


Re: [firebird-support] Firebird SQL Classic-Server 2.5.3 in OSX 10.10.2

2015-03-03 Thread René Colombe firebirdsql-l...@colombe.biz [firebird-support]
hi paul,

thank your for help.

bevore my question i have changed the /etc/service file to this:

gds_db  5143/udp# gds_db (buhl)
gds_db  5143/tcp# gds_db (buhl)

(without „/„ like the other entrys in this file)

since this, firebird has stpped/started many times (reloading,reboot)
but firebird seems to ignore the etc/service file on my system. (?)

any other suggestions for osx 10.10. ?

regards
rené

Am 03.03.2015 um 11:47 schrieb 'Paul Beach' pabe...@waitrose.com 
[firebird-support] firebird-support@yahoogroups.com:

 The following will work.
 
 cd /etc
 
 vi services
 change
 
 gds_db 3051/udp
 gds_db 3051/tcp
 
 for example.
 
 cd /Library/LaunchDaemons
 
 launchctl unload org.firebird.gds.plist
 launchctl load org.firebird.gds.plist
 
 isqlconnect 'localhost:/Users/whome/databases/test.fdb' user 'whoever' 
 password 'whatever';
 
 in another terminal window:
 
 lsof -i:3051
 
 Regards
 Paul
 
  I am using firebird sql classic-server 2.5.3 under mac osx 10.10.2
  How can i change the remote-service-port (standard is 3050) to another one?
 
 
  i know, in windows and linux this setting is managed by an entry in 
  „firebird.conf
 
 
  in osx there is also a „firebird.conf in 
  /Library/Frameworks/Firebird.framework/A/Resources/English-lproj/var/
  but changes in this file:
  RemoteServiceName = gds_db
  RemoteServicePort = 5143
  have no result in firebird. the port is the same as before (3050)
 
 
  i have read the readme-file (firebird.conf.txt) in 
  /Library/Frameworks/Firebird.framework/A/Resources/doc
  But i only found this in „Darwin“ section:
 
 
  Darwin on the other hand first checks the environment variable FIREBIRD.
  If not found, it [... John, please describe the „bundle stuff here].
  As a last resort it too falls back to /usr/local/firebird“.“
 
 
  It seems that this section is not complete written by the author.
  I have searched in internet many times for help but i have not found a 
  answer for this „problem“.
  (with the right knowledege not really a problem)
 
 
  in osx i have found two other files they are maybe used for configuring 
  firebird.
  „org.firebird.gdl.plist and StartupParameters.plist
  but both file has other syntax so i cant adopt the settigs from 
  firebird.conf to this files.
 
 
  these files are:
  /Library/Frameworks/Firebird.framework/A/Resources/FirebirdSS/StartupParameters.plist
 
 
  {
  Description = Firebird SQL Database server;
  Provides = (Firebird Server);
  Requires = (DirectoryServices);
  Uses = (Disks, NFS);
  OrderPreference = None;
  }
 
 
  and:
  /Library/LaunchDeamons/org.firebird.gdl.plist
 
 
  ?xml version=1.0 encoding=UTF-8?
  !DOCTYPE plist PUBLIC -//Apple//DTD PLIST 1.0//EN 
  http://www.apple.com/DTDs/PropertyList-1.0.dtd;
  plist version=1.0
  dict
  keyDisabled/key
  false/
  keyEnvironmentVariables/key
  dict
  keyPATH/key
 
  string/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Applications/Server.app/Contents/ServerRoot/usr/bin:/Applications/Se
  rver.app/Contents/ServerRoot/usr/sbin:/usr/local/sbin/string
  /dict
  keyInetdCompatibility/key
  dict
  keyWait/key
  false/
  /dict
  keyInitGroups/key
  true/
  keyLabel/key
  stringorg.firebird.gds/string
  keyOnDemand/key
  true/
  keyProgramArguments/key
  array
  string/Library/Frameworks/Firebird.framework/Resources/bin/fb_inet_server/string
  /array
  keySockets/key
  dict
  keyListeners/key
  dict
  keySockFamily/key
  stringIPv4/string
  keySockServiceName/key
  stringgds_db/string
  keySockType/key
  stringstream/string
  /dict
  /dict
  keyUserName/key
  stringfirebird/string
  /dict
  /plist
 
 
  How can i configure the remote-service-port (standard is 3050) to another 
  one?
 
 
  Thank You
  Regards
 
 
  René
 
 
  [colombe] computer und medien
 
 
  E-Mail: i...@colombe.biz
  Tel.: 030 868 70 48 89
  mobil: 0179 249 48 89
  www.colombe.biz
 
 
 
 
 
 
 
 
  
  Posted by: =?windows-1252?Q?Ren=E9_Colombe?= firebirdsql-l...@colombe.biz
  
 
  ++
 
  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
 
 
 
 
 
 



Re: [firebird-support] Firebird SQL Classic-Server 2.5.3 in OSX 10.10.2

2015-03-03 Thread Helen Borrie hele...@iinet.net.au [firebird-support]
At 01:38 p.m. 4/03/2015, you wrote:
bevore my question i have changed the /etc/service file to this:

gds_db  5143/udp# gds_db (buhl)
gds_db  5143/tcp# gds_db (buhl)

(without „/„ like the other entrys in this file)

since this, firebird has stpped/started many times (reloading,reboot)
but firebird seems to ignore the etc/service file on my system. (?)

any other suggestions for osx 10.10. ?

Editing the services file does not open ports in the firewall.  Have you 
checked whether port 5143 is open in the firewall?

Next, have you tried setting the port in firebird.conf:

# TCP Protocol Settings
#
# The TCP Service name/Port number to be used for client database
# connections.
#
# It is only necessary to change one of the entries, not both.  The
# order of precedence is the 'RemoteServiceName' (if an entry is
# found in the 'services.' file) then the 'RemoteServicePort'.
#
# Type: string, integer
#
#RemoteServiceName = gds_db
#RemoteServicePort = 3050

The commented settings are the Firebird defaults.  You can try to override them 
by deleting the comment marker # on RemoteServicePort and setting the new port:

#RemoteServiceName = gds_db
RemoteServicePort = 5143

After saving the changes in firebird.conf, don't forget to 
1) open the new port in the firewall and 
2) shut down and restart any  fb-inet_server processes. 

I'm not sure, but you might have to restart xinetd before step 2), as well.  I 
don't have access to an OSX box to test that.


Helen Borrie, Support Consultant, IBPhoenix (Pacific)
Author of The Firebird Book and The Firebird Book Second Edition
http://www.firebird-books.net
__ 



[firebird-support] Re: error messages: client shows only templates

2015-03-03 Thread i...@obmsoftware.com [firebird-support]
I have faced such error message as well, and what I found out is that I have 
multiple GDS32.DLL located in my computer.  I think somehow during my 
uninstallation of previous version of FireBird, it didn't get removed.   

 After I remove all outdated GDS32.DLL like those dated in year 2007, and 
remain the latest one, my system does not prompt such error already but 
prompting more meaningful messages.