I think I have a simple one. I'm doing select * f...
# suitescript
s
I think I have a simple one. I'm doing select * from transaction where transaction.type = 'ItemShip'.... I want to get the "createdfrom". What is the field ?
t
@Simon The createdfrom column is on the TransactionLine table. So you can do something like this:
Copy code
SELECT
	Transaction.TranID,
	Transaction.TranDate,
	BUILTIN.DF( Transaction.Type ) AS Type,
	BUILTIN.DF( Transaction.Status ) AS Status,
	BUILTIN.DF( Transaction.Entity ) AS Entity,
	TransactionLine.CreatedFrom,
	BUILTIN.DF( TransactionLine.CreatedFrom ) AS CreatedFromName
FROM
	Transaction
	INNER JOIN TransactionLine ON
		( TransactionLine.Transaction = Transaction.ID )
		AND ( TransactionLine.MainLine = 'T' )
WHERE
	( transaction.type = 'ItemShip')
s
Thanks a lot