SitePoint Sponsor |
|
User Tag List
Results 1 to 15 of 15
Thread: Having a mysql problem- not sure
Hybrid View
-
Dec 11, 2009, 03:39 #1
- Join Date
- May 2005
- Location
- Houston, Texas, USA
- Posts
- 418
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Having a mysql problem- not sure
Here is the background:
I have two sites which have identical code. With no changes to the code, and three successful transactions on the site since the last update, I am now getting an error on only one of the sites. There is a calendar that is "linked" to the db and the first indication of something wrong was that all the dates turned back to black (they are red when someone makes a reservation). I manually input a reservation and it seems like that is when the problems started. There is an updated cpanel (Accelerated version). I've done lots of these manual "reservations" (adding a record) and never a problem. This is the first one I didn't check before and after on (just my bad luck).
I've attached a pic of both dbs table structure. One works perfectly and one does not. I don't want to touch the php code because it's the same on both sites. As you can see, there are some minor differences to the mysql tables. Can anyone tell me by glancing at this if it is the mysql causing my problem?Opportunity favors the prepared mind.
-
Dec 11, 2009, 03:47 #2
Did you check the content of the tables? If dates are shown as 'not reserved' then maybe you lost the reservation data?
Guido - Community Team Leader
The Votes Are In: The Winners of the 2013 Community Awards are...
Blog - Free Flash Slideshow Widget
-
Dec 11, 2009, 03:53 #3
- Join Date
- May 2005
- Location
- Houston, Texas, USA
- Posts
- 418
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
All of the data is there.
Opportunity favors the prepared mind.
-
Dec 11, 2009, 04:04 #4
Beats me
If the data in the DB is correct, and the code is the same on both sites, I don't know why it shouldn't work.Guido - Community Team Leader
The Votes Are In: The Winners of the 2013 Community Awards are...
Blog - Free Flash Slideshow Widget
-
Dec 11, 2009, 04:08 #5
- Join Date
- May 2005
- Location
- Houston, Texas, USA
- Posts
- 418
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
What about the discrepancies in the table structures?
Opportunity favors the prepared mind.
-
Dec 11, 2009, 14:53 #6
- Join Date
- Sep 2008
- Posts
- 977
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
well the table content seems to be different so I would take a look there to see what is different. I might optimise the table to to try to get rid of that overhead.
bazz
-
Dec 12, 2009, 07:51 #7
- Join Date
- May 2005
- Location
- Houston, Texas, USA
- Posts
- 418
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
-
Dec 12, 2009, 09:20 #8Guido - Community Team Leader
The Votes Are In: The Winners of the 2013 Community Awards are...
Blog - Free Flash Slideshow Widget
-
Dec 12, 2009, 01:18 #9
- Join Date
- May 2007
- Location
- Poole, UK
- Posts
- 5,077
- Mentioned
- 103 Post(s)
- Tagged
- 0 Thread(s)
According to the screenshots in the reservation_date table in the coyoteri_crreservation you have 157 rows. In the same table but in the rabbitju_rjreservation database you only have 144 rows. Have you manually added 13 rows to the reservation_date table in the coyoteri_crreservation database?
Community Team Advisor
Forum Guidelines: Posting FAQ Signatures FAQ Self Promotion FAQ
Help the Mods: What's Fluff? Report Fluff/Spam to a Moderator
-
Dec 12, 2009, 07:49 #10
- Join Date
- May 2005
- Location
- Houston, Texas, USA
- Posts
- 418
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
I have actually manually added some to both. The content of the records is different in each, though, whether I add new records manually or not
Opportunity favors the prepared mind.
-
Dec 12, 2009, 07:58 #11
- Join Date
- May 2005
- Location
- Houston, Texas, USA
- Posts
- 418
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Elsewhere someone suggested that there could have been an inadvertent change to the db table structure which is why the dbcontent is not recognizing it. I want to avoid changing the code. What might need to be changed within the db itself?
Opportunity favors the prepared mind.
-
Dec 12, 2009, 16:39 #12
- Join Date
- May 2007
- Location
- Poole, UK
- Posts
- 5,077
- Mentioned
- 103 Post(s)
- Tagged
- 0 Thread(s)
Have you (or your host) changed anything in terms of server configuration?
Are any errors being given by MySQL for the INSERTS?
Add an echo for each query after the query is made (for both databases) ie something like:
PHP Code:echo $query;
Community Team Advisor
Forum Guidelines: Posting FAQ Signatures FAQ Self Promotion FAQ
Help the Mods: What's Fluff? Report Fluff/Spam to a Moderator
-
Dec 13, 2009, 06:11 #13
- Join Date
- May 2005
- Location
- Houston, Texas, USA
- Posts
- 418
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
cPanel upgrade was done. I asked them about it and they couldn't find anything. could a cpanel upgrade affect one account and not the other? I get no errors when inserting records manually. However, when they uploaded the backup of the db, I now get a php error on the calculation end. I haven't run a query yet, but do you think if I created the db to match the one on the right it would correct the error?
Opportunity favors the prepared mind.
-
Dec 15, 2009, 13:43 #14
- Join Date
- May 2005
- Location
- Houston, Texas, USA
- Posts
- 418
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Solution.... Somehow the user permissions in cpanel were changed
Opportunity favors the prepared mind.
Bookmarks