We are here with you hands in hands to facilitate your learning & don't appreciate the idea of copying or replicating solutions. Read More>>

Looking For Something at vustudents.ning.com? Click Here to Search

www.bit.ly/vucodes

+ Link For Assignments, GDBs & Online Quizzes Solution

www.bit.ly/papersvu

+ Link For Past Papers, Solved MCQs, Short Notes & More

GDB Dated: Aug 06, 15

Dear Students,

 

Note that the Graded Discussion Board (GDB) of CS403 Database Management Systems will remain open for Two days (48 Hours only) from 12:00 AM August 12th, 2015 (Wednesday) to August 13th, 2015 (Thursday) till 11:59 PM according to Pakistan Standard Time.

 

The topic of Graded Discussion Board:

 

Orchid Textile is a large scale organization consisting of hundreds of employees in different office branches across country. HR department decided some new benefits and bonus policies according to pay scale and Designation of employees. So they need to update employees’ relevant record based on specific criteria.  Which indexing technique will be better for above scenario for updation of records?

 

1)      Clustered Indexing

2)      Non- Clustered Indexing

 

Justify your answer with proper reasoning.

 

Note: Try to provide precise (4 to 5 lines only including solid reasons), to the point answer and avoid irrelevant details

 

For any query: CS403@vu.edu.pk

--

Instructor CS403

+ How to Follow the New Added Discussions at Your Mail Address?

+ How to Join Subject Study Groups & Get Helping Material?

+ How to become Top Reputation, Angels, Intellectual, Featured Members & Moderators?

+ VU Students Reserves The Right to Delete Your Profile, If?


See Your Saved Posts Timeline

Views: 5026

.

+ http://bit.ly/vucodes (Link for Assignments, GDBs & Online Quizzes Solution)

+ http://bit.ly/papersvu (Link for Past Papers, Solved MCQs, Short Notes & More)

+ Click Here to Search (Looking For something at vustudents.ning.com?)

+ Click Here To Join (Our facebook study Group)

Replies to This Discussion

y kia hy??

jo solution yahan py upload howa hy, wo sai hy kiya ? Please koe kuch tw btao

http://www.assignmentsolution.net/viewtopic.php?f=9&t=54&p=...

Please Discuss here about this GDB.Thanks
Our main purpose here discussion not just Solution
We are here with you hands in hands to facilitate your learning and do not appreciate the idea of copying or replicating solutions.

I think that the non-cluster model to be used because it give data in blocks so we can make blocks in special criteria or designation.

is it so?

Clustered Indexes

There is only 1 clustered index allowed per table so choose wisely. This index should be the most common column that is in your WHERE clauses for queries against this table. So if most of the time you search by primary key, then leave it as the default. But if you search by DateCreated or LastName most of the time on this table, then you might want to consider changing the clustered index to this column instead.

Some things to remember when using clustered indexes:

  • The reordering of the index occurs every time the index changes (ie: on Updates, Inserts, Deletes).
  • Affects the physical order of data so there can only one clustered index.
  • Keeps the rows in order within a page (8k) of data. The pages are not physically ordered except after an ordered load or re-index based on that cluster.
  • Re-orders the way records in the table are physically stored.
  • Choose this index wisely as there can only be one. Rule of thumb: Apply to a unique, somewhat ordered, and commonly queried column.
  • Like the pages of content in a book. Each page is a collection of data. The order (page numbers 1, 2, 3, etc.) that the data is stored in is controlled by the clustered index.

There a few things to keep in mind when changing the default clustered index in a table:

  1. Lookups from non-clustered indexes must look up the query pointer in the clustered index to get the pointer to the actual data records instead of going directly to the data on disk (usually this performance hit is negligble).
  2. Inserts will be slower because the insert must be added in the exact right place in the clustered index. (NOTE: This does not re-order the data pages. It just inserts the record in the correct order in the page that it corresponds to. Data pages are stored as doubly-linked lists so each page is pointed to by the previous and next. Therefore, it is not important to reorder the pages, just their pointers and that is only in the case where the newly inserted row causes a new data page to be created.)

Best Practices for Clustered Indexes

  • Large amount of selects on a table, create a clustered index on the primary key of the table. Then create non-clustered indexes for all other columns used in selects and searches. Put non-clustered indexes on foreign key/primary key columns that are used in joins.

Non-clustered Indexes

Non-clustered indexes are not copies of the table but a sorting of the columns you specify that "point" back to the data pages in the clustered index. This is why the clustered index you choose is so important because if effects all other indexes.

