One more request.........i was earlier able to increment the counter in the table but having issues in performance now .........so would you be able to guide me in how to implement the Increment value in Table same as to one you have given me for Decrementing.
Acutal Scenario is that when user selects a CTI and raises a Ticket then on opening the Form there should be default values(records) loaded in the table.This table hold data of only those records which have a flag set to "Yes". Currently i have a Add/Modify button where in a user selects values from drop down(these are the values like Test1, Test2, Test3 etc....) option and then clicks on Add/Modify Button.If the there is any matching request then it should modify the previous request.and if if there is no matching request then it should create a new record with increment in the values currently in the table. for e,g These are the default values loaded into the table when the ticket is raised. Order ID Value 1 Test1 2 Test2 3 Test3 4 Test4 5 Test5 Now if i want to modify the second record then the order id should not change only the values in it should get modified. Now if i am selecting a new value from drop down menu say suppose Test6 and then adding it then that record should get the record id as '6'. So would like to know how this can be implemented without having performance impact? Regards, Amey On 12/29/08, ccrashh <[email protected]> wrote: > I think the easiest approach is, as Mike said, an Update SQL > statement: > > UPDATE childtablename > SET counter = counter - 1 > WHERE parentrequestid = '$request_id$' AND counter > > '$counterbeingdeleted$' > > childtablename = the schema of the child form > counter = field on the childtablename that stores the 1, 2, 3, etc. > parentrequestid = I am assuming you have some foreign key stored on > the childtable that is the Request ID of the parent record. > counterbeingdeleted = the counter value of the record being deleted > (ie 2). > > This way you don't have to run through a Push Fields filter. > > Steve > > _______________________________________________________________________________ > UNSUBSCRIBE or access ARSlist Archives at www.arslist.org > Platinum Sponsor: www.rmsportal.com ARSlist: "Where the Answers Are" > _______________________________________________________________________________ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: "Where the Answers Are"

