cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
bonifacious
Frequent Visitor

Syntax Error for ClearCollect

Hello!

 

I am trying to create a collection using filter function:

ClearCollect(Collection1, Filter('[SOURCE].[D_ORG]','Alternative_name' = "X Group"))

The problem is that I get a syntax error:

The requested operation is invalid.
Server response: Syntax Error at position 43 in 'Alternative_x0020_Name' eg "X Group". Inner exception

Any idea how to overcome that?

The source is table in Oracle with VARCHAR2(32 BYTE) format.

 

Update: Seems like it is better to have a column names in format like xxxx and not "xxxx yyy xx" because it is starting to mess with the code.

1 ACCEPTED SOLUTION

Accepted Solutions
Slaverty
Advocate III
Advocate III

Definitely not a casing issue with "Name"?

'Alternative_name' & 'Alternative_x0020_Name' 

Also, I don't think x0020 should be getting substituted in there if it's just an underscore (_) as PowerApps can handle underscores alright.  Best double check your names.

 

Maybe a Oracle DB thing, but also looks like too many brackets and quote marks.

ClearCollect(Collection1, Filter(SOURCE.D_ORG, Alternative_name = "X Group"))

View solution in original post

2 REPLIES 2
Slaverty
Advocate III
Advocate III

Definitely not a casing issue with "Name"?

'Alternative_name' & 'Alternative_x0020_Name' 

Also, I don't think x0020 should be getting substituted in there if it's just an underscore (_) as PowerApps can handle underscores alright.  Best double check your names.

 

Maybe a Oracle DB thing, but also looks like too many brackets and quote marks.

ClearCollect(Collection1, Filter(SOURCE.D_ORG, Alternative_name = "X Group"))

View solution in original post

eka24
Super User
Super User

Please note: Alternative_name is a column name and X Group is in the column name Alternative_name
ClearCollect(Collection1, Filter('[SOURCE].[D_ORG]',Alternative_name = "X Group"))

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

Top Solution Authors
Top Kudoed Authors
Users online (1,244)