From: Joel Rabinovitch <Joel.Rabinovitch@tecsys.com>
To: pgsql-general@lists.postgresql.org <pgsql-general@lists.postgresql.org>
Subject: RE: Migrating PostgreSQL Stored Procedures to MSSQL 2019 for example
Date: Fri, 12 Aug 2022 12:07:15 +0000
Message-ID: <YT2PR01MB880520A654763B23954AEFC0E5679@YT2PR01MB8805.CANPRD01.PROD.OUTLOOK.COM> (raw)
In-Reply-To: <CWXP123MB4312354CC104C7E075F0393794679@CWXP123MB4312.GBRP123.PROD.OUTLOOK.COM>
References: <CWXP123MB4312354CC104C7E075F0393794679@CWXP123MB4312.GBRP123.PROD.OUTLOOK.COM>
Hi,
When we did our migration from SQL Server to PostgreSQL, we mainly used two tools:
sqlserver2pgsql for most of our schema-related changes. You can find that here: https://github.com/dalibo/sqlserver2pgsql.
AWS Schema Conversion Tool (SCT) for migrating views and stored functions/procedures. The AWS SCT also can do schema conversions. You can find that here: https://aws.amazon.com/dms/schema-conversion-tool/
For the AWS SCT tool, you don't really need to use AWS schemas. You can install PostgreSQL locally, and save the SQL files it generates and then apply them yourself. Not sure if that's a violation of their license terms though (our company does use AWS).
Keep in mind that these conversion tools do the majority of the work, but the output they generate needs to be reviewed. For example, columns with an isjson() constraint need to be converted to json or jsonb columns. Stored procedures/functions sometimes don't convert at all.
The following sites also provide the ability to conversion SQL statements using SQL Server-specific syntax to PostgreSQL.
https://www.jooq.org/translate/https://www.sqlines.com/onlinehttps://wiki.postgresql.org/wiki/Converting_from_other_Databases_to_PostgreSQL
Hope this helps,
Joel
From: Scott Simpson <Scott.Simpson@zellis.com>
Sent: Friday, August 12, 2022 6:17 AM
To: pgsql-general@lists.postgresql.org
Subject: Migrating PostgreSQL Stored Procedures to MSSQL 2019 for example
ATTENTION: This email originated from outside of Tecsys. Use caution when clicking links or opening attachments. | Ce courriel provient de l'extérieur de Tecsys. Soyez prudent lorsque vous cliquez sur des liens ou ouvrez des pièces jointes.
Hi,
I need to migrate many PostgreSQL Stored Procedures and functions to MSSQL.
I can find anything online that seems to handle this task.
Are there any tools that you have that can do this job?
Kind Regards
Zellis | Scott Simpson | Senior Engineer
[cid:image001.png@01D8AE1E.AC41B970]
Thorpe Park
United Kingdom
Work : +44 (0)20 3986 3523
Email : Scott.Simpson@Zellis.com<mailto:Daniel.Munns@Zellis.com>
Web : www.Zellis.com<https://can01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.zellis.com%2F&data=05%7C01%...;
________________________________
Zellis is the trading name for Zellis Holdings Ltd and its associated companies "Zellis".
The contents of this email are confidential to Zellis and are solely for the use of the intended recipient. If you received this email in error, please inform the sender immediately and delete the email from your system. Unless Zellis have given you express permission to do so, please do not disclose, distribute or copy the contents of this email.
Unless this email expressly states that it is a contractual offer or acceptance, it is not sent with the intention of creating a legal relationship and does not constitute an offer or acceptance which could give rise to a contract.
Any views expressed in this email are those of the individual sender unless the email specifically states them to be the views of Zellis.
Zellis Holdings Ltd - registered in England and Wales - Company No: 10975623 - Registered Office: 740 Waterside Drive, Aztec West, Almondsbury, Bristol, BS32 4UF, UK.
Attachments:image001.png (image/png, 4.7K) downloadview image
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-general@postgresql.org
Cc: Joel.Rabinovitch@tecsys.com
Subject: Re: Migrating PostgreSQL Stored Procedures to MSSQL 2019 for example
In-Reply-To: <YT2PR01MB880520A654763B23954AEFC0E5679@YT2PR01MB8805.CANPRD01.PROD.OUTLOOK.COM>
References: <CWXP123MB4312354CC104C7E075F0393794679@CWXP123MB4312.GBRP123.PROD.OUTLOOK.COM> <YT2PR01MB880520A654763B23954AEFC0E5679@YT2PR01MB8805.CANPRD01.PROD.OUTLOOK.COM>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox