Suite Deal
12/12/2021, 8:35 PMvar paymentsQuery = query.create({
type: 'customrecord_x',
columns: [
{fieldId: 'custrecord_date'},
{fieldId: 'custrecord_type'},
{fieldId: 'custrecord_company'},
{fieldId: 'name'},
{fieldId: 'custrecord_amount'},
],
groupBy: 'custrecord_type'
});
var resultSet = paymentsQuery.run();
log.debug('paymentsQuery Result:', resultSet);
redfishdev
12/12/2021, 8:38 PMredfishdev
12/12/2021, 8:38 PMSELECT
Employee.LastName,
Employee.FirstName,
SUM( Transaction.ForeignTotal ) AS TotalSales,
SUM( Transaction.TotalCostEstimate ) AS TotalCostEstimate,
SUM( Transaction.EstGrossProfit ) AS TotalGPEstimate
FROM
Transaction
INNER JOIN Employee ON
( Employee.ID = Transaction.Employee )
WHERE
( Transaction.Type = 'SalesOrd' )
AND ( Transaction.ShipDate BETWEEN TO_DATE( '2020-11-01', 'YYYY-MM-DD' ) AND TO_DATE( '2020-11-30', 'YYYY-MM-DD' ) )
AND ( Transaction.Voided = 'F' )
GROUP BY
Employee.LastName,
Employee.FirstName
ORDER BY
Employee.LastName,
Employee.FirstName
redfishdev
12/12/2021, 8:38 PMredfishdev
12/12/2021, 8:38 PMredfishdev
12/12/2021, 8:39 PMredfishdev
12/12/2021, 8:40 PMSuite Deal
12/12/2021, 8:41 PMSuite Deal
12/12/2021, 8:49 PMredfishdev
12/12/2021, 8:49 PMredfishdev
12/12/2021, 8:50 PMredfishdev
12/12/2021, 8:50 PMSuite Deal
12/12/2021, 8:50 PMSuite Deal
12/12/2021, 8:51 PMredfishdev
12/12/2021, 8:51 PMSuite Deal
12/12/2021, 8:51 PMredfishdev
12/12/2021, 8:52 PMredfishdev
12/12/2021, 8:52 PMredfishdev
12/12/2021, 8:53 PMSuite Deal
12/12/2021, 8:54 PMredfishdev
12/12/2021, 8:55 PMredfishdev
12/12/2021, 8:55 PMredfishdev
12/12/2021, 8:55 PMSuite Deal
12/12/2021, 8:56 PMredfishdev
12/12/2021, 8:56 PMredfishdev
12/12/2021, 8:56 PMSuite Deal
12/12/2021, 11:15 PMredfishdev
12/12/2021, 11:29 PMredfishdev
12/12/2021, 11:29 PMvar myFormulaColumn = myTransactionQuery.createColumn({
type: query.ReturnType.CURRENCY,
formula: '{amount} * 125'
});
sorta like thisredfishdev
12/12/2021, 11:29 PMredfishdev
12/12/2021, 11:29 PMredfishdev
12/12/2021, 11:29 PMBUILTIN.DF( IDField )
redfishdev
12/12/2021, 11:29 PMredfishdev
12/12/2021, 11:30 PMredfishdev
12/12/2021, 11:33 PMredfishdev
12/12/2021, 11:34 PMSuite Deal
12/12/2021, 11:38 PMredfishdev
12/12/2021, 11:38 PMSuite Deal
12/12/2021, 11:40 PMredfishdev
12/12/2021, 11:40 PMSuite Deal
12/12/2021, 11:41 PMredfishdev
12/12/2021, 11:45 PMredfishdev
12/12/2021, 11:45 PMSuite Deal
12/12/2021, 11:51 PMvar paymentsQuery = query.create({
type: 'customrecord_x',
columns: [
{fieldId: 'custrecord_date'},
{fieldId: 'custrecord_type'},
{fieldId: 'custrecord_company'},
{fieldId: 'name'},
{fieldId: 'custrecord_amount'},
{fieldId: 'custrecord_pay_method'},
]
});
Yikes! Can't get it to work.Suite Deal
12/12/2021, 11:51 PMredfishdev
12/12/2021, 11:53 PMredfishdev
12/12/2021, 11:53 PM<#switch animal.size>
<#case "small">
This will be processed if it is small
<#break>
<#case "medium">
This will be processed if it is medium
<#break>
<#case "large">
This will be processed if it is large
<#break>
<#default>
This will be processed if it is neither
</#switch>
redfishdev
12/12/2021, 11:53 PMredfishdev
12/12/2021, 11:53 PMSuite Deal
12/12/2021, 11:54 PMbattk
12/13/2021, 12:27 AMredfishdev
12/13/2021, 12:27 AMbattk
12/13/2021, 12:29 AMbattk
12/13/2021, 12:29 AMbattk
12/13/2021, 12:33 AMSuite Deal
12/13/2021, 12:45 AMvar paymentsQuery = query.create({
type: 'customrecord_x',
columns: [
{fieldId: 'custrecord_pay_type',
context: {
name: query.FieldContext.TEXT
}
},
]
});
Suite Deal
12/13/2021, 12:45 AMbattk
12/13/2021, 12:48 AMbattk
12/13/2021, 12:49 AMoptions.context.name
also has a link to valid query.FieldContext
keysbattk
12/13/2021, 12:49 AMSuite Deal
12/13/2021, 12:50 AMSuite Deal
12/13/2021, 12:52 AMname: query.FieldContext.DISPLAY
Did the trick. Thank you both for your time. I really, REALLY appreicate it!