« first day (1428 days earlier)      last day (1230 days later) » 

1:03 AM
@TehShrike ya i do.. is there anyway i can use my "user/login tables" in loggin in to my form? and do sql commands there. ?
 
 
14 hours later…
2:51 PM
@Newbiematt I don't understand your question. The point of having the tables is to be able to use them
 
3:02 PM
Hi there,
I have a table `users` that has `email` as the primary key and a table `offers` that has `offer_id` as the primary key.

I want to store whether a user likes an offer or not. So I thought I would create a new table that contains
email (varchar), offer_id (int(10)), email_offer_id (bool, default false)
I have tried to do it with a for loop , as in "for each email x for each offer i create a row in table choices that is a copy of row i"
But I failed to even create a runnign loop, advice is scarce, ppl recommend using joins, which I dont understand fully.
My idea was

INSERT INTO `2k15_selections` (offers_id, email)
SELECT offers_id FROM `2k15_offers`
SELECT email FROM `user`

but this fails. Can anyone hint me in the right direction ?
 
 
2 hours later…
4:46 PM
OK folks, I've done it like this
INSERT IGNORE INTO `2k15_selections` (offers_id,email)
SELECT DISTINCT `2k15_offers`.`offers_id`,`user`.`email`
FROM `2k15_offers`
JOIN `user`
 
 
7 hours later…
11:27 PM
PHP/Mysql question. I have one script that will query a table endlessly in a while loop without reconnecting to the DB. When I start the script, the table is empty. While it's running, in another script I insert a row to said table. Shouldn't my first script be able to pick up the new record once it's created? Or does it need a new session/connection?
 
11:45 PM
Query caching maybe?
 

« first day (1428 days earlier)      last day (1230 days later) »