Dex - Ctree temp tables versus SQL Server temp tables

For many of you who have been in the channel long enough, whether as developers, partners, or customers and have been using GP for that long, you may still be able to remember the days of c-tree and Btrieve.

Just recently, a developer approached my good friend David Musgrave with a question on a product they had created and been using since the days of GP 6.0. This product makes extensive use of c-tree temp tables and the developer wanted to know whether it was still ok to continue using c-tree tables or convert those to SQL Server temp tables. He received the following answer:


There is nothing wrong with c-tree temp tables. They are faster. SQL Temp tables take a bit of work to create so ctree has less overhead.

The only reasons to change them back to Default or SQL are:

1) You are using them on a report. This allows SQL optimization when generating the report with a single SQL Joined query.
2) You want to use SQL optimized functions such as range where clauses or range copy.
3) The number of records being placed in the temp table is huge and it could cause a local workstation’s hard disk to fill up.

Otherwise, just leave them as is. My policy is to use ctree unless one of the points above says that SQL would be better.

To add to this response, c-tree temp tables are still supported by Microsoft and are used extensively throughout the Microsoft Dynamics GP application. In the end, this may be one of those cases of "if it ain't broken don't fix it".

Until next post!

MG.-
Mariano Gomez, MVP
Maximum Global Business, LLC
http://www.maximumglobalbusiness.com/

Comments

Popular posts from this blog

Power Apps - Application Monitoring with Azure Application Insights

DBMS: 12 Microsoft Dynamics GP: 0 error when updating to Microsoft Dynamics GP 2013 R2

eConnect Integration Service for Microsoft Dynamics GP 2010