Posted on: 10/14/02 04:21pm
By: rv8
I'm working on moving my site to GL. I need to create quite a few stories for years going back to 1997, but the story editor won't let me do anything earlier than this year.
This was discussed earlier[*1] , but I don't understand the suggested work around
What I would do is pick an arbitrary point in the future, say 01/01/2003 00:00:00. Assign all your story to that date/time. Then do this:
"update stores set date = 'YYYY-DD-MM HH:MM:SS' where date = '2003-01-01 00:00:00'"
Where exactly do I go to run this update stories command?
Thanks,
Kevin
Adding stories for previous years
Posted on: 10/14/02 05:31pm
By: dreamscape
You need to run that command in some mysql client (mysql itself, phpMyAdmin, or something equivalent).
You want to pick a point in the future (the same for all stories that are going to be updated at the same time) so that when you update you don't squash your current DB.
Before you run update I suggest making an entrance to #geeklog, make sure you are getting the correct rows with select statements, and get a sanity check on your update statement.
at least that's what I would do.......
Adding stories for previous years
Posted on: 10/15/02 08:36am
By: mvonahn
I had to do something similar for converting MacFixIt to geeklog. What I would up doing was creating a PERL script to parse the files out and insert them into the gl_stories database. MFI has archives of over 5000 articles back to 1996 and there was no way I wanted to add them all by hand. If you are going to do the entry by hand you might want to consider altering the function COM_getYearFormOptions in lib-common.php and setting the variable $start_year to 1997 until you get your archived data all entered.
The for loop looks like it will still wirk correctly after doing this and the selected item should still be this year.
mva
Adding stories for previous years
Posted on: 10/16/02 02:59am
By: rv8
Thanks! I modified the function COM_getYearFormOptions in lib-common.php and setting the variable $start_year to 1997, and everything seems to be working correctly.
There must be a fair number of people who want to populate a GL site with material from an old site, so I think it makes sense to allow this variable to be set from config.php. Who do I make that suggestion to?
Kevin