Could you show your whole project?
Em sábado, 19 de dezembro de 2020 às 23:32:26 UTC-3, jul.ale...@gmail.com
escreveu:
> Hello
>
> First, create a query.py , just for order.
>
> [image: image.png]
>
> and declare a function with the parameters you want to receive.
>
> Then, in your views.py
> [
Hello
First, create a query.py , just for order.
[image: image.png]
and declare a function with the parameters you want to receive.
Then, in your views.py
[image: image.png]
you need to import connection from django.db
finally , you can iterate over the rows fetched with one for loop.
[imag
I want to pass parameter in view and i execute the insert query as shown
below.
I have searched and failed to get a solution.
Any hints.
Here is the code. My attempt is shown but not correct.
def post_payroll(request,p_id):
p_id=2
with connection.cursor() as cursor:
query = "in
3 matches
Mail list logo