cancel
Showing results for 
Search instead for 
Did you mean: 

delete record from database

Former Member
0 Kudos

GudDay,

I created education details iview which displays list of records for a person,Iam able to create new record and add it to the database table.But when it comes to delete iam not able to delete it from the database.

Can anyone explain me wat are the key fields i should mention in the backend so that after selecting a row and clicking delete button it deletes record from the database?

Awaiting ur reply.

Thanks,

Deepthi.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

hi martina......

first read the row tht has been slected or jsut read the primary keys...

in your case it might be a roll no.

then use this syntax:

delete from <database table> where <field> = <value>.

---regards,

alex b justin

Former Member
0 Kudos

Gudday,

If i want to add another button to update database....Iam facing an ambiguity.Requirement is to hav 3 buttons

create,modify n delete on screen below education details records for particular pernr.Can i write code which will call same group with different bindings each time when i click one of thes three buttons??

1)If i click modify it should call group where the selected row contents are dispalayed in output screen and if i change n save it should b updated.

2)If i click delete it should delete row selected from both frontend and database.

3)If i click create it should display empty fields.

Awaitng your reply.

Thanks,

Deepthi.

Former Member
0 Kudos

hi martina..

create an attribute in the context with char1.

now when save is clcked...

in the on action method, update teh attribute to 'x'.

in the wddomodify view method...

check for the attribute, if it is x then method for save should be called.

if y, method for update,

if z, method for delete.

---regards,

alex b justin

Former Member
0 Kudos

Gudday,

I Created attribute char1 under type string and onaction raised char1 flag to different values based on the

functin(del,mod,ins).using case statement i performed operations by calling function modul,which was created to perform ins and mod operation in wddomodifyview ....should i do attribute char1 binding?if so where??

only wddoinit code is executed....the code written in wddomodifyview is not working...actually how is the control flowing??when will wddomodifyview be executed??

Awaiting ur Reply.

Thanks,

Deepthi.

Former Member
0 Kudos

hi martina.....

whenerver there is an action executed or a change in the view, the wddomodify method will be called....

so when save is clcked....

the attribute is set to 's'.

then control moves to wddomodify.

read the attribute.

call the corresponding fm.

when delete is clcked....

the attribute is set to 'd'.

then control moves to wddomodify.

read the attribute.

call the corresponding fm.

and it contiues.

but at the end of wddomodify, clear the attribute.

or better have seperate methods and call tehm whenever the particular button is clicked.

---regards,

alex b justin

Former Member
0 Kudos

Gudday,

When i click f4 button for few fields in the browser screen it is not showing any values to select,

instead it is throwing error "COULD NOT FIND FIND ATTRIBUTE LANGU".Can you tell me wat could be the probable error??

Awaiting ur reply.

Thanks,

Deepthi.

Answers (0)