I am new to Devart and need to know what to buy

Discussion of open issues, suggestions and bugs regarding SDAC (SQL Server Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
syscwl
Posts: 13
Joined: Mon 03 Oct 2011 17:44

I am new to Devart and need to know what to buy

Post by syscwl » Mon 15 Jan 2018 12:40

I am using C++Bldr Tokyo , latest version, and SQL SVR 2017[latest version]. I need a component that will provide a table connection/access to SQLSVR that will allow me to use the Indexes associated with that table. Embarcadero says I need to buy their FireDAC component to do that. The stock TADOTable does not honor SQL SVR indexes when accessing the table.

Does the Devart DAC Table component honor table indexes, in other words can you open a table using an index and retrieve the data in the index order?

Stellar
Devart Team
Posts: 496
Joined: Tue 03 Oct 2017 11:00

Re: I am new to Devart and need to know what to buy

Post by Stellar » Tue 16 Jan 2018 11:43

SQL Server automatically uses server indexes when executing SQL query on the server side. By adding an index to the Field_Name field, and sorting by field to the ORDER BY Field_Name query, SQL Server will build a query execution plan in such a way that the index will be used to sort the data.
If you are not satisfied with the automatically generated query execution plan, you can try changing the behavior of SQL Server when building a query execution plan by adding hints to the query.

More details about Hints: https://docs.microsoft.com/en-us/sql/t- ... ansact-sql

syscwl
Posts: 13
Joined: Mon 03 Oct 2011 17:44

Re: I am new to Devart and need to know what to buy

Post by syscwl » Tue 16 Jan 2018 12:03

Stellar I'm using TADOTable component which is a table access...there is no SQL plan...you open a table ...in the table properties you specify an index, opening the table and accessing the data should expose a index related sorted presentation...TADOTable standard does not unlesd you buy the Embarc FireDAC components...so my question was "Does the Table access component for DAC SQL SVR honor the index when I begin pulling records from the table".

Please respond.

Stellar
Devart Team
Posts: 496
Joined: Tue 03 Oct 2017 11:00

Re: I am new to Devart and need to know what to buy

Post by Stellar » Wed 17 Jan 2018 14:27

SQL Server does not allow you to use server indexes directly. If you need to get the sorted table data to TMSTable, you can specify the fields by which you want to sort the records in the OrderFields property. The server will automatically build a query execution plan in such a way that the index will be used to sort the data, if it exists.

Post Reply