Jeremy5835883
Posts: 0
Joined: Wed May 08, 2013 12:02 pm

querying on a pointer

I have a database with a pointer to a user object. I want to query that table based on the user id. Can you provide a sample of what the query would look like

Jeremy5835883
Posts: 0
Joined: Wed May 08, 2013 12:02 pm

querying on a pointer

i did...they are not clear to me. can you provide an example? please?

Anton Artyukh5836028
Posts: 0
Joined: Wed May 08, 2013 12:57 pm

querying on a pointer

Hi Jeremy,

Example:
We have User with id === "51dba907e4b0cb6cf9c0ba24",
We have collection with column "owner" with type Pointer to Users (pointer<users>)
So if we want retrieve all items with owner "51dba907e4b0cb6cf9c0ba24" we must use this query:
precode{
"owner": {
"$inQuery" : {
"_id": "51dba907e4b0cb6cf9c0ba24"
}
}
}/code/pre
$inQuery is well described here.

Dongzhi Yang7528784
Posts: 0
Joined: Mon May 11, 2015 6:28 am

querying on a pointer

Hi Jeremy/Alena,

The links above seem to be re-redirected, could you please share more information or current links.

Thanks

Dongzhi

Return to “Issues”