Can we convert a SQL query to AMPscript?
I have this big query to convert in AMPscript. Is it even possible. Any suggestion or guidance would be helpful. SELECT count(*)FROM properties_viewINNER JOIN markets on properties_view.market_id =...
View ArticleI'm trying to implement a bubble sort in ampscript for sfmc but it doesn't work
%%[set @array = "1,3,11,6,4,8,24,27,13,99,7771,26"set @arrayList = BuildRowsetFromString(@array, ",")set @arrayLength = RowCount(@arrayList)for @i = 1 to Subtract(@arrayLength, 1) do for @j = 1 to...
View ArticleHow to populate FromName and FromEmail in EmailSendLog with both regular and...
Context:I've setup a Dynamic Sender Profile solution using a Code Snippet block call with AMPScript variables and a Configuration DE.Solution works perfectly fine BUT I've come across a limitation of...
View ArticleUse Dynamic Link inside URL in SFMC passing JobID
I have the following problem, this has been killing me all day today. Even though a read the marketing cloud documentation about AMPscript, I couldn't use dynamic links inside the email that I sent in...
View ArticleAn error occurred: Unable to retrieve security descriptor for this frame
I am trying to post an image in third party tool using below code, but getting an error" An error occurred: Unable to retrieve security descriptor for this frame."Can any one please help me, how to...
View ArticleUpdate a bitly link with API using AMPScript in SMS
We are using custom back-half links in Bitly to redirect to a CloudPage for capturing clicks in SMS campaigns. However, we encountered an issue: Bitly only accepts static links. This means that if I...
View ArticleEmail content changes on browser view
Tool Used: Salesforce Marketing CloudProcess:When a user places an order on the website,they receive an order confirmation email.This email is created using AMPscript in Salesforce Marketing...
View ArticleAmp script claim row is claiming same row twice
I'm running into a weird case where the claimrow function is claiming the same row for multiple users. What I am trying to do is prevent a user from receiving an email if he/she already received a...
View ArticleAMPScript: How can use DecryptSymmetric() function to decrypt an encrypted...
I need to decrypt an encrypted string using AMPScript's DecryptSymmetric() function which is coming from an external system(PHP). I am not sure which algorithm PHP should use to encrypt the string, so...
View ArticleAMPscript: Rounding a number in a text field that has several decimals
I have a text field that holds price values like 1190.00 and 1216.666666667.I've used AMPscript to round the numbers to 0 decimal places. Referencing this Q&A Round a number with AMPscript I'm able...
View ArticleAMPscript Lookup fails to find record
Having trouble with lookup not returning what's expected.The @LOTeamName is what I'm having trouble returning. No errors when I run it, it just doesn't return anything even though I know it's...
View ArticleInserting data from data extension into email using ampscript
I'm trying to create a report like email that will send an email to me that includes all the data in the data extension. When I run do preview and test the email, I get the fall back message - No...
View ArticleCreating new subscriber on ENT 2.0 account using ampscript
We are builing landing pages using ampscript to unsubscribe email address submitted via these pages. The pages should check for email address to existing subscriber and unsubscirbe them or create new...
View ArticleJWT | Does anyone know why JWT generated via AMPscript is diferrent than...
Ref link1 = AMPscript JWT = https://ampscript.guide/getjwt/Ref link2 = JWT official site = https://jwt.io/Comparison link = https://www.diffchecker.com/tEwnbx5h/JTW generated via AMPscriptJWT generated...
View ArticleRetrieveSalesforceObjects with date filter - Ampscript
I need to consult Salesforce records that where created in the last 7 days, but when I test the email it appears the following error:Call to retrieve records for salesforceobject Questionario__c...
View ArticleRequestParameter in Ampscript and how it is used?
We have a html form and from this form we fetch email address.For example, the form input field looks like this,<input type="text" name="EmailAddress">Then there is the amp-script code to fetch...
View ArticleMarketing Cloud: AMPscript redirect not working
When trying to use 'redirect', my 'starting' page will no longer load (returning the 500 error). Not sure what I'm doing wrong here. FYI: If I remove the redirect code, the page loads just fine. Here's...
View ArticleUpdate Data Extension with keyword in Mobile Connect Text response
I was trying to trigger a specific MobileConnect text response keyword which should update a Data extension. When I add some ampscript to the outbound response, I get an error saying "There was an...
View ArticleWeb Analytics Connector customization
I have to setup my WAC configuration including a IIF() function to detect if linkname contains the "%" char. In case of yes, I will include one AMPSCript var I am setting up in the context called...
View ArticleGet Marketing Cloud UserID (numeric)
I'm currently following this guide:https://developer.salesforce.com/docs/atlas.en-us.noversion.mc-programmatic-content.meta/mc-programmatic-content/createDataExtension.htmTo create a data extension via...
View Article