简体   繁体   English

SSRS报告报告设计器

[英]SSRS reporting report designer

I have a problem with times conversion. 我对时间转换有疑问。 In my database, I have 2018-08-20 08:30:11.000 PM and I can't change this format. 在我的数据库中,我有2018-08-20 08:30:11.000 PM ,我无法更改此格式。

When I use =Fields!DateTime.Value , I display the date like this (it's only example). 当我使用=Fields!DateTime.Value ,我这样显示日期(这只是示例)。

示例照片

But I want to display it in this way (date is ok) 2018-08-20 20:30:11 . 但我想以这种方式显示它(日期确定) 2018-08-20 20:30:11 I thought about searching this value and when it will be PM then add 12 to hour but it doesnt work... I have no more ideas... 我考虑过搜索该值,何时将其作为下午,然后将12添加到小时,但它不起作用...我没有更多的想法...

=Format(Fields!DateTime.Value,"MM/dd/yyyy") & Environment.NewLine & iif (Fields!DateTimeValue="PM"), Format(Fields!DtTmStart.Value="HH+12:mm:ss")

Could somebody help me? 有人可以帮我吗? Please! 请!

The following expression should give you what you need... 以下表达式将为您提供所需的信息...

=Format(Fields!DateTime.Value,"yyyy/MM/dd HH:mm:ss")

Note the upper case HH, this gives 24 hour format (hh = 12 hour format) 请注意大写字母HH,这给出了24小时格式(hh = 12小时格式)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 SSRS报告报告服务器速度慢 - SSRS report Slow in Reporting Server 在SSRS报表设计器3.0中选择“最后记录” - Select Last Record in SSRS report Designer 3.0 是否可以在SSRS报表设计器中使用XML数据集 - Is it possible to use XML dataset in SSRS report designer 多次打印报告,(SSRS 报告服务) - Print a report Multiple times, (SSRS reporting services) SSRS报表的SQL查询Visual Studio查询设计器 - SQL Query for SSRS Report Visual Studio Query Designer SSRS 报表设计器在打印布局中截断柱形图 - SSRS Report Designer Cutting off Column Chart in Print Layout SSRS Reporting Services,具有较大间隙/空间的ASP Report Viewer呈现 - SSRS Reporting Services, ASP Report Viewer Rendering With Large Gaps/Spaces 报告服务配置管理器无法启动当前报告服务器 - SSRS - Reporting service configuration manager unable to start currect report server - SSRS 无法从SSRS报表设计器访问SQL Server实例-命名管道错误 - Cannot access SQL server instance from SSRS Report Designer - Named Pipe error 如何在运行时在 SSRS(SQL Server Reporting Services)中压缩和通过电子邮件发送 Excel 报告? - How to Compress and Email Excel Report in SSRS(SQL Server Reporting Services) in Run Time?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM