use values().

example:
Foo.objects.filter(name='foo').values('bar', 'baz')

2020年1月12日(日) 2:38 Mohsen Pahlevanzadeh <m.pahlevanza...@gmail.com>:

> Hello everybody,
>
> I can write django code for "select * from mytables;", but I can't
> specefic fields such as "select field(s) from my table;"
>
> Please help me......
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/8ecebac0-f389-41ce-b5b2-a271e3412832%40googlegroups.com
> <https://groups.google.com/d/msgid/django-users/8ecebac0-f389-41ce-b5b2-a271e3412832%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CADM-sYXRaw389KRC5G-FM5-KVoDeao30rhf0fYqjV8b0SLH%3DRw%40mail.gmail.com.

Reply via email to