KB-27977: Deleting the records stored in a database.

Question:

How can I delete all the records from a database via E3?

Solution:

To do so, you have to create a Query and, in it, set up the SQL commands to delete all records from the database. These commands will vary according to the database being used.

SQL command for Access:
DELETE *
FROM TableName

SQL command for SQL Server:
DELETE
FROM
TableName

SQL command for Oracle:
DELETE
FROM
TableName

Then, with an application script, just execute this command to run the query.

Example: script being executed in a button’s Click event and running Query2 (set up to delete data from the database):

Screen.Item(“Query2”).Execute(ImmediateExecute)
Print Friendly, PDF & Email

Este artigo foi útil? Was this helpful?

Classificação média - Average rating 0 / 5. Count: 0

Leave a Reply

Your email address will not be published.Required fields are marked *