Author Topic: Multi Update  (Read 2319 times)

omerix

  • Pro Enterprise
  • Full Member
  • *
  • Posts: 148
    • View Profile
Multi Update
« on: May 11, 2017, 05:45:57 pm »
Hello,

I am sorry for my english.

"PQ Grid" is posting the data as follows when doing multi-processing.
(PQ-Post.jpg)

This is what happens when the answer is returning.
(PQ-response.jpg)

I am using "classic asp" and it is difficult to use "json" along with "classic asp".

My 1. Question:
When I post, can I post like with every line (Omer-Post.JPG)?

2.Question:
I have an area called " Response (Response) prkod ". If this field is returning 0 value, it means that the database operations are successful and it returns 0. (Omer-responseerror.jpg)

If there is an error in the database operations (for example, the credit limit is exceeded, the product is a lot of quantity, such as undefined product code, etc.) (Omer-responsesuccess.jpg)

Can I use the same "update function" , when the performing multiple operations?

if I can not understand the cause, please you must answer for me .

Pictures and Update Function: https://yadi.sk/d/UzERJRR53J3ZRm

The statement that executes "update function".
Code: [Select]
,editorKeyDown : function( event, ui ) {
keyCode = event.keyCode;
//console.log(keyCode);
if (keyCode == 40 || keyCode == 38) {
update(ui.rowIndx, ui.colIndx,keyCode);
}
}


« Last Edit: May 11, 2017, 05:49:31 pm by omerix »

paramvir

  • Administrator
  • Hero Member
  • *****
  • Posts: 6310
    • View Profile
Re: Multi Update
« Reply #1 on: May 12, 2017, 09:36:16 am »
That url doesn't open up from my end. Could you please attach the screenshots in your post itself.

omerix

  • Pro Enterprise
  • Full Member
  • *
  • Posts: 148
    • View Profile
Re: Multi Update
« Reply #2 on: May 12, 2017, 11:25:01 am »
« Last Edit: May 12, 2017, 12:34:47 pm by omerix »

paramvir

  • Administrator
  • Hero Member
  • *****
  • Posts: 6310
    • View Profile
Re: Multi Update
« Reply #3 on: May 15, 2017, 10:19:56 am »
JSON parsing and composition support ( which is present in all modern day languages/ frameworks ) is a must on server side to work with pqgrid.

JSON parsing in classic ASP is discussed here, hope it may be some help to you:

http://stackoverflow.com/questions/1019223/any-good-libraries-for-parsing-json-in-classic-asp

I can't see the Omer-Post.JPG in your list of attachments.

1. Single row editing can be done, which is shown in this demo: https://paramquery.com/pro/demos/editing

2. When error occurs on server side script / database, then you can pass on any custom code/ message to client side javascript XHR response.

When error occurs, you can either rollback the records in pqgrid or show an appropriate message to user to make valid changes in records.