How to find the number of stored procedures, tables, functions present in the database?
Please help me find the above.
select count(*) from DatabaseName.information_schema.routines where routine_type in ('PROCEDURE', 'FUNCTION', 'TABLE')
You can use sys.Tables for sys.Tables tables for stored procedures and this answer for functions.
sys.Tables
Simply
SELECT COUNT(*) FROM sysobjects WHERE xtype IN ('u', 'p', 'fn')
Hope this helps.
SELECT * FROM user_objects WHERE object_name LIKE 'proc%' ....
SELECT * FROM DB_Name.INFORMATION_SCHEMA.TABLES
SELECT * FROM sysobjects WHERE (xtype = 'p')
You can get all the information from sysobjects
Source: https://habr.com/ru/post/891626/More articles:Why does the standard put a css and js file at the top and bottom of the page (respectively)? - javascriptSynchronizing data from a relational database in Couch DB - synchronizationHow to justify text alignment in html5 canvas? - html5how to update datagrid in windows mobile? - c #Is this a good idea for an enumeration based template? - c ++What is the purpose of a Java class loader? - javaJavascript prototype class extension problem - javascriptHow to install a button in a fixed place at the bottom of the user interface? - android@Singleton or getSingletons () when implementing Singleton Resources in Jersey - javaParameters with Dapper parameters with auto-generated LINQ types - c #All Articles