How to integrated/combined/merged MovieLens and IMDb datasets? - dataset

Movie.csv of the MovieLens dataset contains only the MovieId, title, and genre features. But I'd like to add more features (and merge with movie.csv) like director and cast information. How can I do this? May I ask for suggestions to be informed about this subject?
Thank you..

Related

Simple Database Schema for a tech blog

I am building a simple tech blog and this is my database.
Because I don't really have a lot of experience I am looking to get some feedback if its an OK schema.
I will have 5 categories: Computer, mobile , laptop , tablet and General.
For users I will only have an admin to begin with and maybe I will add users later.
User will only be able to comment/share on the posts nothing more.
Only admins will be able to create posts etc.
Guests will only be able to browse the site and share posts.
I would like to add a feature to be able to count how many shares have been made for a specific post but later.
Also I might add sub categories to each category (for this I think that I need another table to track those).
Any help is appreciated, thanks in advance.
In my view, you should add a comments table; in your database a Post can have only one comment.
Comments should have this fields at minimum: id, body, post_id, user_id, because they belong to a Post and to a User.
In the posts table add fields: user_id and category_id because each post belongs to a User and to a Category; and remove the comment field because a post can have many comments.

Database schema for an online shop

So I'm fiddling with how you could design the basic db schema for a webshop. Sure, there's a lot of missing details here and there, but I just want to get the most basic stuff right.
Some basic requirements for the shop, which I'm trying to make a schema of:
The shop has an inventory of products. Each product has a price, but this price should vary depending on sales. Customers can make orders for multiple products at a time, and should be able to see their order history. When the order has been completed, there should be a track and trace number.
So, the following image is what I've come up with so far. I'm sure something is missing, I'm just not really sure what, also how to model the dynamic price aspect.
I think this is the according to your question give a flow of it how to create a schema and Additional that Link here please visit once you will find some amazing part.
A common way to handle variable price would be to introduce a rebate schema. This can be implemented as association class between Product and Sale by adding some rebate to amountSold. Of course there are many different ways, but this is one at hand.
I'm missing a relation between Order and Customer.
Not sure what you intend with the Inventory aggregating ProductList. To me a Inventory lists Product. There might be the need to a store location and a PurchasePipe

Database : Design table with dynamic tags

In my table, there is a list of items, those items have some attribute that is dynamic. it means it can change through run-time, not design-time.
For example, a list of dishes. So, a dish can be a fish/dessert/drink/.... Those attributes will help my application filter it later base on user. And those attribute is inputted by manager through run-time.
So, I don't know how to design a table with dynamic attribute like this. Who has any ideas, please tell me.
Thanks :)
You could add a type column to your table.
Another approach would be to have something like a tag. Where you item has many tags.
However, more details on what you're trying to accomplish would be necessary in order to give a better answer.
Are you new to database design? you should probably look at some db design tutorials:
http://www.ntu.edu.sg/home/ehchua/programming/sql/Relational_Database_Design.html
http://www.databaseanswers.org/tutorial4_getting_started_with_db_design/index.htm
The attributes that you mentioned could be stored as data in some database table under column dishes.
And then you could relate these dishes with your users.

Building a hotel program database, need a database design opinion

Each reservation contains names of the guests & a company name.
Now, the guests may/may not belong in a company. (a booking may have a company as null)
Currently, I have:
Booking_table (booking_id, guest_id, company_id)
Guest_table (guest_id, guest_name)
Company_table (company_id, company_name)
Guest_booking_history (guest_id, booking_id)
Company_booking_history (company_id, booking_id)
Am I doing this right? Any suggestions in designing the database?
An alternative would be:
Booking_table (booking_id, guest_names, company_id)
Company_table (company_id, company_name)
It's mostly good, but I'd consider adding the company to the guest, and maybe remove the company from the booking table. Something like:
Booking_table (booking_id, guest_id)
Guest_table (guest_id, guest_name, company_id)
Other than that, I think your database is missing a lot of important data - dates, customer info, etc, but that's a whole other issue fully dependent on exactly what you want to achieve with the database and software.
Seems like it would be usefull to have the booking dates, and booking needs likely needs to be linked to a table of rooms.
It all depends on what data you want to keep and track ;)
Other then that, if this is homework mark it as that.

Accessing related models in Django?

Please forgive me if this question is ridiculous. I'm relatively new to programming and Django.
Following the typical Publisher, Author, Book example....
Publisher to Author (One to Many)
Author to Book (One to Many)
I'm trying to get Django to give me a list of books published by all the authors under a single publisher.
Two ways I've thought about doing this:
I could get a list of all the authors under a single publisher, and then iterate over these authors to find all of their books. This seems like a really wonky way to do this.. and I'll have to hit the DB a lot.
I can get Django to add a new "Publisher" column in my Books table, but I'm not sure if I want to replicate that data, and I don't know how to get Django to automatically fill in that info.
I'd appreciate any help. Thanks.
If each book has an author ForeignKey and each author has a publisher ForeignKey, you can do:
Book.objects.filter(author__publisher = <Publisher object>)
To get what you're looking for.

Resources