uili 0 Newbie Poster

Hello ,
Down here we have my code and the error in the compilation, and i dont know how to resolve this can anyone help me.
Just a introduction:
This python script is used to save datas from a form in sql_data base.


# Available parameters:
# fields = HTTP request form fields as key value pairs
# request = The current HTTP request.
# Access fields by request.form["myfieldname"]
# ploneformgen = PloneFormGen object
#
# Return value is not processed
# Pega as variáveis do Ambiente

################################################
request = container.REQUEST
RESPONSE = request.RESPONSE

################################################
# Recebe os valores da Pagina
################################################
cliente = request.get('Cliente')
equipamento = request.get('Equipamento')
local = request.get('Local')
numero_da_proposta = request.get('Numero_da_proposta')
valor_da_proposta = request.get('Valor_da_proposta')
documentos_de_referencia = request.get('Documentos_de_referencia')
nome_do_autor = request.get('Nome_do_autor')
nome_do_checador = request.get('Nome_do_checador')
data_de_inclusao = request.get('Data_de_inclusao')
arquivo_pt = request.get('Arquivo_pt')

################################################
# Insere as informações no banco
################################################
context.adicionarAoBanco(Cliente=cliente,Equipamento=equipamento,Local=local,
Numero_da_proposta=numero_da_proposta,Valor_da_proposta=valor_da_proposta,
Documentos_de_referencia=documentos_de_referencia,Nome_do_autor=nome_do_autor,
Nome_do_checador=nome_do_checador,Data_de_inclusao=data_de_inclusao
,Arquivo_pt=arquivo_pt)

return "Ok"

Now here we have the error:

Traceback (innermost last):
Module ZPublisher.Publish, line 119, in publish
Module ZPublisher.mapply, line 88, in mapply
Module ZPublisher.Publish, line 42, in call_object
Module Shared.DC.Scripts.Bindings, line 313, in __call__
Module Shared.DC.Scripts.Bindings, line 350, in _bindAndExec
Module Products.PythonScripts.PythonScript, line 327, in _exec
Module None, line 35, in py_insere
- <PythonScript at /KotPlone/KOT/pts/adicionar-pt-1/py_insere>
- Line 35
Module Shared.DC.ZRDB.DA, line 501, in __call__
- <SQL at /KotPlone/KOT/pts/adicionar-pt-1/adicionarAoBanco>
Module Products.ZGadflyDA.db, line 108, in query
Module Products.ZGadflyDA.gadfly.gadfly, line 322, in execute
Module Products.ZGadflyDA.gadfly.kjParser, line 1185, in DoParse1
Module Products.ZGadflyDA.gadfly.kjParser, line 1177, in DoParse
Module Products.ZGadflyDA.gadfly.kjParser, line 842, in GO
Module Products.ZGadflyDA.gadfly.kjParser, line 770, in DoOneReduction
Module Products.ZGadflyDA.gadfly.kjParser, line 826, in ParseError
SyntaxError: unexpected token sequence.near ::
'ivo_pt) values('*'\nnull,\nnull,nul'
*******************************
current state = 186
expects:
'numeric_literal', 'character_string_literal', '?', '+', '-',
('nomatch1',)
current token = ((-8, 'user_defined_name'), 'NULL')

thx
att Uili

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.