RE: [firebird-support] Order By Not Working Using "WITH" Clause

2015-07-03 Thread Svein Erling Tysvær svein.erling.tysv...@kreftregisteret.no [firebird-support]
>Hi All, > >I have below SQL, which is concatenating the ShortCode column data, but >without ordering as per the ORDER_NUMBER column in ABC table in "WITH" clause. > >Please help. > >With TBL_SHORT_CODE (SHORT_CODE, FK_KEY) As  >( >SELECT Distinct(XYZ.SHORT_CODE) As SHORT_CODE, ABC.FK_KEY  >From A

Re: [firebird-support] Changing Columns

2015-07-03 Thread Alan J Davies alan.dav...@aldis-systems.co.uk [firebird-support]
I tried this in a test database before replying. Changed a domain from 4 to 8 char. This is used by various tables as a PK and got this error message. I then changed other domains to check and had no problems (done this many times before but possibly not with a PK, can't remember) This operatio

Re: [firebird-support] Order By Not Working Using "WITH" Clause

2015-07-03 Thread 'Mark Rotteveel' m...@lawinegevaar.nl [firebird-support]
Ok, then there are also other grouping or sorting effects involved. Unfortunately there is no way to enforce a specific order. The CTE trick you use is just that: a trick and it doesn't always work. So until Firebird supports a list(... Order by...), there is no way to always get a deterministic

Re: [firebird-support] Order By Not Working Using "WITH" Clause

2015-07-03 Thread Vishal Tiwari vishuals...@yahoo.co.in [firebird-support]
Even if I don't use Distinct, i don't get expected result. On Friday, 3 July 2015 7:17 PM, "Mark Rotteveel m...@lawinegevaar.nl [firebird-support]" wrote:   On Fri, 3 Jul 2015 12:15:31 + (UTC), "Vishal Tiwari vishuals...@yahoo.co.in [firebird-support]" wrote: > Hi All, > I ha

Re: [firebird-support] Changing Columns

2015-07-03 Thread Ann Harrison aharri...@ibphoenix.com [firebird-support]
On Jul 3, 2015, at 8:09 AM, 'checkmail' check_m...@satron.de [firebird-support] wrote: > > I would like to change a primary column in my database from 8 to 16 > characters. Over 100 Tables are constrained, foreign key reference. Now I can > change the DDL from the Database and create this aga

RE: [firebird-support] Re: 450 active transactions after database restore, is it normal?

2015-07-03 Thread 'Leyne, Sean' s...@broadviewsoftware.com [firebird-support]
Dmitry, > 02.07.2015 19:36, 'Leyne, Sean' wrote: > > > >>> Oldest transaction1 > >>> Oldest active2 > >>> Oldest snapshot2 > >>> Next transaction492 > > > > Even it that switch was used, why would the transactions appear to active? > > They're not a

Re: [firebird-support] Order By Not Working Using "WITH" Clause

2015-07-03 Thread Mark Rotteveel m...@lawinegevaar.nl [firebird-support]
On Fri, 3 Jul 2015 12:15:31 + (UTC), "Vishal Tiwari vishuals...@yahoo.co.in [firebird-support]" wrote: > Hi All, > I have below SQL, which is concatenating the ShortCode column data, but > without ordering as per the ORDER_NUMBER column in ABC table in "WITH" > clause. > Please help. > > With

[firebird-support] Order By Not Working Using "WITH" Clause

2015-07-03 Thread Vishal Tiwari vishuals...@yahoo.co.in [firebird-support]
Hi All, I have below SQL, which is concatenating the ShortCode column data, but without ordering as per the ORDER_NUMBER column in ABC table in "WITH" clause. Please help. With TBL_SHORT_CODE (SHORT_CODE, FK_KEY) As (SELECT Distinct(XYZ.SHORT_CODE) As SHORT_CODE, ABC.FK_KEY From ABC Join XYZ On

[firebird-support] Changing Columns

2015-07-03 Thread 'checkmail' check_m...@satron.de [firebird-support]
Hello, I would like to change a primary column in my database from 8 to 16 characters. Over 100 Tables are constrained, foreign key reference. Now I can change the DDL from the Database and create this again, but I must import all Data-Tables. An other Option is the changing manually, delete al

RE: [firebird-support] replace a database in production

2015-07-03 Thread Svein Erling Tysvær svein.erling.tysv...@kreftregisteret.no [firebird-support]
>>i have a web app that use firebird embedded database hosted in the internet. >>and the same database in local used by a regular database 2.5 server >>I have to replace the web database with the local one (a kind of replication) >>the problem is that the database could be used at that moment so lo