The Zurich release has arrived! Interested in new features and functionalities? Click here for more

The value of True/false field

sonita
Giga Guru

In my table I have a field called u_active and the type is True/False.

In my record producer I have a drop down field the values of Add and Delete.

When a record is submitted with 'Add' flag the u_active field should be shown as true; and when a record is submitted with 'delete' flag the u_active field should be shown as false.

(we will keep the deleted records in the database as well)

I have set the default value of the u_active field as true in the dictionary.

in the script section of my record producer I have this code:

if(producer.Add_Delete=="Add")

rec.u_active='true';

if(producer.Add_Delete=="Delete")

rec.u_active='false';

            rec.update();

} else{

rec.initialize();

            rec.u_src_grp_no = group_ids[x];

            rec.u_cid = producer.u_cid;

            rec.u_renewal_month = producer.u_renewal_month;    

rec.u_ctb_prgm_start_dt=producer.u_ctb_prgm_start_dt;

    rec.u_ctb_prgm_end_dt=producer.u_ctb_prgm_end_dt;

rec.u_req_type=producer.Add_Delete;

            rec.insert();

But it does not work!!!!!!!!!!!!! it always shows True. Any help would be greatly appreciated.

24 REPLIES 24

I create new records and then test


find_real_file.png


find_real_file.png


find_real_file.png


timmyweytjens
Tera Expert

Hello,



Can you try without the quotes:


rec.u_active = true;