Re: [AOLSERVER] The quality of our community (was Re: [AOLSERVER] Retrieving oid from INSERT)

2006-04-10 Thread Mark Aufflick
Firstly I would like to second Dossy on the quality of the aolserver community. In addition I would like to say that one of the biggest reasons why the aolserver community has life in 2006 and is of such a high calibre is because of Dossy himself. I also want to say that I was joking in the

[AOLSERVER] Databases (was : The quality of our community (was Re: [AOLSERVER] Retrieving oid from INSERT))

2006-04-10 Thread Bas Scheffers
Mark Aufflick said: I also want to say that I was joking in the comment quoted below. Weak technology (especially expensive weak technology) gets me a little hot under the collar sometimes but I don't think there was any real In that regards, IBM to me has always been a shocking example with

Re: [AOLSERVER] Databases (was : The quality of our community (was Re: [AOLSERVER] Retrieving oid from INSERT))

2006-04-10 Thread Bas Scheffers
Mat Kovach said: I see many large scale sites that run UDB/DB2. I know of at least three sites that have, easily, 1000 UDB instances running. I lot of people What kind of sites are they? What industries? Cheers, Bas. -- AOLserver - http://www.aolserver.com/ To Remove yourself from this

Re: [AOLSERVER] Databases (was : The quality of our community (was Re: [AOLSERVER] Retrieving oid from INSERT))

2006-04-10 Thread Steve Manning
On Mon, 2006-04-10 at 13:47 +0100, Bas Scheffers wrote: Who uses DB2? Is it any good, or much like IBM's other software? Just about every IBM midrange system comes with DB2. There are an awful lot of AS/400 or iSeries out there and there were a lot of System/36 and System/38's as well.

Re: [AOLSERVER] Databases (was : The quality of our community (was Re: [AOLSERVER] Retrieving oid from INSERT))

2006-04-10 Thread Mat Kovach
Bas Scheffers wrote: Mat Kovach said: I see many large scale sites that run UDB/DB2. I know of at least three sites that have, easily, 1000 UDB instances running. I lot of people What kind of sites are they? What industries? Large data centers, mainly for finance and logistics companies.

Re: [AOLSERVER] Databases (was : The quality of our community (was Re: [AOLSERVER] Retrieving oid from INSERT))

