sqlserver2pgsql
sqlserver2pgsql copied to clipboard
Incorrect parsing of default sysdatetime() function
Hi Team, If we have a date time type column with a default value ex:
ALTER TABLE [dbo].[AAFILE] ADD CONSTRAINT [DF_AAFILE_created_on] DEFAULT (sysdatetime()) FOR [created_on]
The function sysdatetime() gets parsed as is which is not supported by PG ex:
ALTER TABLE "public"."aafile" ALTER COLUMN "created_on" SET DEFAULT sysdatetime();
If we could convert it to now(), the PG equivalent, the error can be avoided.
Thank You for your help.