Error Adding Blog Entries

Whenever I post a new article (several lately)… it never posts to the cb_contentVersion table, and errors out, until I add it manually.
I noticed it happens with my Unit Testing Category especially, but it might be just a case of those are the last couple of entries.
I thought I re-inited and did everything else from the admin menu.

I’m adding the pdf, so you can have a look.
Not sure what is causing it.

Any ideas.
Don’t waste your family time… enjoy your xmas… but I thought its probably obvious to you.

Thanks in advance guys

Merry Christmas and Happy Holidays.

www.gpickin.com_error.pdf (438 KB)

The error starts with the entryService.saveEntry( entry ); line in the entries handler. Following the Java stacktrace north of the EntitySave() shows these lines:

at org.hibernate.engine.Cascade.cascadeToOne(Cascade.java:392):392
at org.hibernate.engine.Cascade.cascadeAssociation(Cascade.java:335):335
at org.hibernate.engine.Cascade.cascadeProperty(Cascade.java:204):204
at org.hibernate.engine.Cascade.cascadeCollectionElements(Cascade.java:425):425
at org.hibernate.engine.Cascade.cascadeCollection(Cascade.java:362):362
at org.hibernate.engine.Cascade.cascadeAssociation(Cascade.java:338):338
at org.hibernate.engine.Cascade.cascadeProperty(Cascade.java:204):204
at org.hibernate.engine.Cascade.cascade(Cascade.java:161):161
at org.hibernate.event.def.AbstractSaveEventListener.cascadeAfterSave(AbstractSaveEventListener.java:476):476
at org.hibernate.event.def.AbstractSaveEventListener.performSaveOrReplicate(AbstractSaveEventListener.java:354):

which indicates it’s saving a cascading relationship off of the entry entity. I assume this is the contentVersion table. The top few lines of the trace are this:

could not insert: [cbContentVersion]
at org.hibernate.exception.SQLStateConverter.handledNonSpecificException(SQLStateConverter.java:140):140
at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:128):128
at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:66):66
at org.hibernate.id.insert.AbstractReturningDelegate.performInsert(AbstractReturningDelegate.java:64):64
at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:2329):2329

So apparently Hibernate handles non-specific exceptions by telling us pretty much nothing.

Can you give us any specifics on the type of database you’re using, what version of Railo you’re on, and what you get if you enable ORM Logging? The stacktrace doesn’t have a "caused by "section at the bottom. Can you confirm that the error that is put in your logs (if any) or displays on the screen also don’t have a “caused by”?

Thanks!

~Brad

ColdBox Platform Evangelist
Ortus Solutions, Corp

E-mail: brad@coldbox.org
ColdBox Platform: http://www.coldbox.org
Blog: http://www.codersrevolution.com

I got it to happen again last night.
Its when I create a new category, I’ll try and do a TEST entry and pull all the logs then.

As usual, time is short, so I’ll do it when I have time to mess with it.

I just created a new blog entry and typed in a new category name before saving and it worked fine.

I’m on v.1.6.0.00037

Thanks!

~Brad

ColdBox Platform Evangelist
Ortus Solutions, Corp

E-mail: brad@coldbox.org
ColdBox Platform: http://www.coldbox.org
Blog: http://www.codersrevolution.com

Oh, also-- make sure you enable ORM Logging.

Thanks!

~Brad

ColdBox Platform Evangelist
Ortus Solutions, Corp

E-mail: brad@coldbox.org
ColdBox Platform: http://www.coldbox.org
Blog: http://www.codersrevolution.com

Ok… another similar error, editing a blog.

i just edited a blog, and switched just some basic content, nothing else… and it blew up.

I reloaded the App
the Admin
the Site
the ORM

Tried again, still the same error.

The ORM.LOG file shows

[root@new-supernova logs]# tail orm.log
“Severity”,“ThreadID”,“Date”,“Time”,“Application”,“Message”
“ERROR”,“web-0”,“12/19/2013”,“15:53:15”,“org.hibernate.util.JDBCExceptionReporter”,“Incorrect string value: ‘\xE2\x80\x8B-ho…’ for column ‘content’ at row 1”
“ERROR”,“web-0”,“12/22/2013”,“23:28:03”,“org.hibernate.util.JDBCExceptionReporter”,“Incorrect string value: ‘\xE2\x80\x8Bind…’ for column ‘content’ at row 1”
“ERROR”,“web-0”,“12/24/2013”,“10:36:32”,“org.hibernate.util.JDBCExceptionReporter”,“Incorrect string value: ‘\xE2\x80\x8B}\x0D\x0A…’ for column ‘content’ at row 1”
“ERROR”,“web-0”,“01/08/2014”,“02:39:49”,“org.hibernate.util.JDBCExceptionReporter”,“Incorrect string value: ‘\xE3\x81\x99\xE3\x81\x90…’ for column ‘content’ at row 1”
“ERROR”,“web-0”,“01/10/2014”,“00:24:00”,“org.hibernate.util.JDBCExceptionReporter”,“Incorrect string value: ‘\xE2\x80\x8B …’ for column ‘content’ at row 1”
“ERROR”,“web-0”,“01/31/2014”,“21:32:44”,“org.hibernate.util.JDBCExceptionReporter”,“Incorrect string value: ‘\xE2\x80\x8B\x0D\x0A<…’ for column ‘content’ at row 1”
“ERROR”,“web-0”,“01/31/2014”,“21:33:19”,“org.hibernate.util.JDBCExceptionReporter”,“Incorrect string value: ‘\xE2\x80\x8B\x0D\x0A<…’ for column ‘content’ at row 1”
“ERROR”,“web-0”,“01/31/2014”,“21:34:22”,“org.hibernate.util.JDBCExceptionReporter”,“Incorrect string value: ‘\xE2\x80\x8B\x0D\x0A<…’ for column ‘content’ at row 1”

None of the other LOGs were updated.
Any clues from that?

Then once reloading everything, I try to login in another browser, and the site is completely busted.
Attaching that too.

Restarting Railo now… will see if that fixes anything.
Once restarted Railo, its back to normal.

Interesting.

editerror_www.gpickin.com_index.pdf (396 KB)

reload_issue.pdf (71.9 KB)

Not 100% sure, but that looks like UTF-8 issues with the database mysql.

Sorry meant to post this link as well.

http://stackoverflow.com/questions/1168036/how-to-fix-incorrect-string-value-errors

Its strange it only happens at weird times, and when it does, I have to restart Railo to fix it.

I am not using UTF8 for my db, its all cp1252.

Weird… I’ll read into it, thanks for the heads up Andrew.

Gavin Pickin
gpickin@gmail.com
http://www.gpickin.com

Hi guys.

I have encountered this same issue with Railo and MySql.

Incorrect string value: ‘\xE2\x80\x8B\x0D\x0A\x0D…’ for column ‘entry’ at row 1

It is definitely character related. Here is the part of the query that is causing the error when trying to Insert a row:

VALUES(15010,6392294,'I can not log into this … cf​

How do I detect and clean these character up?

I know we’ve had similar threads and I think it’s usually boiled down to MySQL settings. I don’t know if there’s a way ContentBox can even detect your character sets via ORM and modify the data accordingly.

Maybe someone using ContentBox with a language different than English like myself will have more insight.

One more question, were those characters something you typed, or were they unexpected?

Thanks!

~Brad

ColdBox Platform Evangelist
Ortus Solutions, Corp

E-mail: brad@coldbox.org
ColdBox Platform: http://www.coldbox.org
Blog: http://www.codersrevolution.com