首页 > 代码库 > crmsql查询表的信息

crmsql查询表的信息

--查询指定的lookup字段对应的实体
select name,OriginalLocalizedName from MetadataSchema.Entity
where objecttypecode in (
 select objecttypecode from dbo.v_attributeobjecttypes where entityid in
 (select entityid from entity where name =‘new_store‘)
 and attributename = ‘new_area‘
)

--查询异步作业
select * from dbo.AsyncOperation

 

--查询站点地图
select * from  dbo.IsvConfigBase

--查询组织信息
select * from  dbo.Organization

--查询一个实体的权限(实体: new_member)
select * from dbo.PrivilegeBase where name like ‘%new_member‘

--查询存储过程信息
select * from MetadataSchema.StoredProcedureCatalog