Expand my Community achievements bar.

Announcing the launch of new sub-community for Campaign Web UI to cater specifically to the needs of Campaign Web UI users!
SOLVED

Using my SQL scripts in data schema expression

Avatar

Level 7

Hello, I would like to use this function:

Heku__0-1690979639176.png

In the data schema declaration like this:

<attribute expr="GetEmailPreDomain('prefix@xxx.xxx')" label="x" name="x"
type="string"/>

So its value is "prefix"

 

How can I do this?

Thank you in advance.

@Manoj_Kumar_ @ParthaSarathy @Parvesh_Parmar @DavidKangni 

Topics

Topics help categorize Community content and increase your ability to discover relevant content.

1 Accepted Solution

Avatar

Correct answer by
Community Advisor
3 Replies

Avatar

Community Advisor

Hi @Heku_ ,

Try this expression,

expr="Substring(@email,0 ,Length(@email)-Length(GetEmailDomain(@email)))"

<attribute expr="Substring(@email,0 ,Length(@email)-Length(GetEmailDomain(@email)))" label="Email Prefix" name="emailPrefix" type="string"/>

Disconnect & Reconnect.

Avatar

Level 7

Thank you, but i need to do more complex things, like doing a SELECT x FROM actual table order by x DESC LIMIT 1

Avatar

Correct answer by
Community Advisor

Hello @Heku_,

 

Please referre to this documentation to do what you want to do : 

https://experienceleague.adobe.com/docs/campaign-classic/using/configuring-campaign-classic/api/addi...

 

Br,

Amine