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

Deep Linking SQL

Hello,

 

I have an application I built where I am using the deep linking function.

 

PowerApps Deep Linking - Send a direct link to a specific record/screen in your app with parameters ...

 

I originally was using SharePoint as a data source, but have recently moved over to SQL. When doing so I have experienced an issue with the form when the user is directed there. For some reason, it keeps getting stuck on "Getting your data." I'm assuming this is something pretty simple that I'm overlooking, but wanted to know if someone could help out.

 

For the Items property of the form I am using the following:

 

LookUp(SQLSource, Notification_ID=varRecord.Notification_ID)

 

When selecting the Gallery Item:

 

Set(varRecord, ThisItem)

 

And for OnStart of the application:

 

Set(
varRecordID,
Value(Param("RecordID"))
);
If (
varRecordID <> 0,
Set(
varRecord,
LookUp(
SQLSource,
Notification_ID = varRecordID
)
)
);
If(
Param("ScreenName") = "TestScreen",
Navigate(TestScreen),
false
);

 

 

5 REPLIES 5
DSut
Advocate I
Advocate I

Hi @cperry07 ,

Try changing the items property of the form to your varRecord variable.

It looks to me like you've already set the variable to the record via the on start or gallery selected item functions so there's no need to look it up again. 

Still getting the "Getting Your Data"

Only other thought is that you have multiple records in your variable when a deep link is used.

I.e. You might have duplicate values in you SQL Notification_ID column.

Does it work when navigating from a gallery selection where the varRecord is set to ThisItem?

If it does then check the variable to make sure it has a single record when using a deep link or Try adding First(varRecord) to the form items property to test for multiple records.

I haven't used the SQL connector before so if that doesn't work then hopefully someone else who has SQL experience can assist.

timl
Super User
Super User

Hi @cperry07 

To diagnose this further, here are a couple of things that I would try. If you add a label and set the text property to the following, does it display the correct notification ID?

 

varRecord.Notification_ID

 

Also, if you were to set the items property of the form so that it looks up the record based on the record ID variable, does your form still get stuck on "Getting your data."?

 

LookUp(SQLSource, Notification_ID=varRecordID)

 

 

cperry07
Helper I
Helper I

OK

@timl @DSut 

 

Well this is embarrassing. I copied some of the coding over from the SharePoint application I had built over and forgot to update the URL to the new application LOL. So it works now HAHAHA. Thank you for your help guys

Helpful resources

Announcements
2022 Release Wave 1 760x460.png

2022 Release Wave 1 Plan

Power Platform release plan for the 2022 release wave 1 describes all new features releasing from April 2022 through September 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 (1,178)