Can you use a slice in a Start Expression? I...

Can you use a slice in a Start Expression?

I have the followingโ€ฆ

This one worksโ€ฆ

straight to the Students table

<<Start: OrderBy(SELECT (Students[Name], [Type of Student]=โ€Fighterโ€), [Name])>>

This one does NOT workโ€ฆ

going to the Active Students slice.

<<Start: OrderBy(SELECT (Active Students[Name], [Type of Student]=โ€Fighterโ€), [Name])>>

Iโ€™m confusedโ€ฆ

0 18 557
18 REPLIES 18

@David_Hopkins

Your current Select does look wrong. It is missing the condition. Try changing it to include a condition. I used โ€œTrueโ€ in the following one.

OrderBy(SELECT (Active Students[Name], true), [Name])

Earlier you specified the following, and it had a condition.

<<Start: OrderBy(SELECT (Active Students[Name], [Type of Student]=โ€Fighterโ€), [Name])>>

@David_Hopkins

Both Start expressions look correct. What error are you seeing?

@Philip_Garrett_Appsh the second wonโ€™t work.

Its a slice but for what ever reason wonโ€™t return anything.

@Philip_Garrett_Appsh

Okโ€ฆ for some reason I thought the condition was optional .

That did the trick!

Way to go Philipโ€ฆ

Really helpfulโ€ฆ

Thank You.

@David_Hopkins

Glad to hear that it is working. I am really impressed with how much you have done!

@Philip_Garrett_Appsh

Iโ€™m a quick studyโ€ฆ and I really love this platformโ€ฆ Iโ€™m building this particular app for one of my trainersโ€ฆ Iโ€™m only building it to get better at AppSheetsโ€ฆ

Thanks again sirโ€ฆ

I really appreciate youโ€ฆ

Great post!

@David_Hopkins

I like the scope of this app, would be very useful in any school to keep better track of the trouble-makers and nip it in the bud!

You should actually be able to build in some formulas and features that would help automate the response, mitigation and even rehabilitation of these troubled kids. Ex. If you add a โ€œFollow upโ€ system to log historical data, even Family data, you would eventually have an amazing tool that could predict/list problems and solutions of new cases that might otherwise be overlooked in the middle of such turmoil.

Imagine entering the details of this mornings fight into your app, all official notifications are sent out, and the school Counselors get a report suggesting that little Jimmy Peters is 1. very likely not getting proper morning nutrition and 2. very likely allowed to stay up until midnight 6 days per week! I would also think that automated preliminary reports like this, based on historical data, might make it easier to get parents to buy in to Counselor recommendations.

@Stephen_Mattison Im not sure thats the intent of this app actuallyโ€ฆ however, what your suggesting might actually be very helpfulโ€ฆ

The premise behind my app is this:

You are an instructor (fitness and Martial Arts in this case) that moves between facilities and needs to track students in multiple classes at multiple locations. Broadcast messages and reminders to a specific individual, class, or facility and the ability to pull payment, status, and progress reports.

Iโ€™m currently building this application simply as a way to learn AppSheets better. One of my fighting trainers is being my Use Case.

@David_Hopkins

Ha!

Silly me!

I was thinking Fighter, Biter, Cryer, Pukerโ€ฆ

Great job getting into AS, looks like youโ€™ve got a great start and very useful app!

LOTS you will be able to do for your niche, and Iโ€™m sure youโ€™ll find lots more niches to explore!

@David_Hopkins I bet the Start expression is fine.

I would trouble shoot the slice.

When you go to the Slice and click โ€œViewโ€ are you seeing the data you expect? Somehow you are filtering out too much of the data.

I use the slice to feed the main entry of the app.

Sup Iโ€™m supposing that its working correctly

@David_Hopkins

Can you clarify what you mean when you says it wonโ€™t return anything? Are you get an email with an empty body or you are not getting an email at all?

If you are not getting any email at all, then you should check Audit History.

@Philip_Garrett_Appsh

I just checked the slice directly in the View Data window and itโ€™s good.

When I set the start to โ€œActive Studentsโ€ the email just never comes.

So I just ran the test again and found thisโ€ฆ

โ€˜OrderBy(SELECT (Active Students[Name]), [Name])โ€™ is invalid due to: SELECT has invalid inputs. Error: Workflow rule โ€˜Active Students Reportโ€™ Start expression โ€˜OrderBy(SELECT (Active Students[Name]), [Name])โ€™ should generate a List of Ref values.

I think Im getting closerโ€ฆ

@Philip_Garrett_Appsh The only difference i can see in the test data for the report is the name of the Table calledโ€ฆ

either โ€œActive Studentsโ€ or โ€œStudentsโ€ โ€ฆ one works, one does not.

Im not sure what โ€œinvalid inputsโ€ the error would be referring to .

@Philip_Garrett_Appsh BTWโ€ฆ

Thank You for your help Philipโ€ฆ itโ€™s much appreciatedโ€ฆ

@David_Hopkins

Can you tell me the workflow rule name and the steps to repro?

@Philip_Garrett_Appsh

Certainlyโ€ฆ

Workflow is โ€œActive Students Reportโ€.

Itโ€™s called from the Menu item โ€œReportsโ€ then โ€œActive Student Reportโ€ and โ€œGenerateโ€ icon.

You can also check out the Active Fighter Reportโ€ฆ they are the same in all ways except Active Fighter sets [Type of Student]=โ€œFighterโ€ in the SELECT statement.

Top Labels in this Space