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

The property expects Table values, but this rule produces incompatible Boolean values

Below are links to two screen prints. They are for a PowerApp using the new barcode scanner. The purpose of the app is to scan a book's ISBN, then get information from a database and return information about the book. The Swagger file results in a successful response (see image at link).

 

Issue 1: I have two instances of the app saved. One is shared and the other is not. When I try to load the unshared instance for editing, the "Downloading" overlay appears and never completes loading the app in edit mode. The shared instance loads for editing. Is there a way to "unshare" to permit additional edits? Or is something else causing the problem?

 

Issue 2: If the Items property of Gallery1 is set to 'BookByISBN2.txt'.GetISBNSearch(Scanned_ISBN), the result is "The property expects Table values, but this rule produces incompatible Boolean values". If I replace "Scanned_ISBN" with an actual ISBN, the same message appears. How can this Items statement be corrected? The intent is to scan an ISBN, search the database for that ISBN, then return it to Gallery1.

 

Issue 3: When scanning the barcode in PowerApps online, the image is rotated 90 degrees and scanning does not work (at least not well).  When using PowerApps Studio, the barcode scanning image does NOT rotate (it is oriented properly and scanning works). This issue has been reported previously in the " scanning" Ideas section of the PowerApps Community. I assume this has been identified for a fix by the PA Team.

 

Any help will be very much appreciated!

Swagger File Is Valid

Gallery1 Items Statement

25 REPLIES 25

This might be what you need:

000-Request and Response Header on Swagger Event.png

 

Created a Swagger file for the WorldCat ISBN search and made a connection with it in PA. I have now tried with two different APIs and the corresponding files I created, both of which respond successfully in the Swagger Editor but result in PA errors that are similar, but different. This second file leads to an "Internal Server Error" in PowerApps (see below). Any ideas on how to fix this will be most appreciated!

 

[FYI- I have made connections in App Studio using these APIs with the Custom API connector in App Studio and they work well, but of course there is no way to pass a value (ISBN) to the query and now way to use the data once returned.] So I'd really like to get this working in PowerApps.

 

I realized after preparing the screen shots two ISBNs are shown in the screen prints below. This does not make a difference in the resulting error, however. One is a 10-digit ISBN, the other a 13-digit ISBN. Sorry about that.

 

Here is the second Swagger file used in PowerApps:

Swagger Part ASwagger Part ASwagger Part BSwagger Part B

The Swagger editor response is shown below:

Swagger Editor Response Part ASwagger Editor Response Part ASwagger Editor Response Part BSwagger Editor Response Part BSwagger Editor Response Part CSwagger Editor Response Part C

The PowerApps Error Message is shown below:

001-WorldCatISBNAPAError.png

...And the Fiddler Trace...

001-WorldCatISBNAFiddlerGet&Response.png

Unfortunately, Swagger 2.0 does not allow query strings in paths.

See the following on reasons why this is the case: Proposal: Querystring in Path Specification

 

You can see this by the fact that the '?' char in your path is being escaped (per url escaping protocol). Also, there is likely a weird thing going on with connectors which is possibly masking the actual problem. But this is definately the cause of the problem. In all likelyhood, the connector is passing to your service a url which is further messed up.

 

You should fix your paths to be Swagger compliant.

I have filed a task on our plate to detect this scenario and to reject any Swaggers that contain the '?' char in the path string.

 

One thing that you'll hit though is that you'll have to actually specify the parameters with no values. This is unfortunate as you'll have to specify the parameters in the rules. But first thing is to be explicit. I'd recommend specifying the parameter as type:"string" for now and just specifying "json" in the function call to unblock you.

View solution in original post

Frequent Visitor

Hello Team,

 

I have created a custom connector which read the multiple items bases on business logic from sharepoint lists.

 

No i have call connector from the power app and it gives me error that "The property expects the table values but this rules produces in compatiable values."

But when i ran the connector from test page it will generate json records as below.

 

[{\"odata.type\":\"SP.Data.InvoiceapprovaltasksListItem\",\"odata.id\":\"4d5eb3aa-f285-48f6-90e0-32514b5177f6\",\"odata.etag\":\"\\\"3\\\"\",\"odata.editLink\":\"Web/Lists(guid'6d41d1bb-b5a0-42e6-a723-2b0ea2ccf7fe')/Items(334)\",\"TestInvoiceUniqueRefID@odata.navigationLinkUrl\":\"Web/Lists(guid'6d41d1bb-b5a0-42e6-a723-2b0ea2ccf7fe')/Items(334)/TestInvoiceUniqueRefID\",\"TestInvoiceUniqueRefID\":{\"odata.type\":\"SP.Data.InvoicetrackerListItem\",\"odata.id\":\"3b82e4a6-c9b2-4480-970e-6f7d6795cfed\",\"TestInvoiceUniqueID\":\"Invoice000326\",\"TestInvoiceNumber\":\"1\",\"TestTotalGrossValue\":500000.0,\"TestVendorName\":\"GHD PTY LTD\",\"TestGeneratedPrNo\":null,\"TestInvoiceDate\":\"2017-11-30T18:30:00Z\"},\"Id\":334,\"ID\":334}]""

 

How can i convert it in table format as power App read only table records and function also work on table records?

How can i generate table values from Custom API?

 

As i have observed that when we connect sharepoint as data soure it returns the table value from lists.

 

Can anyone help me out ?

 

Thanks

Dipen 

I think @jneyses has found a solution in this post.

He should be publishing more details in the next few days to that post.

Helpful resources

Announcements
News & Announcements

Community Blog

Stay up tp date on the latest blogs and activities in the community News & Announcements.

Power Apps Community Call

Power Apps Community Call- January

Check out the Power Apps Community Call for January 2021

PP Bootcamp Carousel

Global Power Platform Bootcamp

Dive into the Power Platform stack with hands-on sessions and labs, virtually delivered to you by experts and community leaders.

secondImage

Power Platform Community Conference On Demand

Watch Nick Doelman's session from the 2020 Power Platform Community Conference on demand!

Top Solution Authors
Top Kudoed Authors
Users online (3,727)