so i'm using an inMemory tmp table inside a loop.
1. what would be the difference if i clear the tmp table at the beginning of the loop or i use delete_From?
2. and does in memory tables save values until the loop ends while tmpDB tables still save the value after the while loop?
Hi JuniorAX,
1. Could you, please, explain what do you mean "clear tmp table"?
2. The difference is only where data is stored: in memory (or disk) or in temp table in DB.
Hi Junior AX
The clear() method is to clear the fields in the current record. The delete_from keyword is for a set based SQL delete. So using delete_from in the beginning of your statement will not make sense.
And then the difference between InMemory and TempDB - docs.microsoft.com/.../temporary-inmemory-tables
As mentioned by Pete, calling .clear() clears the current table buffer.
Delete_from statement deletes records from the database (or wherever they are stored).
These statements work exactly the same with normal or temp tables.
Both types of temp tables (InMemory and TempDB) retain the data until the table buffer variable goes out of scope.
For example if you introduce the temp table buffer variable in a method, the data disappears after the method has been executed.
Or if you introduce the variable inside a loop, the data only exists until that particular loop iteration is completed.
Under review
Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.
As AI tools become more common, we’re introducing a Responsible AI Use…
We are honored to recognize Abhilash Warrier as our Community Spotlight honoree for…
These are the community rock stars!
Stay up to date on forum activity by subscribing.
CA Neeraj Kumar 2,167
André Arnaud de Cal... 867 Super User 2025 Season 2
Sohaib Cheema 617 User Group Leader