Recent Topics

1 Dec 03, 2007 12:55    

I posted an original "help" question on this but I'm thinking it's a bug.
[URL=http://forums.b2evolution.net/viewtopic.php?t=13481]Original Help Question[/URL]

I've repeated trying to edit posts with existing tags and keep getting the error. The post can only be updated or edited by deleting the existing tags.

Additional information about this error:

MySQL error!

Duplicate entry 'firefox' for key 'tag_name'(Errno=1582)

Your query: insert new tags

INSERT INTO evo_items__tag( tag_name )

VALUES ( 'firefox' ),( 'gmail' ),( 'google' ),( 'mac' )

I'm not sure if it;s always been a problem, or if the inclusion of comma seperators with this version is causing problems.

2 Dec 06, 2007 04:31

This has even happened on a brand new post.
Post was compiled, tags added, hit Save and the same error again.
Tags cannot be added, and existing tags posts cannot be edited.
What changed between this version and the previous version?

3 Dec 06, 2007 14:50

On a fresh 2.2.0 installation I was unable to duplicate the problem with a new post. Meaning I created a new post and gave it some tags, and it posted with the tags as one would desire.

I can not test editing an old post because I wiped the database and created a new installation instead of upgrading an existing one.

4 Dec 06, 2007 21:04

I think the issue lies in the fact that I had this in the previous version. I'm sure that the "," separator was only introduced in the 2.2.0 version ( it was a "space" before ) so it doesn't surprise me that on a first up 2.2.0 post your ok EdB.

5 Dec 06, 2007 23:24

Well, I checked the database and for one it had multiple tag names in the one item instead of creating separate items for each name.
I'll see if deleting that helps.

6 Dec 06, 2007 23:54

OK...
Any tag word that has been used in a previous post cannot be repeated in any subsequent posts.
If the tag words are new and unigue, there is no error

If they are the same , BANG, error.

This isn't how tags are supposed to work, is it?

7 Dec 07, 2007 01:54

John wrote:

OK...
Any tag word that has been used in a previous post cannot be repeated in any subsequent posts.
If the tag words are new and unigue, there is no error

If they are the same , BANG, error.

This isn't how tags are supposed to work, is it?

Does this apply to posts created after upgrading? Again I couldn't duplicate, so I'm sort of thinking if it ALWAYS ties in with tags from 210 it helps debugging efforts.

8 Dec 07, 2007 02:15

Edb.. the database lists all tag words
In the previous 2.1.0 I could post the same tag word in as many different posts as I liked.... witness the Tag Cloud

Now, with this version, if I post a tag word thats already in evo_items__tag I get the duplication error as quoted above.

Something changed on upgrade to 2.2.0 that caused it but I can't figure out what files are effected to do a compare, and I know SFA about databases to try ad deal with that side of it

Thanks for hanging in there :)

9 Dec 07, 2007 12:32

But if you make a post in 220 using tags that never got used in 210 does it post? How about if you re-use those same tags in another post in 220? See what I'm getting at? "Is your installation hosed when you try to re-use tags that you used in 2.1.0" is what I think will help developers understand the problem - and therefore find a solution for whatever comes next.

Can you try 2 posts in 220 using a tag of something like "asdfadfadsfasdfadf" just to see if you can re-use that tag? More accurately, using a tag that you have never used before. Doesn't have to be stupid random letters...

I can and will do a 210 install, post with tags, upgrade to 220, and see if I can duplicate your problem. Right now I'm deep in upgrading skins and plugins, so adding another project would ensure that nothing gets done soon, but for sure I will try to set up the conditions that you've described. The core developer need to find a definitive statement about the problem is the thing, no matter how complicated "definitive" might be.

10 Dec 07, 2007 12:46

But if you make a post in 220 using tags that never got used in 210 does it post?

Yes, it works

How about if you re-use those same tags in another post in 220?

It crashes and reports "duplicate " error.

Is your installation hosed when you try to re-use tags that you used in 2.1.0"

Yes, its more than friggin hosed.

I'll bugger around with it EdB using whatever mix I can but the bottom line is, it went like the cats whiskers until the update to 2.2.0.

I like tags, they work, they are a good idea. Its one of the better additions to B2 in a long time so I'm jus trying to get it sorted

I'll post back here any results.

Thanks for the reply

11 Dec 07, 2007 13:14

Cool. Well, not cool that your blog is broken, but cool that the developers are getting more info. Unfortunately I can't duplicate your problem on my fresh 220 installation. I will not reply here again until I have the time to do a 1103 install that I upgrade to 210 then add a post with tags then upgrade to 220 and try another post with the same tags.

Plus my exact server config will probably differ from yours. Just to make it more fun... ;)

Thanks for reporting and your follow-up.

PS: I'm not a tag guy. To me they're nothing more than 'categories on the fly', but hey maybe that's a cool thing? Category = 'politics', Tags = politician names and current hot topic name. This would be a smart use of tags?

Wow I should try tagging something in my 220 that went through 210 from ... ultimately ... to be honest ... 0.8.6.2 to see if I can duplicate this issue based on it being an upgrade even though there were no tags used when I was on 210.

This is on my Major ToDo list - because I stuck my nose in. My plugins are really important to me, so they take precedence, but for sure I will do a 210 with tags then upgrade.

12 Dec 07, 2007 13:23

I reckon Tags are cool. They are a way to break out of a Categories based system. They are a way of grouping posts (Yabba's Related Post plugin) etc etc and Google and poorer relations eats them for breakfast.

Seems to be a database based issue, but I just wish I could find the B2 file that generates/makes em and do a file compare.

Lets leave it sit , it's the weekend down here :)

13 Dec 08, 2007 15:52

Fixed in cvs.

inc/model/_item.class.php approx 2712

			if( !empty($this->tags) )
			{
				// Find the tags that are already in the DB
				$query = 'SELECT LOWER( tag_name )
										FROM T_items__tag
									 WHERE tag_name IN ('.$DB->quote($this->tags).')';
				$existing_tags = $DB->get_col( $query, 0, 'Find existing tags' );

¥

14 Dec 08, 2007 18:29

¥åßßå wrote:

Fixed in cvs.

inc/model/_item.class.php approx 2712

¥

inc/items/model/_item.class.php approx 2712


Form is loading...