2006-04-10 Thread Joe Kondel
I've seen it in the wild in financial institutions (mainly banks) running on as/400 or iSeries boxes. Most would then use products like datamirror to migrate it out of db2 and into sql server, etc.. to run their reporting packages against. best, Joe Kondel On Apr 10, 2006, at 10:33 AM, Mat

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-07 Thread Dossy Shiobara
On 2006.04.07, Mark Aufflick [EMAIL PROTECTED] wrote: Although that's not a dissimilar problem to the NULL as empty string issue in the Oracle C libraries (which really really bites). Um, where are you getting this information from? Oracle's OCI libraries definitely expose whether a column

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-07 Thread Bas Scheffers
Mark Aufflick said: I feel a good old fashioned usenet style flame war coming on =) Slashdot has flame wars, all we have are friendly argument with as outcome learning more about our favourite and other products. In Sybase, NULL matches NULL in a search clause (by default - as Yes. I personaly

[AOLSERVER] The quality of our community (was Re: [AOLSERVER] Retrieving oid from INSERT)

2006-04-07 Thread Dossy Shiobara
On 2006.04.07, Bas Scheffers [EMAIL PROTECTED] wrote: Mark Aufflick said: I feel a good old fashioned usenet style flame war coming on =) Slashdot has flame wars, all we have are friendly argument with as outcome learning more about our favourite and other products. I actually wanted to

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-06 Thread Mark Aufflick
Most of the web world runs on MySQL and does ok - just like CDBaby who You can't possibly liken Sybase to MySQL! I know that they are not even in the same league technically, but they do show disturbingly similar philosophies - like making NULL = NULL by default because many clients with

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-06 Thread Mark Aufflick
That's great - I'm a bit of a Sybase newby and this tip makes life a lot easier. Given that this is so easy and reasonable I don't understand why so many Sybase developers employ other unreliable methods to emulate triggers. On 4/5/06, Bas Scheffers [EMAIL PROTECTED] wrote: select @@identity

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-06 Thread Bas Scheffers
Mark Aufflick said: do show disturbingly similar philosophies - like making NULL = NULL by default because many clients with poorly trained developers asked for I recon that's the only one! (and I still don't see why this is such a bad thing) My problem with MySQL isn't this simplification, it's

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-06 Thread Dossy Shiobara
On 2006.04.06, Mark Aufflick [EMAIL PROTECTED] wrote: That's great - I'm a bit of a Sybase newby and this tip makes life a lot easier. Given that this is so easy and reasonable I don't understand why so many Sybase developers employ other unreliable methods to emulate triggers. For the

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-06 Thread Bas Scheffers
Dossy Shiobara said: You're right; MySQL is orders of magnitude better than Sybase. I'm dead Yeah, when it doesn't blow up in weird and wonderul ways... And you don't mind not being able to do online backups And if you think '-00-00' or '2006-02-30' is a date... (oh no, just tested mysql

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-06 Thread Dossy Shiobara
On 2006.04.06, Bas Scheffers [EMAIL PROTECTED] wrote: Dossy Shiobara said: You're right; MySQL is orders of magnitude better than Sybase. I'm dead Yeah, when it doesn't blow up in weird and wonderul ways... [...] I'll bet a nickel it's user error (whether that user is a developer or the

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-06 Thread Tom Jackson
It sounds like you guys are comparing rotten oranges and rotten apples. tom jackson On Thursday 06 April 2006 05:37, Bas Scheffers wrote: Dossy Shiobara said: You're right; MySQL is orders of magnitude better than Sybase. I'm dead Yeah, when it doesn't blow up in weird and wonderul ways...

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-06 Thread Bas Scheffers
Tom Jackson said: It sounds like you guys are comparing rotten oranges and rotten apples. Are there any apples that aren't considered rotten by someone, somewhere? Like I said before, every RDBMS has it's issues... ...MySQL just takes them to a whole new level and gets even otherwise sensible

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-06 Thread Bas Scheffers
Dossy Shiobara said: Oh man, who is feeding you this pack of lies? I mean, MySQL has been able to do hot online backups since May 2002! Well, you've been able to How? All I can find is this mysqldump and mysqlhotcopy, which lock tables while they are being dumped. Hardly online backup if you

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-06 Thread Dossy Shiobara
On 2006.04.06, Bas Scheffers [EMAIL PROTECTED] wrote: The difference? If I *had* to, I could extend MySQL to do exactly what I need. (Beware: Tcl as a supported UDF language for MySQL stored procs! Muwahaha.) Why waste your time, Postgres already has that! :) (and loads of other

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-06 Thread Bas Scheffers
On 6 Apr 2006, at 17:42, Dossy Shiobara wrote: Can you embed Postgres? Before I got turned on to SQLite, MySQL served I don't see that as a downside, it's not what I use it for. Like you say, there's SQLite for that. Try embedding MySQL into a non-GPL project and see how free it is then!

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-06 Thread dhogaza
On 2006.04.06, Bas Scheffers [EMAIL PROTECTED] wrote: As much as people criticize MySQL's replication and clustering, where's Postgres's? I don't see any mention of it in Postgres 8.1 docs: http://www.postgresql.org/docs/8.1/interactive/index.html That's because replication isn't part

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-06 Thread Bas Scheffers
On 6 Apr 2006, at 19:13, dhogaza@PACIFIER.COM wrote: The people who wrote MySQL have the ethical standards of the George W. Bush administration. What, it's made by the same folks as those behind JBoss!? ;-) Bas. -- AOLserver - http://www.aolserver.com/ To Remove yourself from this list,

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-06 Thread Mark Aufflick
On 4/6/06, Dossy Shiobara [EMAIL PROTECTED] wrote: Did you know that Sybase silently promotes an empty string to a string of 1 character? You can't actually store an empty string in a Sybase database. That is absolutely ridiculous. I'd expect that kind of behavior from some college-level

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-06 Thread Mark Aufflick
On 4/6/06, Bas Scheffers [EMAIL PROTECTED] wrote: Mark Aufflick said: do show disturbingly similar philosophies - like making NULL = NULL by default because many clients with poorly trained developers asked for I recon that's the only one! (and I still don't see why this is such a bad

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-06 Thread Mark Aufflick
On 4/7/06, Mark Aufflick [EMAIL PROTECTED] wrote: On 4/6/06, Dossy Shiobara [EMAIL PROTECTED] wrote: Did you know that Sybase silently promotes an empty string to a string of 1 character? You can't actually store an empty string in a Sybase database. That is absolutely ridiculous. I'd

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-05 Thread Bas Scheffers
select @@identity for the last identity value assigned in the current session. This is acros all tables with id columns, so if you are inserting multiple in one transaction and need all of them, be sure to assign them to another variable after each insert. Cheers, Bas. On 5 Apr 2006, at

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-05 Thread Olaf Mersmann
Hi Mark, * Mark Aufflick [EMAIL PROTECTED] [060405 06:31]: Sybase, like SQLlite, does (now) support an auto-incrementing column type, but AFAICT there is no way to find out which id you just inserted. Sybase provides the @@identity variable which holds the last

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-05 Thread Bas Scheffers
Mark Aufflick said: I have seen some large Sybase databases go down quite spectacularly. Any details on how or why? One common cause for downtime is filling up the log space and locking up the DB, not knowing how to fix it. But they should have read the manual! Most of the web world runs on

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-05 Thread Tom Jackson
Can't you write a function to do the insert and return the value of the oid? If you are contemplating adding a new query, seems like it would be just as easy to replace the insert statement with a function call. Another possibility is to grab a number of oids and cache them in your

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-04 Thread Bas Scheffers
Mark Aufflick said: Doesn't that still serialize all updates requiring access to that sequence? Sequences are used for inserts, not updates. Well, I haven't seen them being used in updates anyway. If you used it within a transaction it would also have implications with other transactions

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-04 Thread Andrew Piskorski
On Tue, Apr 04, 2006 at 03:02:21PM +1000, Mark Aufflick wrote: Doesn't that still serialize all updates requiring access to that sequence? No. Sequences in an RDBMS are designed to scale gracefully under heavy concurrent load. (This is basic stuff, grab any good intro. book on databases and

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-04 Thread Dossy Shiobara
On 2006.04.04, Bas Scheffers [EMAIL PROTECTED] wrote: All Systems have their merrits. As (commercial) enterprise database go, I have _much_ better experiences with Sybase than Oracle for ease of maintainance (best backups in the business), optimization (it just uses indexes that make sense

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-04 Thread Bas Scheffers
Andrew Piskorski said: No. Sequences in an RDBMS are designed to scale gracefully under heavy concurrent load. (This is basic stuff, grab any good I think Mark was talking about my Sybase solution (sequence table) for if you don't want to use identity columns. I think SQL Server and Sybase

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-04 Thread Bas Scheffers
Dossy Shiobara said: I just have to ask: what version of Sybase and Oracle are you comparing? 9i and 11.92, 12, 12.5. The worst Oracle instance was maintained by a couple of very good DBAs, at least according to the guy who actually worked for Oracle and did an audit of our system. They were

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-04 Thread Mark Aufflick
Hi Andrew, I might have missed the context in my reply - we were discussing Sybase which is one of those databases missing sequence support. We are a little off topic, but Bas was suggesting a reasonable way around the missing sequences (very reasonable compared with many other attempts to work

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-04 Thread Mark Aufflick
I've added so many 2c this thread is nearly tax deductable! .. I have never actually seen a Sybase instance go down or mess up my data. I have seen some large Sybase databases go down quite spectacularly. The whole financial world seems to run on Sybase, and so far it's been doing OK...

Re: [AOLSERVER] Retrieving oid from INSERT

2006-04-03 Thread Mark Aufflick
Doesn't that still serialize all updates requiring access to that sequence? If you used it within a transaction it would also have implications with other transactions using that sequence especially in a rollback situation. In the context of AOLServer you could minimise the impact of these

Re: [AOLSERVER] Retrieving oid from INSERT

2006-03-29 Thread Bas Scheffers
William Scott Jordan said: ns_db dml $db INSERT INTO test (test_column) SELECT COALESCE(MAX(test_column),0) + 1 FROM test Ehrm, that is a very, very bad way of creating keys. It is no unlikely that on a very loaded site two people might insert at the same time and get the same key! The correct

Re: [AOLSERVER] Retrieving oid from INSERT

2006-03-28 Thread Janine Sisk
The way we do this in OpenACS is to have a primary key in each table that is populated from a sequence. So in your code you get the next number from the sequence, do the insert (storing the number in the primary key column), and then you have that number already in your possession to use