Write a regex to standardize phone numbers by applying formatting logic to match the pattern (XXX) XXX-XXXX.
Create a condition to route separate records by month and assign them to different targets.
Check if address1 contains USA. If yes, concatenate address1 and address2. If not, convert the mod of the ASCII code of the first letter in both the city and state to string.
Extract the month from the start date and compare it to the end date.
次の例に、自然文で記述したプロンプトを示します。
1. Cast all columns to string. Do a left or right trim. 2. Make sure all fields aren't null. 3. If there's a null, replace it with null stringConcatenate all the above using the || operator and don't use the concat function. 4. Create an MD5 function out of the concatenated value.
次の画像に、マッピングと詳細モードのマッピングに対して生成された式を示します。
次の例に、自然文による別のプロンプトを示します。
Cast all columns to string. Do a left or right trim. Join all.
次の画像に、SQL ELTモードのマッピング用に生成された式を示します。
擬似コード
次のサンプルプロンプトに、擬似コードを使用して式を記述する方法を示します。
if order status is New or Processing and order date in January set order status to Fulfilled else if order date in February set order status to Delayed
次の例に、擬似コードを使用したプロンプトを示します。
// --- TIER 1: STRATEGIC & HIGH-GROWTH --- // Criteria: Very high revenue, large size, and an active client in a key industry. IF (Revenue >= 25,000,000 AND NumberOfEmployees >= 5,000 AND (Industry == 'Technology' OR Industry == 'Financial Services') AND Type == 'Active Client') THEN
// --- TIER 2: KEY ACCOUNTS --- // Criteria: High revenue, significant size, OR an active client in any target industry. ELSE IF ((Revenue >= 10,000,000 AND NumberOfEmployees >= 1,000) OR (Revenue >= 5,000,000 AND Type == 'Active Client' AND (Industry == 'Healthcare' OR Industry == 'Manufacturing'))) THEN
Priority_Bucket = 'Tier 2 - Key Accounts'
// --- TIER 3: STANDARD ACCOUNTS --- // Criteria: Established revenue, moderate size, typically a Prospect or long-term Client. ELSE IF (Revenue >= 1,000,000 AND Revenue < 10,000,000 AND NumberOfEmployees >= 100 AND (Type == 'Client' OR Type == 'Prospect')) THEN
Priority_Bucket = 'Tier 3 - Standard Accounts'
// --- TIER 4: DEVELOPMENTAL ACCOUNTS --- // Criteria: Smaller, but strategic as a new Partner or a small company in a key industry. ELSE IF (Revenue >= 100,000 AND NumberOfEmployees >= 50 AND (Industry == 'Technology' OR Type == 'Partner')) THEN