SQL Queries - CAST Knowledge Base - Queries on objects - How to get object GUID
Purpose of Query
This page provides queries to get the object GUID as per object name or object id
Applicable CAST Version
| Release | Yes/No |
|---|---|
| 8.3.x | ✅ |
| 8.2.x | ✅ |
| 8.1.x | ✅ |
| 8.0.x | ✅ |
| 7.3.x | ✅ |
Applicable RDBMS
| RDBMS | Yes/No |
|---|---|
| Oracle Server | ✅ |
| Microsoft SQL Server | ✅ |
| CSS2 | ✅ |
Query for CSS, Oracle, SQL Server
To search by object name, use the following query by replacing
SELECT k.IdKey , k.KeyNam, o.IdNam AS GUID FROM Objects o JOIN Keys k ON k.IdKey = o.IdKey AND k.KeyNam LIKE ‘%
2. To search by object id, use the following query by replacing <object id>
```java
SELECT k.IdKey ,
k.KeyNam,
o.IdNam AS GUID
FROM Objects o
JOIN Keys k
ON k.IdKey = o.IdKey
AND k.IdKey = '%<object id>%'
Query result example
| methCS_Net?y:\dotnet\project_name\object_name\controls?aspWS_Net?object_name?nmsp_Net?Controls?nmsp_Net?object_name?nmsp_Net?RestaurantListControls?nmsp_Net?MarketCuisinesSet?clsCS_Net?GetCuisineAreaAndPriceText(cls_Net?c:\windows[microsoft.net](http://microsoft.net/)\framework64\v2.0.50727\mscorlib.dll?asm_Net?System?nmsp_Net?String,out cls_Net?c:\windows[microsoft.net](http://microsoft.net/)\framework64\v2.0.50727\mscorlib.dll?asm_Net?System?nmsp_Net?String,out cls_Net?c:\windows[microsoft.net](http://microsoft.net/)\framework64\v2.0.50727\mscorlib.dll?asm_Net?System?nmsp_Net?String) |
| methCS_Net?y:\dotnet\project_name\object_name\object_name.csproj?proj_Net?object_name?nmsp_Net?Controls?nmsp_Net?object_name?nmsp_Net?RestaurantListControls?nmsp_Net?MarketCuisinesSet?clsCS_Net?GetCuisineAreaAndPriceText(cls_Net?c:\windows[microsoft.net](http://microsoft.net/)\framework64\v2.0.50727\mscorlib.dll?asm_Net?System?nmsp_Net?String,out cls_Net?c:\windows[microsoft.net](http://microsoft.net/)\framework64\v2.0.50727\mscorlib.dll?asm_Net?System?nmsp_Net?String,out cls_Net?c:\windows[microsoft.net](http://microsoft.net/)\framework64\v2.0.50727\mscorlib.dll?asm_Net?System?nmsp_Net?String) |
Query result interpretation
The above GUID is the object ID selected while running the query.
Notes/comments
Related Pages