如何在SQL中搜索包含冒号的字符串?(How can i search for a string in SQL which contains a colon?)
有没有办法在SQL中搜索包含冒号的字符串?
例:
我在数据库中有像
2009-09-17 05:00:00.000
和2011-11-10 06:00:00.000
的值。 但是我想要所有具有05:
的值。我尝试了以下SQL,但它给了我一个空白的结果:
SELECT cast(narrative_date as datetime) FROM P_MATTER_NARRATIVE WHERE cast(narrative_date as datetime) LIKE '%05:%';
谢谢Rajan
Is there a way I can search for a string in SQL which contains a colon?
Example:
I have values like
2009-09-17 05:00:00.000
and2011-11-10 06:00:00.000
in the database. But I want all the values which have05:
in them.I tried the following SQL, but it gives me a blank result:
SELECT cast(narrative_date as datetime) FROM P_MATTER_NARRATIVE WHERE cast(narrative_date as datetime) LIKE '%05:%';
Thanks Rajan
原文:https://stackoverflow.com/questions/31238938
满意答案
显然,我上次尝试这个时忘了包含always关键字。
<div style="page-break-after:always"></div>
毕竟这确实最终起作用了。 只需要确保div始终关闭,否则它不会被切断。 或者,也许更安全的方法是使用:
<div style="page-break-before:always"></div>
这样,如果你不小心忘记关闭它,我相信它仍然会削减页面。
Apparently, last time I tried this I forgot to include the always keyword.
<div style="page-break-after:always"></div>
That did end up working after all though. Just have to make sure that div is always closed or else it won't cut. Alternatively, perhaps a safer approach is to use:
<div style="page-break-before:always"></div>
That way if you accidentally forget to close it, I believe it'll still cut the page.
相关问答
更多wkhtmltopdf page-break-after有空格(wkhtmltopdf page-break-after have whitespace)
为特定页面设置浏览器打印机(Set browser printer for specific page)
在vb.net中打开连接到USB的打印机的现金抽屉(Open cash drawer with printer connected to USB in vb.net)
打印机将在每一页上打印是/否对话框(Yes/No Dialog on every page the printer will print)
打印机页面尺寸问题(Printer Page Size Problem)
TSP100和reportviewer 10.0 A7(TSP100 and reportviewer 10.0 A7)
如何设置Epson打印机上的打印机可打印区域?(How to set printer printable area on Epson printer?)
明星tsp100打印机,使其剪切页面(分页)(Star tsp100 printer, make it cut the page (page break))
采用OPOS的Star TSP700 TSP743U逐行打印(Star TSP700 TSP743U using OPOS prints line-by-line)
page-break / webkit-region-break不再使用chrome了吗?(page-break/webkit-region-break not working in chrome anymore?)
相关文章
更多Solr: a custom Search RequestHandler
Becoming a data scientist
a favorite song
Sql Support within Solr-类Sql的solr搜索实现(1)
ServletOutputStream cannot be resolved to a type
Stack Overflow Architecture Update - Now At 95 Million Page Views A Month
ElasticSearch入门-Bulk,Search操作
Spark - A Fault-Tolerant Abstraction for In-Memory Cluster Computing
Java String类
sql问题
最新问答
更多您如何使用git diff文件,并将其应用于同一存储库的副本的本地分支?(How do you take a git diff file, and apply it to a local branch that is a copy of the same repository?)
将长浮点值剪切为2个小数点并复制到字符数组(Cut Long Float Value to 2 decimal points and copy to Character Array)
OctoberCMS侧边栏不呈现(OctoberCMS Sidebar not rendering)
页面加载后对象是否有资格进行垃圾回收?(Are objects eligible for garbage collection after the page loads?)
codeigniter中的语言不能按预期工作(language in codeigniter doesn' t work as expected)
在计算机拍照在哪里进入
使用cin.get()从c ++中的输入流中丢弃不需要的字符(Using cin.get() to discard unwanted characters from the input stream in c++)
No for循环将在for循环中运行。(No for loop will run inside for loop. Testing for primes)
单页应用程序:页面重新加载(Single Page Application: page reload)
在循环中选择具有相似模式的列名称(Selecting Column Name With Similar Pattern in a Loop)
Copyright ©2023 peixunduo.com All Rights Reserved.粤ICP备14003112号
本站部分内容来源于互联网,仅供学习和参考使用,请莫用于商业用途。如有侵犯你的版权,请联系我们(neng862121861#163.com),本站将尽快处理。谢谢合作!