Skip to content

Tag: mysql

Update specific row using codeigniter?

I am trying to update specific row of table in codeigniter. But my code update all rows. Model: Controller: And in new page it show the echo value 1. How to update specific row? why $query->num_rows() return 1 and update all rows? Answer Try using a where condition to update a specific record

connecting to mysql via ipaddress with MySQL and mysqli

I have weird problem. I don’t have a domain name for my remote mysql database, so on my development machine I usually just connect to a remote mysql using the ip address. On my development machine the ip address connection works for both mysql and mysqli connections. However, when I upload to my live se…

Trying to use variable in MySQL INNER JOIN

I am a php and MySQL newbie. What I have done is created an html form with a <select> dropdown. Based on the selection from the form, it changes the $_SESSION[campaignID] variable. Changing the selection in the form is supposed to then change what displays on the page. The page consists of a forum style…

MySQL Rows Disappearing (Mysteriously)

I have 3 tables A, B and C which are directly linked and should contain the same number of rows, the rows for each table being created together. I’ve recently noticed that after creating 1000 rows for test purposes (rows are definitely inserted, no transactions, system stable), and without any applicati…