Home > Forum > Forms > Solution -> [CLOSED] Q: How to get the name of an ItemList within a SELECT statement?

Solution -> [CLOSED] Q: How to get the name of an ItemList within a SELECT statement?
2

MVP

Good evening everyone,

I'm looking for a way to get the name of an ItemList within a SELECT statement.

I'm planning to build a way to move an ItemList row to another ItemList in the same instance.
Therefore I need an autocomplete field with ID=ItemListID(DET_WFCONID) and Name=? .

I'm kind of stuck.
At the moment I can't even find it under (https://developer.webcon.com/2022/resources/db/).

Anyone out there for a little help?
Thanks in advance,
Bjoern

MVP

Hi Björn,

the column of foreign key (DET_WFCONID) often is a abbreviation of the table.
WFCON refers to WFConfigurations

So you get the name in the designer using:
SELECT [WFCON_ID]
,WFCON_Prompt
FROM [dbo].[WFConfigurations]
where WFCON_ID = 4687

If you want to take translations into account


select isnull(
(
select Trans_name
from Translates
-- Trans-ObjId See table DicTranslationsObjects
where TRANS_OBJID = 11
and TRANS_ELEMID = 4687
and TRANS_LANID = (select LAN_ID from TranslateLanguages where LAN_Name = 'de-DE')
and Trans_name <> ''
)
, (
SELECT WFCON_Prompt
FROM [dbo].[WFConfigurations]
where WFCON_ID = 4687
)) as Translation

Best regards,
Daniel

MVP
In reply to: Daniel Krüger (Cosmo Consult)

Hi Björn,

the column of foreign key (DET_WFCONID) often is a abbreviation of the table.
WFCON refers to WFConfigurations

So you get the name in the designer using:
SELECT [WFCON_ID]
,WFCON_Prompt
FROM [dbo].[WFConfigurations]
where WFCON_ID = 4687

If you want to take translations into account


select isnull(
(
select Trans_name
from Translates
-- Trans-ObjId See table DicTranslationsObjects
where TRANS_OBJID = 11
and TRANS_ELEMID = 4687
and TRANS_LANID = (select LAN_ID from TranslateLanguages where LAN_Name = 'de-DE')
and Trans_name <> ''
)
, (
SELECT WFCON_Prompt
FROM [dbo].[WFConfigurations]
where WFCON_ID = 4687
)) as Translation

Best regards,
Daniel

⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⣀⣀⣀⣀⠀⠀⠀⢀⡤⠤⠤⣄⠀⣀⣀⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
⠀⠀⠀⠀⠀⠀⠀⠀⣀⣀⠤⢴⣴⠒⠉⠹⣴⣏⠀⠀⠀⡀⠈⢇⠀⠀⣼⠀⠀⠀⠘⣶⠇⠀⢨⢃⡾⠓⠲⢤⠀⠀⠀⠀⠀⠀
⠀⠀⠀⣀⠤⠔⠒⠙⣯⣇⠀⠈⣿⣇⠀⠀⣿⣿⣿⠀⠀⣷⠀⠘⡄⠀⣿⠀⠀⠀⠀⢹⠀⠀⢸⡏⠇⠀⢀⠇⣀⠤⠒⠒⠤⣄
⢰⡖⠉⠀⠀⠀⠀⣀⣸⣿⠀⠀⠉⠉⠀⠀⢸⠁⣿⠀⠈⠉⠁⠀⢱⠀⣿⠀⠀⣦⠀⠀⠀⠀⣿⡸⠀⠀⠘⠉⠀⠀⣀⣤⣴⠟
⢼⢣⣀⣴⡀⠀⠘⡿⠏⠗⡆⠀⠠⣶⡆⠀⠸⡄⡏⠀⠀⣶⣷⠀⠀⢧⣿⠀⠀⣿⡆⠀⠀⢸⣿⠃⠀⢰⡄⠀⠐⡿⠛⠋⠀⠀
⠘⢿⡿⢿⣧⠀⠀⢳⠀⢸⠸⠀⠀⢹⣧⢀⣀⣷⣧⣤⣤⠛⣏⣦⣤⣾⣿⢦⣤⣿⢸⣄⣀⣼⡏⠀⢠⡟⡇⠀⠀⡇⠀⠀⠀⠀
⠀⠀⠀⠀⢏⢇⠀⠀⣣⠀⣆⣷⣶⣿⣿⡿⠿⠿⢷⡿⠟⣠⠟⠋⠛⢿⡛⠛⠿⡼⠿⠿⢿⣿⣿⣶⠞⡅⢸⠀⠀⢸⠀⠀⠀⠀
⠀⠀⠀⠀⠘⣾⣿⣿⠇⢠⣟⠉⠙⠷⡿⠀⠀⠀⢸⢀⡼⠁⠀⣀⠀⠀⠹⡄⡼⡇⠀⠀⡜⣸⡏⠙⠢⣧⣾⣦⣀⢸⠀⠀⠀⠀
⠀⠀⠀⠀⠀⠈⠀⠀⠀⢿⣿⣷⣦⡀⠀⠀⠀⠀⣇⡾⠀⠀⣼⣿⢷⠀⠀⢻⢱⠀⠀⢀⣿⡿⠀⠀⢠⠋⢻⡿⠿⣏⠀⠀⠀⠀
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠈⠳⣿⣿⠆⠀⠀⢸⡏⡇⠀⠀⡏⡟⡟⠀⠀⢸⡸⠀⠀⢸⣿⠃⠀⠀⡜⡰⢩⠃⠀⠈⣱⠀⠀⠀
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢸⢹⠀⠀⠀⢸⠀⡇⠀⠀⠙⠋⠀⠀⢀⡏⡇⠀⠀⠘⠋⠀⠀⣰⣱⢣⠇⠀⠀⣰⠃⠀⠀⠀
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⡘⡎⠀⠀⠀⡏⣿⣧⡀⠀⠀⠀⠀⢀⣾⣷⡇⠀⠀⠀⠀⠀⢠⣯⣧⣾⣦⣄⣰⠃⠀⠀⠀⠀
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣧⣧⣤⣶⣶⠃⠘⢿⣿⣷⣶⣶⣾⠟⠉⣿⣿⣦⣄⣀⣠⣴⢏⣽⠋⠉⠙⢿⠁⠀⠀⠀⠀⠀
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠘⠛⠛⠛⠋⠁⠀⠀⠀⠉⠉⠉⠉⠀⠀⠀⠈⠛⠻⠿⠟⠋⠁⣿⣿⣦⣀⣀⡼⠀⠀⠀⠀⠀⠀
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠙⠛⠛⠛⠁⠀⠀⠀⠀⠀⠀⠀

Did you know that with WEBCON you can automate virtually any process? Even baking cookies 🍪
 
Speaking of cookies: we use the ones that are essential for our website to function properly, as well as additional ones that help us customize our content to your preferences. If you don’t mind cookies, click Accept. If you want to learn more, explore settings.
Settings