Questions tagged [database]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0 votes
0 answers
11 views

Unable to connect to SQLITE SERVER

I just signed up for cs50 sql but have not be able to connect to the database server after i installed sqlite, sql tools, sqlite3 editor and so forth. I have been at it for over a week and still ...
Riyadh Elbaff's user avatar
0 votes
3 answers
37 views

how to get values and column names from database and find max()

I query database for values, append them to the list and find the maximum value. What can I do to get the name of column too? in my case the name of the maximum expense? I would appreciate any ...
ann's user avatar
  • 1
0 votes
0 answers
204 views

RuntimeError: near ",": syntax error

I'm struggling with my final project. I try to query database for income items ( in "income" table) to sum them up finally, but each time I get the syntax error. The funny thing is that it ...
ann's user avatar
  • 1
0 votes
1 answer
275 views

How does the database ER diagram look like in Pset7 (Fiftyville)?

Pset7 (Fiftyville) DB has 10 tables. It would be much easier to work with them if the entity–relationship model (ER diagram) is presented. Pset description doesn’t have it.
NeMaksym's user avatar
0 votes
1 answer
472 views

CS50W Project 4 / Network - like counter not always saving to database

I was able to implement a like counter where it keeps track of all the likes. For some reason though, it randomly doesn't save the counter to the database when I submit the PUT request. I can't figure ...
abbanator's user avatar
0 votes
1 answer
536 views

RuntimeError: missing value for placeholder (:name)

all! I'm doing the final project, and I have a form whose contents I'm trying to submit to a database. My python code is: @app.route("/Contact.html", methods=["GET", "POST"]) def Contact(): if ...
Diaresta's user avatar
0 votes
0 answers
122 views

DNA is good for the small database but not for the large database - CS50 Pset6

I'm currently developing the small and the large database functions separately and I wonder why in the large one it does not keep track of the STR repetitions. Here is my code from both functions: ...
f23's user avatar
  • 1
0 votes
1 answer
315 views

postgresql syntax error

So this is part of the import.py code in project1: db.execute("INSERT INTO books (isbn, title, author, year) VALUES (:isbn, :title, :author, :year)", {"isbn": isbn, "title": title,...
Chris's user avatar
  • 428
0 votes
2 answers
73 views

CS50W Project1: ISBN too short, csv file does not provide correct ISBNs?

I was having an requests.exceptions.HTTPError: 404 Client Error: Not Found for url: error. I noticed after reading some of the documentation on Goodreads that we can use either 10-digit ISBNs or 13-...
azb1297's user avatar
  • 63
0 votes
1 answer
63 views

Finance register function does not insert data in database

I am trying to finish the register function but something goes wrong. I get an error message " It seems that although registration is claimed to be ok (from check50) nothing is actually added in the ...
Mary91gr's user avatar
0 votes
2 answers
421 views

Can't Connect Python Flask With PSQL Database

every time i try to make connection between python and PSQL this error disappear ?
Ahmed Usama's user avatar
0 votes
1 answer
26 views

Best practice advice - store in DB or calculate on the fly (pset7)

I have a table which is basically a "flat" list of all the purchase transactions done in the system - no aggregation of any sort. I was wondering if there are any best practices or guidelines as to ...
Ami Friedman's user avatar
0 votes
1 answer
143 views

pset7 finance insert new row

I'm trying to add a row into my finance db using the code below (a few versions), but keeping getting an error saying I'm passing in too many variables to the execute() function. Any direction here ...
Jake 's user avatar
  • 37
0 votes
2 answers
133 views

pset 7 [buy] Unable to render user's cash

I've spent a lot of time trying to solve this problem and can't seem to find were I went wrong. Any help is greatly appreciated. I am unable to render the user's cash balance on the index. def ...
Salamit's user avatar
  • 231
1 vote
2 answers
827 views

Password for phpLiteAdmin

I am requested to enter a password for phpLiteAdmin. I was following steps from the lecture, intro to phpliteadmin. After I inserted a new row ("name", "dorm") into the table registrants, I got this ...
wingedRuslan's user avatar
1 vote
2 answers
2k views

Set foreign key in phpLiteAdmin

Does anyone know how to set a foreign key using the phpLiteAdmin interface? The docs for this application are lacking, and the recommended syntax for adding a column using SQLite does not appear to ...
Ryan's user avatar
  • 138
0 votes
0 answers
41 views

Ruby Database Question Final Project

I'm working on my CS50 final project. The goal is a powerful webscraper using Nokogiri and Ruby that will pull event data from many sources on a weekly basis and then output that data as a CSV and ...
Nicholas S's user avatar