Table Key

Get our Free Newletter

Don't you have the time to be online here at DUG every day? So how do you follow what is going on in the Dynamics industry and community?
If you subscribe to the DUG Newsletter then you can relax! We will make sure that you don't miss the big news!

Check out our
Newsletter Subscription Center
page a complete list of our different newsletters.

Not Answered This post has 0 verified solutions | 6 Replies | 1 Follower

Male
26 Posts
360 Points
Joined: 2011-4-25
Last Online:
2013-3-4 11:35
Location: India
Mrinal Singha posted on 2012-9-1 8:06

How many keys can be created on a Table ??

Mrinal Singha | Technical Consultant

Samadhan

Skype ID : mrinal-samadhan

All Replies

3,998 Posts
87,685 Points
Joined: 2009-2-17
Last Online:
2013-5-24 17:53
Location: New Delhi
DynamicsNAVMVP
Moderator
Mohana replied on 2012-9-1 8:22

Key can have 16 fields and should not exceed 252 Bytes in SQL.

Male
2,228 Posts
32,855 Points
Joined: 2006-4-10
Last Online:
2013-5-24 12:05
Location: Pune India
Moderator
Amol replied on 2012-9-2 5:33

Maximum 40 Keys on a table.

 

-Amol

http://dynamicsuser.net/blogs/amol

Don't forget to  the post(s) that solved your problem

Male
630 Posts
8,890 Points
Joined: 2005-11-6
Last Online:
2013-5-24 11:56
Location: Norwell, MA, USA
babrown replied on 2012-9-4 1:45

Give careful thought to why you would need so many indexes.  Remember they are a double-edged sword.  While keys can improve data access (read performance) the trade-off is a negative impact to write performance.  The goal is to decide the right balance for your system.

 

 

Male
26 Posts
360 Points
Joined: 2011-4-25
Last Online:
2013-3-4 11:35
Location: India
Mrinal Singha replied on 2012-9-6 16:00

Please detail it's negative impact, as many keys are created on table according to report's requirements.

Does it impact indexes ?

Mrinal Singha | Technical Consultant

Samadhan

Skype ID : mrinal-samadhan

Male
2,228 Posts
32,855 Points
Joined: 2006-4-10
Last Online:
2013-5-24 12:05
Location: Pune India
Moderator
Amol replied on 2012-9-6 17:01

Keys are Indexes and of course it will impact your DB performance.

-Amol

http://dynamicsuser.net/blogs/amol

Don't forget to  the post(s) that solved your problem

Male
2,636 Posts
37,350 Points
Joined: 2004-1-23
Last Online:
2013-5-24 21:44
Location: Howell, MI
DynamicsNAVMVP
Moderator
DenSter replied on 2012-9-6 20:21

Amol:
Keys are Indexes

No that is not true.

A key in the NAV table designer is a sort order. you must have a key in order to be able to sort in NAV.

An index in SQL Server is also a sort order, but it is mostly used by SQL Server to be more efficient at retrieving records from the database.

By default, when you create a key in the NAV table designer, it creates an index for the same fields (plus the primary key fields to make the index unique). You can completely disable the SQL Server index by unchecking the MaintainSQLIndex property of the key. You can modify the SQL Server index by specifying the fields in the SQLIndex property (which is not recommended for version 5.0 SP1 and higher).

A key is most definitely NOT the same thing as an index.

Daniel Rimmelzwaan
RIS Plus - MVP

Page 1 of 1 (7 items) | Get this RSS feed | Bookmark and Share