anyone….on my question about change columns…?
# suitescript
j
anyone….on my question about change columns…?
b
should be very possible
you load the search then set the columns then save the search
j
but it doesn’t save the new columns
next time I load it, it’s back to the old columns
b
what did your example look like?
j
wtf…now it’s working
I tried like 4 times with both ss1 and ss2
Copy code
var ws_search = search.load({id: 'customsearch_ws_columns_search2'});

var columns = [];

/* do stuff in here to add columns */

ws_search.columns = columns;

ws_search.save();
was essentially the above
r
how are you adding the columns?
b
ws_search.columns = columns;
anyways, what is columns equal to?
your code looks fine
j
yeah not sure why it wasn’t working before
¯\_(ツ)_/¯
to be fair I’m trying to find the “breaking point” of the search
I have a search that does an UNEXPECTED ERROR when I try to load it, and I think it’s cuz it has too many columns
this is what I’m trying to find out
incrementally adding columns till it breaks
b
"why is the code im trying to break not working"
j
well no. I had a search that was fine. Was trying to add columns to it.
nothing was happening.
from 25 to 30 columns should not break
a
I have search with up to 70 columns I think...
j
yeah I have one with like 300 and it’s fine
a
Uff 300 columns...
j
my custom record has ~700 columns
….sigh
a
Jesus...
j
yeah it’s super fun to work with
thanks for your help. Gonna chalk this one up to temporary NS weirdness