[EMAIL PROTECTED], 2001-03-25 12:35 -0800
>On Sat, 24 Mar 2001, Mike Noyes wrote:
> > [EMAIL PROTECTED], 2001-03-23 23:39 -0800
> > >... hardcoded "leaf" vs $DB?
> >
> > It would for our project, but I'm going to write a SF setup FAQ for
> > the phpWebSite project. Other SF projects have long names.
>
>I mean, in one place you used $DB, and in another place you used
>"leaf".
Jeff,
Yeah, I noticed that after I sent it to the list. It's fixed now. You can
get a copy of the shell script I'm using for the backup from my home
directory on shell1. After you ssh into SF:
$ cp ../mhnoyes/website.sh .
> > >this seems odd... if there are more entries in the authors table than
> > >just admin,
> >
> > There are.
> >
> > >they will be reduced to just admin (with a bunch of failed
> > >duplicate inserts)
> >
> > Correct, but I don't understand your comment about "failed duplicate
> > inserts". Did I do something wrong? The test.sql output looked
> > correct.
>
>I have never seen the "INSERT INTO ... (), (), (), ..., ();" extension
>of the INSERT command before. I always saw one insert for each row.
That's alright, I've never looked at a MySQL dbase prior to this. The
phpWebSite developers are discussing changes to the dbase structure for the
next release.
> > >is it really a good idea to lose author attribution? are there any
> > >foreign keys depending on entries in this table? maybe better just to
> > >"fix" their password to a dummy in the copy? I am not familiar with
> > >the schema, so I don't know what else might be a problem, but
> > >whatever you do, try it and load it into a temporary partition to
> > >verify that it works rather than depending solely on eyeball
> > >review...
> >
> > I already checked that sed was doing what I wanted before posting.
> > However, I haven't tried to use it on another site.
>
>I am still concerned about the loss of author attribution information.
>The "stories" table uses the "aid" variable.
Since users can create content, don't you have to worry about the uid
variable too?
CREATE TABLE users
line #1: uid int(11)
line #7: pass varchar(20)
PRIMARY KEY (uid)
>I have since looked closer at MySQL, and they claim that if you want to
>maintain relations, it is more efficient for the application programmer to
>do this than for them to put foreign key enforcement in the database.
>Regardless of whether this is right, you have broken this relationship.
>
>If the "pwd" field is the author password, then substituting a single
>default password for each password would seem to be more appropriate.
I'm out of my depth here, but my last conversation with Eric lead me to
believe otherwise. If we decide to substitute the password it should be
done for users and authors, correct?
>If there are no quoted single-quotes in the author fields, the following
>should do it:
>
>sed -e
>"/INSERT/s/\((\('[^']*',\)\{4\}\)'\([^']*\)',\([^)]*\)/\1'dummy',\4\)/g"
Why did you use a global when there are multiple INSERT strings in the
mysqldump? Wont this insert dummy in areas we don't want it?
author
('aid','name','url','email','pwd','counter')
user
('uid','name','uname','email','femail','url','pass','storynum','umode',\
'uorder','thold','noscore','bio','ublockon','ublock','theme','commentmax\
','counter')
--
Mike Noyes <[EMAIL PROTECTED]>
http://leaf.sourceforge.net/
_______________________________________________
Leaf-devel mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/leaf-devel