How to write to TO CHAR and TO DATE SQL SERVER
来源:互联网 发布:网络暴力 电影 2011 编辑:程序博客网 时间:2024/06/08 09:21
Select convert(char,EMPJOINDATE,101) as EMPJOINDATE FROM emp;
Additionally, here is how to retrieve the current date and the formats
select convert(char, getdate(), 100) --mon dd yyyy hh:mmAM (or PM)
select convert(char, getdate(), 101) --mm/dd/yyyy
select convert(char, getdate(), 102) --yyyy.mm.dd
select convert(char, getdate(), 103) --dd/mm/yyyy
select convert(char, getdate(), 104) --dd.mm.yyyy
select convert(char, getdate(), 105) --dd-mm-yyyy
select convert(char, getdate(), 106) --dd mon yyyy
select convert(char, getdate(), 107) --mon dd, yyyy
select convert(char, getdate(), 108) --hh:mm:ss
select convert(char, getdate(), 109) --mon dd yyyy hh:mm:ss:mmmAM (or PM)
select convert(char, getdate(), 110) --mm-dd-yyyy
select convert(char, getdate(), 111) --yyyy/mm/dd
select convert(char, getdate(), 112) --yyyymmdd
select convert(char, getdate(), 113) --dd mon yyyy hh:mm:ss:mmm
select convert(char, getdate(), 114) --hh:mm:ss:mmm(24h)
select convert(char, getdate(), 120) --yyyy-mm-dd hh:mm:ss(24h)
select convert(char, getdate(), 121) --yyyy-mm-dd hh:mm:ss.mmm
- How to write to TO CHAR and TO DATE SQL SERVER
- How to write Bibliography
- how to write makefile
- How to write makefile
- How to write patent
- how to write Makefile
- DLL - How to Write
- how to write
- How to write rebuttal ?
- How to use boost::property_tree to load and write JSON
- how to convert char to char []
- nodejs canvas to base64 and post server write to image
- How to backup and restore database in SQL Server
- to char 和 to date 的用法
- How (and How Not) to Write a Good Systems Paper
- Sql Server - How to write a Stored procedure in Sql server
- How to write a Makefile
- How to Write English Papers
- [Cocoa]XCode的一些调试技巧
- 知识总结 ExtJs"入门"
- 第三,四,五,十一章 设计模式和面向对象的各种规则(读书笔记)
- 将PFX证书导入USB-KEY
- DataTable中三种获取参数值的方法
- How to write to TO CHAR and TO DATE SQL SERVER
- C++ socket实现获取本机IP&MAC
- Java的Properties文件操作类
- android-drawable大小
- js switch case default 的用法
- Android学习笔记: 第三天
- Oracle中的Translate与Replace
- 为什么Windows Phone 7不支持C++?
- 写javascript代码的技巧