Page 1 of 1
Pulling the Payment Tansaction ID Value
Posted: Mon Feb 27, 2012 10:09 am
by vashts1980
As part of the integration project I'm working on, I need to pull the transaction ID number from the payments attached to each order. However, instead of the long value which I am trying to obtain, I keep getting a short four digit value. If anyone knows what to pull from the order information to get this value, it would be great to given a point in the right direction. I've included a screenshot of what I'm trying to pull.

Re: Pulling the Payment Tansaction ID Value
Posted: Mon Feb 27, 2012 10:55 am
by david-ebt
You're looking for the ProviderTransactionId in the ac_transactions table.
If you're working directly in the database, here's a query to pull that info based on ordernumber.
Code: Select all
select o.orderid, o.ordernumber, t.ProviderTransactionId, t.AuthorizationCode
from ac_orders o
join ac_payments p on o.orderid = p.orderid
join ac_transactions t on p.paymentid = t.paymentid
where o.OrderNumber = '77211'
If you're using the CommerceBuilder API, you'll need Order.Payments.Transactions
Re: Pulling the Payment Tansaction ID Value
Posted: Mon Feb 27, 2012 11:08 am
by vashts1980
Yes, I'm using the API in C#. And thank you for the info. My command now looks like..
Code: Select all
order.Payments[0].Transactions[0].ProviderTransactionId
I'll give that a try. I didn't think about treating Payments like an array.