Posts

Showing posts from January, 2023

CST 363 - Week 4

 5 Things Learned So Far How to create tables and insert data into them Creating an EER using MySQL Workbench Using forward and reverse engineering in MySQL Workbench to create and view EER diagrams Quires to display the desired information on one or many combined tables Use views to better organize subqueries. 3 Questions How and where are large-scale databases deployed (ie. on remote servers, local PCs, etc.) How to create the front end of the database that clients would use What happens when an already populated database, with much information, has to be transferred to a new iteration of that database?

CST 363 - Week 3

Normalization in database design refers to the techniques used when designing the database to avoid redundant data and possibly anomalies when updating and deleting data from the database.  The third normalization form says to not store redundant data and that redundant data can be found through functional dependencies.  It should be noted that when designing a database using a top-down design and an ER model, the tables will usually be normalized by their design.  Using a bottom-up design such as being given a CSV of all the data to be entered into a database, with no explanation or guidance, redundancy tends to occur.  An example of why the third normalization is good was demonstrated in our assignment this week.  We had tables for products and related tables for PCs, laptops, and printers.  If all of these tables were in one table and not split up between their respective dependent key then there would exist redundant data.  Speed for PCs and laptop...

CST 363 - Week 2

CST 363: Week 2 The most common technique of joining tables in SQL is to join the primary key of one table to the foreign key of another table.  There might only sometimes be a key relationship between the two tables though.  Or, the desired return is purposely not using a primary key or foreign key to join the tables.  An example of this is joining data of one table (A) with additional data that relates from another table (B).  The same data type might have been stored in two different tables and the user wishes to have them together.  To do this you can do,     SELECT A.col, B.col     FROM A     LEFT JOIN (SELECT DISTINCT col FROM B)     ON A.col = B.col This will combine the data into one table and exclude duplicate data that might have appeared in both tables. So far, SQL is an interesting language to learn.  I find it easier to learn than OOP languages because it uses English.  With that being said it is sti...

Week 1

  Relational database tables and spreadsheets look very similar, containing rows and columns.  What makes a relational database different is the word relation.  Unlike a spreadsheet that can have any data type with any meaning in any row/column, a relational database makes relations with the fields.  The relations made within a table and with other tables allow the data to be stored, searched, and edited without losing the relation. Using a database instead of just saving files has many advantages.  One advantage is all the data you wish to save is gathered and saved together.  Now the person looking for certain data only has to search one place for it.  Another reason it is advantageous is redundancy.  Instead of having to back up every single file you wish to save, one backup of the database can be used and can be easily recovered in case of a hard drive failure.  This course will be useful for anyone that wants to enter the field of comput...