Search Results
Search type | Search syntax |
---|---|
Tags | [tag] |
Exact | "words here" |
Author |
user:1234 user:me (yours) |
Score |
score:3 (3+) score:0 (none) |
Answers |
answers:3 (3+) answers:0 (none) isaccepted:yes hasaccepted:no inquestion:1234 |
Views | views:250 |
Code | code:"if (foo != bar)" |
Sections |
title:apples body:"apples oranges" |
URL | url:"*.example.com" |
Saves | in:saves |
Status |
closed:yes duplicate:no migrated:no wiki:no |
Types |
is:question is:answer |
Exclude |
-[tag] -apples |
For more details on advanced search visit our help page |
2
votes
1
answer
406
views
phpliteadmin is constatly loading and won't open pset8
Basically the title. Whenever I try to open phpliteadmin, I get the little loading circle and no matter how long I wait it doesn't open. I've restarted my computer, refreshed the tabs, reconnected to …
0
votes
1
answer
95
views
How to run a command (like apology) inside of db.execute? PSET8
I have an IF statement inside of db.execute, but I can't figure out how to run a normal command depending on the result. I want to run like apology inside of the db.execute for testing, but I can't fi …
1
vote
1
answer
32
views
Map doesn't load properly pset8
When I go to flask run and open the web server, the google maps background is darkened and says "For development purposes only" and when I try to use the search feature nothing changes. Also I can onl …
0
votes
1
answer
49
views
pset8 finance portfolio on new stock/id
I'm trying to make it so when the user doesn't already own the stock, it adds it to the table. If they do already own it, it should update. The problem is when I try it, it buys 2x what it is supposed …
0
votes
1
answer
76
views
When stock and user exist, update (PSET8)
I'm trying to make it check if the user already owns this stock, and if they do, then to update the portfolio. I'm confused about how to get this code to work as I don't understand how to check if it …
0
votes
1
answer
50
views
Update portfolio on duplicate id and stock
So I think I know where the problem is, it's trying to update the variable shares taken from the form, and add the shares from the form and the new amount of shares, which is not helpful. I need to gr …
0
votes
1
answer
72
views
How to tell if selling shares results in a negative amount pset8
This is the code I have at the moment
dbshares = db.execute("SELECT :shares FROM portfolio WHERE user_id = :user_id", shares=shares, user_id=session["user_id"])
if dbshares[0]['shares'] - shares …
2
votes
1
answer
294
views
CS50 2019 PSET8 updating API from 2017 API
I have a lot of work from finance 2017, but it seems to use a different API than what I used last year. How do I update my code to use this new API? Or can I just use the one from last year? (I don't …
0
votes
0
answers
205
views
PSET8 finance index giving internal server error, can't find a table that already exists
Whenever I go to the web server, and I log in, I get an internal server error. It says " no such table: transactions [SQL: 'SELECT stock, SUM(shares) as sumshares FROM transactions WHERE user_id = 1 G …
0
votes
1
answer
42
views
pset8 New errors without changing any old code [duplicate]
I've been working hard on pset8 lately and making great progress. I was busy and didn't get to work on it for about a week. …
-1
votes
2
answers
88
views
finance how to compare requested shares to shares owned
I'm having trouble trying to figure out how to write the sql statement to receive the amount of shares owned so I can compare it to the number requested, and if owned - requested < 0, don't let them s …