Welcome to Geeklog, Anonymous Sunday, December 22 2024 @ 02:19 am EST

Geeklog Forums

Change the Dates on All Stories


Status: offline

Sonnyb

Forum User
Junior
Registered: 05/21/05
Posts: 22
Location:Tampa, FL
Does anyone know of a simple way to change the date of all stories? Maybe an SQL command? I don't know enough about SQL to be comfortable messing with it without some guidance from the geeklog gods Smile

Thanks
 Quote

Status: offline

matthewcox

Forum User
Junior
Registered: 12/11/03
Posts: 31
Location:Asheville, North Carolina
ArrowIf you have phpmyadmin, select your database and select the SQL tab

in the query field us this command(changing the date and time to what you want)
Text Formatted Code

UPDATE `stories` set `date` = "2003-12-02 19:13:00"


 


ArrowIf you have shell access run these to commands(you'll need your geeklog database password)
mysql -p -u yoursusername geeklogdatabasename
UPDATE `stories` set `date` = "2003-12-02 19:13:00";

see example session below

Text Formatted Code

$ mysql -p -u yoursusername geeklogdatabasename
Enter password:
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A

Welcome to the MySQL monitor.  Commands end with ; or g.
Your MySQL connection id is 1346329 to server version: 4.0.24-standard

Type 'help;' or 'h' for help. Type 'c' to clear the buffer.

mysql> UPDATE `stories` set `date` = "2003-12-02 19:13:00";

 


enjoy!

-Matthew Cox

 Quote

Status: offline

Sonnyb

Forum User
Junior
Registered: 05/21/05
Posts: 22
Location:Tampa, FL
Thanks for the quick reply, worked like a charm.
 Quote

Status: offline

matthewcox

Forum User
Junior
Registered: 12/11/03
Posts: 31
Location:Asheville, North Carolina
Glad to hear. Very Happy

It does make me curious though, what purpose or effect does this achieve?

Always interested in new creative ways of using geeklog...

-Matthew Cox
 Quote

All times are EST. The time is now 02:19 am.

  • Normal Topic
  • Sticky Topic
  • Locked Topic
  • New Post
  • Sticky Topic W/ New Post
  • Locked Topic W/ New Post
  •  View Anonymous Posts
  •  Able to post
  •  Filtered HTML Allowed
  •  Censored Content