Hi,

> Le 23 nov. 2016 à 07:04, [email protected] a écrit :
> 
> I need to Filter from multiple tables and return response like this [ {'first 
> name':'Max',','last name':'Yuri','age':23,'gender':'Male'},{'first 
> name':'Alex',','last name':'John','age':23,'gender':'Male'}]
> in rest framework.
> here 
> 1.first name and last name come from django 'auth.User' table
> 2.age and gender comes from another table
> 
> how can i stitch these tables return response as specified above in rest 
> framework.
> i can able to do it in custom API but i dont know in rest framework.Please 
> Help Me ?
> 
> Thank You.

Everything you need should be in 
http://www.django-rest-framework.org/api-guide/filtering/ 
<http://www.django-rest-framework.org/api-guide/filtering/>
If you’re not sure how spanning across tables with Django, I recommend you read 
this section: 
https://docs.djangoproject.com/en/1.10/topics/db/models/#many-to-many-relationships
 
<https://docs.djangoproject.com/en/1.10/topics/db/models/#many-to-many-relationships>

Regards,
Xavier,
Linovia.

-- 
You received this message because you are subscribed to the Google Groups 
"Django REST framework" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to