cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
tbabe12
Helper I
Helper I

Add new column from a different data source

Hi, i am. trying to add a column from another datasource to my datatable, but my syntax keeps giving me the below error message

2 ACCEPTED SOLUTIONS

Accepted Solutions
WarrenBelz
Super User
Super User

Hi @tbabe12 ,

I may not have this exactly correct, but you do not need the As statement and you need to add the field name from the Jobs lists you are adding.

Search(
   AddColumns(
      WorkOrders,
      "Jobs”, 
      LookUp(
         Jobs, 
         job_addressl_Columnl = job_addressl
      ).YourFieldName     //need the field to add
   ),
   searchQuering,
   "job_addressl"
)

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

 

 

View solution in original post

What type of visual is job_address1_Column1?  If it is a textbox, it should be job_address1_Column1.Text.  The easiest way to figure out what should go there is to press a period and see what the system suggests.  If it says job_address1_column1.Selected  you will need to press the period one more time and do it again. 

View solution in original post

17 REPLIES 17
WarrenBelz
Super User
Super User

Hi @tbabe12 ,

I may not have this exactly correct, but you do not need the As statement and you need to add the field name from the Jobs lists you are adding.

Search(
   AddColumns(
      WorkOrders,
      "Jobs”, 
      LookUp(
         Jobs, 
         job_addressl_Columnl = job_addressl
      ).YourFieldName     //need the field to add
   ),
   searchQuering,
   "job_addressl"
)

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

 

 

View solution in original post

tbabe12
Helper I
Helper I

Thank you, i tried the syntax provided but still got errors, guess i am not doing something right

@tbabe12 ,

Firstly, you have double quotes around job_addressl_Column1, which you do not need and I also noticed not you have a list and field name (jobs) the same - not good practice. Also Search() does not seem to like working outside and AddColumns function (I have now properly tested the syntax), so try this

Filter(
   AddColumns(
      WorkOrders,
      "JobNotes",
      LookUp(
         Jobs,
         job_address1_Column_1 = job_address1
      ).job_Notes
   ),
   searchQuering in job_address1
)

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

 

 

the datasource i am trying to add is Jobs, and the field names are job_Notes and job_warrantydate_closed

tbabe12
Helper I
Helper I

hi, its me again😊.. just wondering what the reason for the error is..i am trying to add two columns (job_Notes and Job_warantyDate) from Jobs table to WorkOrder Table(Datatable). Thanks for your help and patient so far i am new to powerapps..

What type of visual is job_address1_Column1?  If it is a textbox, it should be job_address1_Column1.Text.  The easiest way to figure out what should go there is to press a period and see what the system suggests.  If it says job_address1_column1.Selected  you will need to press the period one more time and do it again. 

View solution in original post

Filter(
AddColumns(
WorkOrders,
"JobNotes",
LookUp(
Jobs,
job_address1_Column1.FieldDisplayName = job_address1
).job_Notes
),
searchQuering in job_address1
)

 

searchQuerying happen to be a variable i created for the search box, but using this filter, i can not search for my job_address, as the field is empty, also the jobnotes field is empty too.  my question is , i am wondering why my job_address field and Job notes field are not showing values and also why i can not search using address.. thanks

@dyee ,

You might give me a chance to respond in my time zone (UTC +10)

I'm confused.  What are you talking about?

Helpful resources

Announcements
User Group Leader Meeting January 768x460.png

Calling all User Group Leaders!

Don't miss the User Group Leader meetings on January, 24th & 25th, 2022.

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

Top Solution Authors
Top Kudoed Authors
Users online (2,759)