[SQL] dynamic events categorization

2008-06-24 Thread Louis-David Mitterrand
Hello, I'm looking for a more efficient way of dynamically categorizing some events. The following view definition looks into each event's latest event_date object (a theater play can have several, a book only one) to tell whether the event is current, past or future: SELECT s.id_event_su

[SQL] ANSI Standard

2008-06-24 Thread Pascal Tufenkji
Hi, How do I know if a function (or a certain sql syntax) in Postgres is a SQL ANSI Standard, hence it works on all databases such as MySQL, SQL Server, Oracle. I noticed that concat, decode, nvl, instr are functions that work for some databases and don't for others. I only want to use ANS

[SQL] Verify Execute

2008-06-24 Thread Shavonne Marietta Wijesinghe
Hello Is there a way to find out if the EXECUTE of a UPDATE, INSERT has been completed successfully? Here is an example of what I do: Set conn = Server.CreateObject("ADODB.Connection") conn.Open "Form_Store_PSQL" Set oRs = Server.CreateObject("ADODB.Recordset" ) strSQL = "INSERT INTO TABLE_TEM

Re: [SQL] Verify Execute

2008-06-24 Thread Andreas Joseph Krogh
On Tuesday 24 June 2008 17:18:22 Shavonne Marietta Wijesinghe wrote: > Hello > > Is there a way to find out if the EXECUTE of a UPDATE, INSERT has been > completed successfully? > > Here is an example of what I do: > > Set conn = Server.CreateObject("ADODB.Connection") > conn.Open "Form_Store_P

[SQL] Sequential event query

2008-06-24 Thread Steve Crawford
I have a table that includes the following columns: event_time timestamptz device_id integer event_type integer ... There are hundreds of unique device_ids, about ten event_types and millions of records in the table. Devices can run the gamut from idle to fully utilized so for any given time-pe

Re: [SQL] ANSI Standard

2008-06-24 Thread Richard Broersma
On Tue, Jun 24, 2008 at 7:33 AM, Pascal Tufenkji <[EMAIL PROTECTED]> wrote: > How do I know if a function (or a certain sql syntax) in Postgres is a SQL > ANSI Standard, hence it works on all databases such as MySQL, SQL Server, > Oracle… > I noticed that concat, decode, nvl, instr are functions