The Student Room Group

Scroll to see replies

Original post by Amirrryy
yea i know how to create a primary key, but when does the primary key compose of TWO or even THREE attributes rather than the usual one? (i.e. composite keys)


Say you're creating a database for a library where a book cannot be returned the same day that it is borrowed. This allows you to have a loans table where the primary key is the copy of the book and the date that it is borrowed. We know that, because each book copy has a unique ID, there is no chance of a non-unique primary key therefore it is not worth creating a new column.

To ensure that this relation is normalised, every attribute must be dependent on the whole of the key (2NF says that there should be no partial key dependencies.)

Composite keys can also appear when taking a table into 1NF (see the textbook).
Reply 221
Original post by Edwin Okli
Say you're creating a database for a library where a book cannot be returned the same day that it is borrowed. This allows you to have a loans table where the primary key is the copy of the book and the date that it is borrowed. We know that, because each book copy has a unique ID, there is no chance of a non-unique primary key therefore it is not worth creating a new column.

To ensure that this relation is normalised, every attribute must be dependent on the whole of the key (2NF says that there should be no partial key dependencies.)

Composite keys can also appear when taking a table into 1NF (see the textbook).


thanks man i understand it a bit more now :smile:
Original post by exam2k10
BTW, how screwed am I and am I the only one feeling a bit nervous?


Nope, I'm really worried about this exam too. I'm pretty confident on most of the main material, but all it takes is for them to ask a string of questions based around relatively obscure topics in the textbook for you to end up losing a large number of marks.

My revision plan is pretty much exactly the same as yours; get some past paper questions done, do a full past paper, then go over all my revision notes.
(edited 11 years ago)
Reply 223
can switches be used for bus networks? or is a bus network with a switch the same thing as a star network? confused :s-smilie:
Reply 224
can someone help me how to do this q as well thanks

comp3_517.jpg
Reply 225
Original post by Amirrryy
can switches be used for bus networks? or is a bus network with a switch the same thing as a star network? confused :s-smilie:

switched Ethernet Looks like a star but behaves like a bus. It sends frames by creating a temporary connection between the reciever and transmitter of a frame. To avoid collisions it buffers frames by placing them in a queue

This was posted from The Student Room's Android App on my Nexus S
Reply 226
Original post by exe
switched Ethernet Looks like a star but behaves like a bus. It sends frames by creating a temporary connection between the reciever and transmitter of a frame. To avoid collisions it buffers frames by placing them in a queue

This was posted from The Student Room's Android App on my Nexus S


isnt that the same as a star?? or is it just an improved bus network then?
Reply 227
Original post by Amirrryy
isnt that the same as a star?? or is it just an improved bus network then?


Topology: Star
Behaviour: Bus

:smile:
Original post by SecondHand
Think about what happens in each case if some information about the coin changes or if some information about the supplier changes. Think about it first and then I will explain if you are still stuck.


Ok right so because CoinID is unique to each coin if you added more CoinID's to the table then you'd keep repeating supplierID. And in the supplier table the supplier supplies loads of coins then it's not unique so CoinID is added? Wait that's wrong. Argh I'm still stuck.
Reply 229
Original post by Yash13
Topology: Star
Behaviour: Bus

:smile:


ok to get this straight then lol a bus with a switch is a star
Reply 230
Its a star because the switch is connected by unique cables to each node/computer. It's a bus because of the way it handles connections, ie. it uses a backbone
Reply 231
A single network can have multiple topologies.


This was posted from The Student Room's iPhone/iPad App
Reply 232
can someone please tell me the answer to part b... why cant the printer be directly connected to the switch? in the ms it says the printer has to be connected to a computer which is connected to the switch not directly to the switch...is that always the case or just for "Peer to peer" networks or what? :L

many thanks in advance


comp3_578.jpg
Reply 233
Original post by Amirrryy
can someone please tell me the answer to part b... why cant the printer be directly connected to the switch? in the ms it says the printer has to be connected to a computer which is connected to the switch not directly to the switch...is that always the case or just for "Peer to peer" networks or what? :L

many thanks in advance


comp3_578.jpg

Yeah, I didn't really understand that either. I think its because you can't set up the printer as a standalone node on older printers and thats from the old spec
Original post by BalletDystopia
Ok right so because CoinID is unique to each coin if you added more CoinID's to the table then you'd keep repeating supplierID. And in the supplier table the supplier supplies loads of coins then it's not unique so CoinID is added? Wait that's wrong. Argh I'm still stuck.


Case 1: A coin has 1 supplier and suppliers can supply many coins - Supplier ID in the Coin table
Case2: A coin can have many suppliers but each supplier can only supply 1 coin - CoinID in supplier table
Case 3: A coin can have many suppliers and suppliers can store more than 1 coin - You need a table in the middle or the Coin table and the Supplier Table which only holds the link between the two tables (as to break the many to many relationship)


In case 1: If you don't have separate tables then when the supplier changes you have to change the supplier details in every coin.

Case 2: If information about a coin changes then you have to change information about the coin many times

Case 3: If either changes then you would have to change all the records if the tables were not set up properly.

Normalisation minimises repeated data and safeguards for the future by removing the need to update in multiple places.

Original post by Amirrryy
can someone please tell me the answer to part b... why cant the printer be directly connected to the switch? in the ms it says the printer has to be connected to a computer which is connected to the switch not directly to the switch...is that always the case or just for "Peer to peer" networks or what? :L

many thanks in advance


comp3_578.jpg


Is it not because in a peer to peer network there are no central servers, for the printer to be directly connected to the switch there would need to be a print server which handled printing requests. In a peer to peer network each terminal is both the client and the server hence the printer must be connected to one of them.
Reply 235
Original post by SecondHand
In case 1: If you don't have separate tables then when the supplier changes you have to change the supplier details in every coin.

Case 2: If information about a coin changes then you have to change information about the coin many times

Case 3: If either changes then you would have to change all the records if the tables were not set up properly.

Normalisation minimises repeated data and safeguards for the future by removing the need to update in multiple places.



Is it not because in a peer to peer network there are no central servers, for the printer to be directly connected to the switch there would need to be a print server which handled printing requests. In a peer to peer network each terminal is both the client and the server hence the printer must be connected to one of them.


i think it can be connected directly :/ i dont see why not. If each is a server and client on its own then surely a printer can be a server on its own too...unless workstations only mean computers and not printers but i think workstations stands for computer and peripherals which in this case is a printer...so i think it can be but this is old spec. am i correct?
Reply 236
i think its cause the printer only acts a server and not a client in that kind of network, i guess.. my printer is connected to the network though so it seems kind of a poitnless distinction to me
I have a feeling the 6 marker may have something to do with Operating Systems, and choosing the correct OS, or attributes from more than 1 OS for a particular Situation, and an explanation as to why you chose those attributes.
Reply 238
I think this paper will have a few high markers such as OS, encryption+ use of public keys and private keys and maybe firewalls. May well also have stuff on network adapters (which I know nothing about).
As for the rest, well real numbers will be in it, SQL + Database will be in it, but I really think binary tree traversal will be in it as it requires a stack or if not a recursive function. Also hashing may be another possibility if not the insertion sort will since it has not come up before. Need 70/100 for an A which I will be so proud of, if I do get it.
Reply 239
Original post by exe
i think its cause the printer only acts a server and not a client in that kind of network, i guess.. my printer is connected to the network though so it seems kind of a poitnless distinction to me


same..thanks

Latest

Trending

Trending