-
Notifications
You must be signed in to change notification settings - Fork 5
Restructure Reconciliation Report in Dashboard #21
Comments
|
Per IRL convo, here's a hack to get the list of payment networks dynamically: select enumlabel from pg_enum where enumtypid =
(select typelem from pg_type where typname='_payment_net'); |
So I was wondering about the structure of the table that we want to get. It would narrow how to get the data a little. Below are the options that I was considering.
OR
|
@kaguillera Let's go for: 2012-06
|
Actually, we want to diff this against our books programmatically ... |
Per IRL convo, let's aim for CSVs at endpoints like this: https://gratipay.com/dashboard/reconciliation/2012-06.csv With columns as above: |
"What about the payout part?"—@kaguillera |
Yeah, we'll need that. Let's focus on what we need for 2012-06 and 2012-07. We can evolve the export as we work through the rest of the months. |
|
produces:
Not exactly what we are looking for?! |
Since that approach seems to be beyond me at this time I am going to use following query
which produces the following results
The programmatically produce the table show in (#21 (comment)) so here we go... |
@kaguillera Does gratipay/gratipay.com#3975 close this? |
Yes. !m @whit537 |
!m @kaguillera |
So we are doing this in order to be able to quickly and easily visually check if the information that we are producing in the Financial reports reconcile with the entries in the Gratipay database. Please note that this is a work in progess. I am not submitting a PR as yet because I am getting
sometrouble with the SQL. It has been a while.To the point of this post since I digress...I have come up with the following SQL query and would like verification as to if it is correct as well as give some starting point for some one who would like to try. Please note that it has been a while since I have done (years) SQL and it is not my first language. But again I digress.
The query above should produce a table of Payins, Payouts, and income broken down by months and network (i.e. routes/payment vendors). It work...up to a point. It does what it is supposed to but the routes are hard coded and I personally don't like this because it makes the Dashboard Reconciliation Report inflexible. If you have any advice as to how to make it more dynamic please share. I will continue to try and work on it
The text was updated successfully, but these errors were encountered: