AW: [firebird-support] Optimize query for date ranges

2015-10-12 Thread 'Parzival' parzival1...@gmx.at [firebird-support]
Hi, the execution is currently not the problem, because the number of records is too small. I have the impression that the first query looks for DATUM >= x and the second one for DATUM <= y and finally delivers the number of records that is included in both result sets. My main interesst is to

Re: [firebird-support] Optimize query for date ranges

2015-10-12 Thread Thomas Steinmaurer t...@iblogmanager.com [firebird-support]
Niko, > Hello all, > > i am running a simple query where the result contains 3 records. The > query should provide all records in a specific week. > > SELECT * FROM ARBEITSEINTEILUNG AS a where a.baustelle = '12345' AND > WOCHE = '2015-41'; > > Some times I dont have a week but two dates: > > In

[firebird-support] Re: basic cursor and firebird psql question

2015-10-12 Thread thirdshiftco...@yahoo.com [firebird-support]
Hi- I hope this doesn't double post. RDB$ denotes a system table. Stilll not sure where RNAME gets its value. thanks - jim

[firebird-support] basic cursor and firebird psql question

2015-10-12 Thread thirdshiftco...@yahoo.com [firebird-support]
Hi- I have 2 questions from the code below. Where do you come up with RDB$FIELD_NAME? Is FIELDNAME part THE NAME OF A FIELD IN an actual TABLE AND RELATION_FIELDS THE NAME OF A REAL TABLE? How can you use :RNAME IN THE WHERE clause? Where is it getting its value from? It seems like it

[firebird-support] Re: basic cursor and firebird psql question

2015-10-12 Thread thirdshiftco...@yahoo.com [firebird-support]
Hi- I since figured out part of it. RDB$ prefix denotes system tables. Okay, so I am still wondering where RNAME gets it values. thanks for any help. jim

Re: [firebird-support] basic cursor and firebird psql question

2015-10-12 Thread Helen Borrie hele...@iinet.net.au [firebird-support]
At 06:43 a.m. 13/10/2015, thirdshiftco...@yahoo.com [firebird-support] wrote: >I have 2 questions from the code below. > >Where do you come up with RDB$FIELD_NAME? It is a column in the system table RDB$RELATION_FIELDS. The RDB$-- tables exist in all Firebird databases. They store your