Created
July 23, 2012 18:13
-
-
Save gscheibel/3165106 to your computer and use it in GitHub Desktop.
assoc information in _id
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"_id": { | |
"bankAccounts_id": "0c9e943e-d77b-44db-b55f-7a8eef451d61" | |
}, | |
"rows": [{ | |
"table": "AccountOwner_BankAccount", | |
"columns": { | |
"owners_id": "05bf8eb9-a20b-459d-bc97-dd370ce36111", | |
"bankAccounts_id": "0c9e943e-d77b-44db-b55f-7a8eef451d61" | |
}, | |
"tuple": { | |
"bankAccounts_id": "0c9e943e-d77b-44db-b55f-7a8eef451d61", | |
"owners_id": "05bf8eb9-a20b-459d-bc97-dd370ce36111" | |
} | |
}] | |
} | |
{ | |
"_id": { | |
"owners_id": "05bf8eb9-a20b-459d-bc97-dd370ce36111" | |
}, | |
"rows": [{ | |
"table": "AccountOwner_BankAccount", | |
"columns": { | |
"owners_id": "05bf8eb9-a20b-459d-bc97-dd370ce36111", | |
"bankAccounts_id": "0c9e943e-d77b-44db-b55f-7a8eef451d61" | |
}, | |
"tuple": { | |
"bankAccounts_id": "0c9e943e-d77b-44db-b55f-7a8eef451d61", | |
"owners_id": "05bf8eb9-a20b-459d-bc97-dd370ce36111" | |
} | |
}] | |
} |
if the filter used by MongoDBDialect is only composed by _id and rows (and I totally agree with that) so why do we need owners_id and bankAccounts_id ?
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
AssociationContext.getSelectableColumns() = { "owners_id", "bankAccounts_id" }
But the mongoDB filters you will use for such structure would be to filter by two columns "_id" and "rows".