- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
我对元查询充满热情,我的意思是回答关于数据的问题,而不是用数据回答问题。
在我得到很多合理的批评之前,我确实意识到元查询的方法并不理想,正如 Eloquent 地描述的那样here例如。尽管如此,我相信他们确实有自己的位置。 (以至于我创建了一个支持 SQL Server、Oracle 和 MySql 参数化元查询的 WinForms 用户控件,并且我在 Simple-Talk.com 上发布的 three-part series 中广泛描述了此 QueryPicker 的设计和使用。 )
我使用元查询的动机:
当然还有其他(更好?)方法来获取给定数据库类型的元信息。。 SQL Server 特别提供了 SQL Server Management Studio。 Oracle 和 MySql 工具似乎没有提供相同的用处。 (我坦率地承认,我是用我的 SQL-Server 世界观来做出这一主张的。:-) 即使他们这样做了,它们也会有所不同——我想要一种跨数据库类型的统一方法 em>.
<小时/>您认为哪些 SQL Server、Oracle 或 MySql 元查询有用?
<小时/>第一个 View 按数据库类型总结了我迄今为止的收集(并且,正如我所说,主要针对 SQL Server)。
Query SQL Server Oracle MySqlDB Version yes yes yesDatabases with properties yes yesDatabases with space usage yesNational Language Support yesProcedures and functions yes yesPrimary keys yes yesPrimary to foreign keys yesSession Information/brief yesSession Information/details yesSession SET options yesUsers and Roles yesCurrently running statements yesConstraints yesIndexes yesColumn info/brief yes yes yesColumn info/details yes yes yesObject level details yesRows and space used yesRow/column counts yesNon-empty tables yes yes yesShow table schema yes yesSeed/max values yes<小时/>
我自己开发了一些元查询,但许多元查询来自社区论坛。第二个 View 在适当的情况下逐项列出了源 URL。
System Category----------------- DB Version Databases with properties http://www.mssqltips.com/tip.asp?tip=1033 Databases with space usage http://www.sqlservercentral.com/Forums/Topic261080-5-1.aspx Procedures and functions Primary keys http://databases.aspfaq.com/schema-tutorials/schema-how-do-i-show-all-the-primary-keys-in-a-database.html Primary to foreign keys http://www.sqlservercentral.com/scripts/Miscellaneous/61481/ Session Information/brief http://www.sqlservercentral.com/blogs/glennberry/archive/2009/12/28/how-to-get-a-count-of-sql-connections-by-ip-address.aspx Session Information/details http://www.mssqltips.com/tip.asp?tip=1817 Session SET options Users and Roles http://www.sqlservercentral.com/scripts/users/69379/ Currently running statements http://www.sqlservercentral.com/articles/DMV/64425/ Constraints Indexes http://www.sqlservercentral.com/scripts/Index+Management/63932/Column Category----------------- Column info/brief Column info/detailsTable Category----------------- Object level details Rows and space used http://www.mssqltips.com/tip.asp?tip=1177 Row/column counts Non-empty tablesDDL Category----------------- Show table schema http://www.sqlservercentral.com/scripts/Create+DDL+sql+statements/65863/Data Category----------------- Seed/max values
System Category----------------- DB Version National Language SupportColumn Category----------------- Column info/brief Column info/detailsTable Category----------------- Non-empty tablesDDL Category----------------- Show table schema
System Category----------------- DB Version Databases Procedures and functions Primary keys http://databases.aspfaq.com/schema-tutorials/schema-how-do-i-show-all-the-primary-keys-in-a-database.htmlColumn Category----------------- Column info/brief Column info/detailsDDL Category----------------- Show table schema
最佳答案
Oracle SQL Developer 有一组包含这些类别的内置报告。我扩展了其中一个类别。
About Your Database
All Objects
Application Express
ASH and AWR
Database Administration
All Tables
Cursors
Database Parameters
Locks
Memory
Sessions
Storage
Top SQL
Users
Waits and Events
Data Dictionary
Jobs
PLSQL
Security
Streams
Table
XML
这些是一些实际的报告名称,
Tables without Indexes
Tables without Primary Keys
Tables with Unindexed Foreign Keys
Largest Average Row Length
Most Rows
Unusable Indexes
还有更多可用报告。
关于sql - 最有用的 SQL 元查询,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/2321704/
当我开始学习一门新语言时,我总是觉得我没有以实用、标准的方式进行学习。所以这里有一个关于 jQuery 的问题以及我所做的是否可以接受。 我有 3 张图片。 然后我让 jQuery 检测 $('
基本上,我想知道线程是否有用或必要,或者可能更具体地说,您将使用它的用途和情况。我对线程了解不多,也从未使用过它(我主要使用 C#),并且想知道如果使用它们是否会提高性能或稳定性。如果有人愿意解释一下
这个问题在这里已经有了答案: What is The Rule of Three? (8 个答案) 关闭 7 年前。 嘿嘿。我有一个让我很难过的问题。我自定义了一个普通的拷贝构造函数但它只在我初始化
这个问题在这里已经有了答案: 关闭 12 年前。 Possible Duplicate: Uses for multiple levels of pointer dereferences? 我在 C
我不确定异常在每种语言中的工作方式是否相同,但我使用的是 PHP,我想知道我什么时候做这样的事情: if (!$this->connection[0]->query($this->query)) t
Scala native 是最近发布的,但是他们(现在)使用的垃圾收集器非常rudimentary,因此不适合严肃使用。 所以我想知道:为什么不只将Scala转换为Go (即Scala.js)?这将是
最近,我一直在研究docker及其对SaaS公司的有用性。我花了一些时间学习如何容器化应用程序,并简要了解了什么是docker和容器。我在理解这项技术的实用性时遇到了一些问题。我看过dockercon
我必须根据出现在它们之前的字符串是否是某个关键字“load”从输入文件中读取整数。没有关键数字告诉我们要输入多少个数字。这些数字必须保存到一个数组中。为了避免为扫描的每个附加数字创建和更新新数组,我想
Deferred 对象具有回调池 doneCallbacks、failCallbacks 和 progressCallbacks。 doneCallbacks 和 failCallbacks(以及方法
这个问题在这里已经有了答案: Is there a case where including the same header twice is actually helpful? (6 个答案) 关
我在C++ Programming Language的书上看到了下面的例子 class Ptr { X* operator->( ); }; voide f(Ptr p) { p-
你能不能: template const T &operator[] (unsigned int x) 我的想法是如果你有一个 map如果有一个包装器类可以让您这样做,那就太好了: obj["Int
根据doc这个tutorial , cmp() returns -1 if x y 教程里也说了 cmp() returns the sign of the difference of two nu
我经常读到 It seem that identity monad is useless. It's not... but that's another topic. 那么谁能告诉我它有什么用? 最佳
我已经知道实现和接口(interface)的基础知识。我不明白什么时候使用接口(interface)。有接口(interface)的要求是什么? 例子: /// Interface demo Inte
在一些 R 函数的主体中,例如 lm,我看到对 match.call 函数的调用。正如其帮助页面所述,当在函数内部使用 match.call 时,会返回指定参数名称的调用;这对于将大量参数传递给另一个
在监督学习中,我有典型的训练/测试分割来学习算法,例如回归或分类。关于无监督学习,我的问题是:训练/测试分割是否必要且有用?如果是,为什么? 最佳答案 这取决于问题、数据集的形式以及用于解决特定问题的
我最近接触到 Javascript 模板并变得非常感兴趣。 我正在使用 MVC 模式构建一个大型 PHP 应用程序。模板由相当棒的 Twig 处理. 我最近遇到了一个 javascript imple
我最近在一个我要重构并拥有的项目中遇到了以下代码行: SomeClass someClass = new SomeClass(); 我这辈子都想不通为什么有人会以这种方式使用泛型。我想出的唯一原因是
亲爱的,我正在阅读这篇关于通过 asp.net 4 中的代码动态添加元标记的帖子 - 但我想问一下对 SEO 有什么好处,静态添加它或者在代码后面添加它没有问题 http://weblogs.asp.
我是一名优秀的程序员,十分优秀!