Announcements
No record found.
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.
Congratulations to our 2026 Super Stars!
Thanks to all of our 2025 Community Spotlight stars!
These are the community rock stars!
Stay up to date on forum activity by subscribing.
André Arnaud de Cal... 514 Super User 2026 Season 1
Giorgio Bonacorsi 390
Adis 266 Super User 2026 Season 1