locked
Uncaught RangeError: Maximum call stack size exceeded RRS feed

  • Question

  • User-1634604574 posted

    i will send this array into the db number of rows are 8000 i have this error

    Uncaught RangeError: Maximum call stack size exceeded

    var AddressesDataJSON = $("#tb_customer").find('input').serializeArray();
    console.log(AddressesDataJSON.length);
    // alert(JSON.stringify(AddressesDataJSON));
    $.ajax({
    url: "/Selling_Customer/INSERT_Customer_Import",
    type: "POST",
    data: JSON.stringify(AddressesDataJSON),
    contentType: "application/json; charset=utf-8",
    dataType: "json",
    error: function (response) {
    // alert(response.responseText);
    },
    success: function (response) {
    }
    })

    how can i solve it?

    Sunday, June 2, 2019 8:28 AM

All replies

  • User475983607 posted

    i will send this array into the db number of rows are 8000 i have this error

    Uncaught RangeError: Maximum call stack size exceeded

    var AddressesDataJSON = $("#tb_customer").find('input').serializeArray();
    console.log(AddressesDataJSON.length);
    // alert(JSON.stringify(AddressesDataJSON));
    $.ajax({
    url: "/Selling_Customer/INSERT_Customer_Import",
    type: "POST",
    data: JSON.stringify(AddressesDataJSON),
    contentType: "application/json; charset=utf-8",
    dataType: "json",
    error: function (response) {
    // alert(response.responseText);
    },
    success: function (response) {
    }
    })

    how can i solve it?

    Where is the data coming form?  If this data exists on your server then copying it to the browser and having a user edit 8000 records seems odd at best.

    Can you explain at a high level the problem you are trying to solve?

    Sunday, June 2, 2019 11:26 AM
  • User839733648 posted

    Hi zhyanadil.it@gmail.com,

    zhyanadil.it@gmail.com

    Uncaught RangeError: Maximum call stack size exceeded

    The error you get is one that $.ajax will generate if you try to pass a structure that has circular references in it.

    I suggest that you could use F12 developer tools to check where does the error occur.

    If the error appears at $.ajax, I think that there is something wrong with the data.

    If the data definition type is incorrect, the data cannot be successfully sent to the background.

    The background does not receive the data, the front end is always sent, and the loop causes the stack to overflow.

    You could check that if the parameters in ajax is right.

    Best Regards,

    Jenifer

    Monday, June 3, 2019 6:57 AM