Hi All
I spent several days reading and searching examples of how to implement
channels. The current status of my project is as follows:
- I have a page which lets the user enter the data used for the offline
calculations, a POST request is send
- the post request is handled and I can
I think you would still need some SQL, you could use annotate to add the
field with the value of the calculation and then add .order_by() to the
queryset
https://docs.djangoproject.com/en/1.10/ref/models/expressions/#raw-sql-expressions
On Tue, Nov 29, 2016 at 11:07 PM, Artem Bernatskyy <
artem.b
Hello, how to rewrite this PostgreSQL query to Django ORM with no raw SQL ?
select * from finance_fund order by((select price from finance_nav where
date='2016-11-08' and fund_id=finance_fund.id)/(select price from
finance_nav where date='2016-11-07' and fund_id=finance_fund.id)) LIMIT 30;
So
I have a model Product which a Foreign Key to a Company model. The Company
Model has a OneToOne Relationship to user.
When a user submits a form to add product I need to associate the product
with the company of the user (the user doesn't need to add manually the
company in the form)
There ar
A model was designed with a wrong assumption of uniqueness and given a
natural key. We now need to switch to a surrogate primary key.
Upgrading Django is currently not an option. The production database
may not be dropped/restored for this, it is in use by several
unrelated projects (remember the t
The problem is in your html. Browsers can only send data for inputs with a
`name` attribute, which Django then uses as the key in the querydict, whereas
the `value` attribute becomes the value for that key.
None of your inputs have names. It also doesn't make sense to add the id to the
form or
6 matches
Mail list logo