No, when I do it in flowscript procedure it works fine:

function do_new_component() {
        var param = cocoon.parameters.id;
        var form = new Form("forms/components.xml");
        var formMap = form.asMap();
        form.showForm("viewform-component-template.html");
        if (form.isValid) {
                dao.dbi.execute("insert into compositions 
values(seq_compositions.NEXTVAL, :density)", formMap);
        }
        var url = "" + param + "/do_list_compositions";
        cocoon.redirectTo("phisical_parameters", true);
}

-----Original Message-----
From: Jeroen Reijn [mailto:[EMAIL PROTECTED] 
Sent: Monday, August 25, 2008 1:40 PM
To: users@cocoon.apache.org
Subject: Re: using fd:on-value-changed ???

Hi,

See http://ora-00904.ora-code.com/. It means that the settings are 
probably incorrect for the columns in the db.

Regards,

Jeroen Reijn

Мария Григорьева wrote:
> Hello!!! I’m trying to update form data, using on-value-changed:
> 
>  
> 
> <fd:field id="density" required="true">
> 
>                 <fd:label>Плотность</fd:label>
> 
>                 <fd:datatype base="decimal"/>
> 
>                 <fd:on-value-changed>
> 
>                                <javascript>
> 
>                                                var value = this.value;
> 
>                                                var test = 
> cocoon.parameters["comp_id"];
> 
>                                                var sql = "update 
> compositions set density = " + value + " where id = " + test;
> 
>                                                dao.dbi.execute(sql);
> 
>                                </javascript>
> 
>                 </fd:on-value-changed>
> 
>   </fd:field>
> 
>  
> 
> But as output I’ve got the exception:
> 
>  
> 
> java.sql.SQLException: ORA-00904: "UNDEFINED": invalid identifier
> 
>  
> 
> What’s the problem ?
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to