=UNIQUE(QUERY({IMPORTRANGE("1xWx1FRfvCfmvYi9Sb7Gh5lIAb-NAt0RG0h-e_HKmxjU","APP Directory!A2:U");IMPORTRANGE("1xWx1FRfvCfmvYi9Sb7Gh5lIAb-NAt0RG0h-e_HKmxjU","APP Directory!A2:U")},"Select * Where Col1 is not null order by Col4 Asc",1))

This is what I get as an error:

Unable to parse query string for Function QUERY parameter 2: NO_COLUMN: Col4

  • 2
    Without being able to see the spreadsheet and test things, there is little we can tell you. I also don't understand why you'd have the same range stacked on top of itself, as shown in the formula post.
    – Erik Tyler
    Jan 5 at 1:29
  • 2
    Hi. Would you please edit your question to clarify: 1) Do you have access to this external spreadsheet? 2) what is the data layout in APP Directory!A2:U 3) As mentioned by @ErikTyler, why are you stacking the same data from the same sheet? 4) The error appears to be related to the second of the IMPORTRANGE data sets. If that parameter is removed from the formula, there is no error. Have you tried removing the second query range? 5) The data range (A2:U) covers 21 Columns, but your select and where condition cover only 4 Columns. Why didn't you declare a range of "A2:D"?
    – Tedinoz
    Jan 5 at 3:00
  • hI, I am copying my old system and now is giving that error a friend of mine built it for me and I can't get in touch with anymore.
    – criss
    Jan 13 at 14:29
  • Erik Tyler, someone built me a CRM of Google sheets it is working great for my small business but every year I create a new copy to start fresh again. but I am getting this error. even though it is the same formula that it is working now but when i made a copy gives me that error.
    – criss
    Jan 13 at 14:31

1 Answer 1


Try authorizing the importrange(). In the spreadsheet where you have the issue, put this in a free cell:

=importrange("1xWx1FRfvCfmvYi9Sb7Gh5lIAb-NAt0RG0h-e_HKmxjU", "A1")

Chances are that the new formula cell will display a red corner flag. Click it to authorize the import. After that, your existing formulas that use importrange() should start working as well. You can delete the new formula cell after that.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.