Re: Porting MSSQL to PGSQL (Was: [OT] MySQL is bad, but THIS bad?) - Mailing list pgsql-hackers

From Josh Berkus
Subject Re: Porting MSSQL to PGSQL (Was: [OT] MySQL is bad, but THIS bad?)
Date
Msg-id 200605211458.17146.josh@agliodbs.com
Whole thread Raw
In response to Porting MSSQL to PGSQL (Was: [OT] MySQL is bad, but THIS bad?)  (Mischa Sandberg <mischa@ca.sophos.com>)
Responses Re: Porting MSSQL to PGSQL (Was: [OT] MySQL is bad, but THIS bad?)
List pgsql-hackers
Mischa,

> Somebody earlier was mentioning, why no automatic transformer from
> Transact-SQL to PLPGSQL (maybe with a bunch of glue routines). The grammar
> is not a problem, though you have to wonder at all the wired-in keywords
> (T-SQL always felt like COBOL).

Actually, porting TSQL to PL/pgSQL would be very hard.   I speak as an expert 
TSQL developer.  For example, most data manipulation in TSQL is done through 
updatable cursors, something we don't currently support.  Also, T-SQL uses 
un-ordered, callable parameters for SPs, something which we *also* don't 
support.

> Other issues: stored procs returning multiple result sets; "print"
> statements; SELECT TOP n PERCENT; COMPUTE-expressions (subtotals); and some
> of the @@global variables that are hard to emulate @@IDENTITY being the
> main problem in older T-SQL code.

Yeah, but @@IDENTITY sucks.  Most MSSQL developers are glad to leave it 
behind.  ;-)

-- 
Josh Berkus
PostgreSQL @ Sun
San Francisco


pgsql-hackers by date:

Previous
From: Volkan YAZICI
Date:
Subject: Re: problem with PQsendQuery/PQgetResult and COPY FROM statement
Next
From: Tom Lane
Date:
Subject: Re: problem with PQsendQuery/PQgetResult and COPY FROM statement