There are 2 modes for non-clustered indexes, Non-unique and unique. Non-Unique means that the index does not act as a constraint on the table and does not prevent identical rows from being inserted. Unique constraints mean that the index prevents any identical rows from being inserted.

  • Does not re-order the actual table data.
  • Sometimes called a "heap table" for tables lacking clustered indexes because it points to the actual data pages that are essentially unordered and non-indexed.
  • If no clustered index, non-clustered indexes point to the actual data in the table.
  • If clustered index present, non-clustered index point to clustered index.
  • Logical order of the index does not match the physical stored order of the rows on disk.
  • Similar to an index in the back of a book. The actual data is stored in the pages of the book but the index reorders and stores a pointer to each data value.

Best Practices for Non-clustered Indexes

  • Add non-clustered indexes for queries that return smaller result sets. Large results will have to read more table pages anyway so they will not benefit as much from a non-clustered index.
  • Add to columns used in WHERE clauses that return exact matches.
  • If a clustered index is not used on these columns, add an index for collections of distinct values that are commonly queried such as a first and last name column group.
  • Add for all columns grouped together for a given query that is expensive or very common on a large data table.
  • Add to foreign-key columns where joins are common that are not covered by the clustered index.

Indexes are a lot of "trial and error" depending on your database design, SQL queries, and database size.

kia he acha hoota agar aap gdb ka jawab bhe de ddeety

we dont need all this

Waqas explained Clutered Indexes. The purpose of this thread is to discuss, not copy each other's solutions.

My gdb solution file is attach plz check and comments. and plz do not post the same file if u want to post it plz make some changes in the file.

Attachments:

yeh gdb hai ya assgnmnt 

gdb to the point hota apn to itnaaaaaaaaaaaaa zada likh dia

lolz :p

RSS

Latest Activity

Profile IconSiddiq khan kakar, NABEEL AMJAD, Mehreen Awan and 1 more joined Virtual University of Pakistan
5 minutes ago
+ Adeeena replied to + Iuuoɔǝut+'s discussion Aurat ki soch
22 minutes ago
Shine--Ex-VUStudent liked BIA's blog post Totay Bhe Jo Tara Toh Zamee p Nahi Girta.....
25 minutes ago
Shine--Ex-VUStudent liked BIA's blog post Hamari Buri Adaton Main Say Aik Buri Adat. . .
26 minutes ago
Shine--Ex-VUStudent liked + Iuuoɔǝut+'s discussion Tum Theak ja Rhe ho
27 minutes ago
+ Iuuoɔǝut+ replied to + !! SARAH's discussion hahhahahahaha!!!!!!
44 minutes ago
+ Iuuoɔǝut+ replied to + Iuuoɔǝut+'s discussion جیسے جیسے پڑھتے گئے۔۔۔۔۔۔۔ڈوپٹے۔۔۔۔
48 minutes ago
+ Iuuoɔǝut+ liked + Iuuoɔǝut+'s discussion جیسے جیسے پڑھتے گئے۔۔۔۔۔۔۔ڈوپٹے۔۔۔۔
49 minutes ago
+ Iuuoɔǝut+ posted discussions
50 minutes ago
+ ! ! ! ! Noor E Kayenat updated their profile
58 minutes ago
+ Iuuoɔǝut+ replied to + Iuuoɔǝut+'s discussion Mind blowing mehndi design ...
1 hour ago
+ Adeeena replied to + Iuuoɔǝut+'s discussion Mind blowing mehndi design ...
1 hour ago
+ Iuuoɔǝut+ liked + Iuuoɔǝut+'s discussion Mind blowing mehndi design ...
1 hour ago
+ Iuuoɔǝut+ replied to + Iuuoɔǝut+'s discussion Tum Theak ja Rhe ho
1 hour ago
+++Mahoo+++ liked + M.Tariq Malik's discussion Kamyab Jawan Program Prime Minister (Loan) Youth Entrepreneurship Scheme (YES)
2 hours ago
+++Mahoo+++ commented on BIA's blog post Rat Ki Tanhai Main....
2 hours ago
+++Mahoo+++ replied to + !! SARAH's discussion hahhahahahaha!!!!!!
2 hours ago
+++Mahoo+++ replied to +++STUDENT+++'s discussion Allah kin sy muhabat krta ha
2 hours ago
+++Mahoo+++ liked +++STUDENT+++'s discussion Allah kin sy muhabat krta ha
2 hours ago
+++Mahoo+++ liked +++STUDENT+++'s discussion Allah kin sy muhabat krta ha
3 hours ago

© 2019   Created by + M.Tariq Malik.   Powered by

Promote Us  |  Report an Issue  |  Privacy Policy  |  Terms of Service