Best method in SQL Server 2016
Example:
SELECT FORMAT(GETDATE(), 'yyyy/MM/dd-HH:mm:ss', 'fa')
Answer:
1398/10/08-05:37:59
More Related Contents:
- SQL group_concat function in SQL Server [duplicate]
- Pivot Dynamic Columns, no Aggregation
- How to connect to local instance of SQL Server 2008 Express
- Export query result to .csv file in SQL Server 2008
- varchar(max) everywhere?
- T-SQL: Export to new Excel file
- Enable ‘xp_cmdshell’ SQL Server
- Sql Server ‘Saving changes is not permitted’ error ► Prevent saving changes that require table re-creation
- How to get the last record per group in SQL
- How to convert float to varchar in SQL Server
- A transport-level error has occurred when receiving results from the server [closed]
- How can I load a large flat file into a database table using SSIS?
- storing passwords in SQL Server
- How does sql server sort your data?
- How to restore to a different database in SQL Server?
- SQL Server: Split operation
- How to get week number of the month from the date in sql server 2008
- How to deploy SQL Server Compact Edition 4.0?
- Optional parameters in SQL Server stored procedure
- Entity Framework Database.SetInitializer simply not working
- Cannot open backup device. Operating System error 5
- Restoring database from .mdf and .ldf files of SQL Server 2008
- Restrict SQL Server Login access to only one database
- T-SQL strip all non-alpha and non-numeric characters
- How can I get a trigger to fire on each inserted row during an INSERT INTO Table (etc) SELECT * FROM Table2?
- Can I pass variable to select statement as column name in SQL Server [duplicate]
- SQL Server 2008 Connection Error “No process is on the other end of the pipe”
- SSIS LookUp is not dealing with NULLs like the docs say it should
- Recursive Child/Parent queries in T/SQL
- Forcing code-first to always initialize a non-existent database?