cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
ShowMeTheAnswer
Level: Powered On

Remove function not workin online, SQL Datasource

Hi,

I added a simple button on my products screen.

It's a screen that has a "datatable" of products.

Required functionality of button:

 - "Deletes" a record from SQL Database Table called [MAIN].

 - (Potentially refreshes the screen as well).

Actual observed functionality of button:
 - Nothing happens.

 

Code is here:

Remove('[dbo].[MAIN]',First(Filter('[dbo].[MAIN]', "KAPMT_ProductDataTable.Selected.MAIN_ID_1"=Text(MAIN_ID) )));Refresh('[dbo].[MAIN]');Refresh('[dbo].[KAPMT_MAIN_VIEW_2]')

 

I have access to delete records in SQL using my Windows Login.

App uses an ID that also has access..any ideas?

1 ACCEPTED SOLUTION

Accepted Solutions
ShowMeTheAnswer
Level: Powered On

Re: Remove function not workin online, SQL Datasource

Fixed it myself:

Remove('[dbo].[MAIN]',First(Filter('[dbo].[MAIN]',MAIN_ID=KAPMT_ProductDataTable.Selected.MAIN_ID)));Refresh('[dbo].[MAIN]');Refresh('[dbo].[KAPMT_MAIN_VIEW_2]')=

Issues

Quotes around this bit:

KAPMT_ProductDataTable.Selected.MAIN_ID
Order seems to matter, datasource column to go first.

1 REPLY 1
ShowMeTheAnswer
Level: Powered On

Re: Remove function not workin online, SQL Datasource

Fixed it myself:

Remove('[dbo].[MAIN]',First(Filter('[dbo].[MAIN]',MAIN_ID=KAPMT_ProductDataTable.Selected.MAIN_ID)));Refresh('[dbo].[MAIN]');Refresh('[dbo].[KAPMT_MAIN_VIEW_2]')=

Issues

Quotes around this bit:

KAPMT_ProductDataTable.Selected.MAIN_ID
Order seems to matter, datasource column to go first.