select convert(varchar(255),getdate(),103)
You used date format 103 and that's what you got; so what's the problem?
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
I have a managed instance of SQLMI database . The database has been migrated from other RDBMS. The format of date in the RDBMS is mm/dd/yyyy . But when migrated to SQLMI the format is mm-dd-yyyy. The application need default data in the same format. i.e slash '/' instead of hyphen '-'. Will it be possible to change the default format to '/' so that data is stored in the same format and we don't have to use any convert function.
Is there any collation that support this format.
example:
select convert(varchar(255),getdate(),103) 'SLASH' ,getdate() 'HYPHEN'
SLASH HYPHEN
26/10/2023 2023-10-26
select convert(varchar(255),getdate(),103)
You used date format 103 and that's what you got; so what's the problem?