Api return only selected column

Hello everyone,
there is any API for get only selected column data as like in my collections have 50 column but i want only 30 selected column some column i want to avoid,
is this possible please help me.

thanks in advance

Hi @mizanvai, I seem to have answered this with your other question:

2 Likes

thank you @Josh

2 Likes

My form has 159 questions. I would also like to specify the columns to download. Before I commit in doing this, is there a limit to the length of the URL? I can only imagine the length of the URL if I specify the names of 100 columns. Thanks.

https://kc.humanitarianresponse.info/api/v1/data/formid?fields=[%22start%22,%22end%22,%22today%22,” + “%22username%22,%22simserial%22,%22subscriberid%22,%22deviceid%22,%22phonenumber%22,%22_1_Camp%22,%22group_cc8xg51/_1_1_Majhi_Name%22,” +"%22group_od9qu80/_2_1_Husband_Father_s_Name%22,%22group_od9qu80/_2_2_This_family_is_Female_headed_family%22," +
“%22group_od9qu80/2_3_Mobile%22,%22group_od9qu80/Male_1_18%22,%22group_od9qu80/Female_1_18%22,%22group_od9qu80/Male_18%22,” +…]

it will be so long min

10 line

of code for 100 field.

thanks. Have you encountered a limit to the length of the URL? Can I do this with 100 columns?

i have done for 140 columns.

thanks. okay, will try to download selected columns only

Hi @raffy_m, are you trying to download the data as a CSV/XLS file or as JSON?

1 Like

i will be downloading as JSON. But if there is way to download as Excel, I would like to know how this is done too. Thanks