django模型中e=Emp.objects.all()中的'objects'是什么
What is 'objects' in e=Emp.objects.all() in django Models
Emp 是 django 中的模型,所以 e=Emp.objects.all()
e : 引用查询集
Emp : 参考型号名称
all() :指从table
中获取所有列
对象:?
请深入解释此查询中的 'objects' 是什么。
是模特经理。这是上面的docs。
来自文档:
A Manager is the interface through which database query operations are provided to Django models. At least one Manager exists for every model in a Django application.
Emp 是 django 中的模型,所以 e=Emp.objects.all()
e : 引用查询集
Emp : 参考型号名称
all() :指从table
中获取所有列对象:?
请深入解释此查询中的 'objects' 是什么。
是模特经理。这是上面的docs。
来自文档:
A Manager is the interface through which database query operations are provided to Django models. At least one Manager exists for every model in a Django application.