You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ofbiz.apache.org by "Adrian Crum (JIRA)" <ji...@apache.org> on 2009/11/21 18:44:39 UTC
[jira] Created: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Sandbox: Integrating The New Conversion Framework Into The Entity Engine
------------------------------------------------------------------------
Key: OFBIZ-3245
URL: https://issues.apache.org/jira/browse/OFBIZ-3245
Project: OFBiz
Issue Type: Improvement
Components: framework
Affects Versions: SVN trunk
Reporter: Adrian Crum
Assignee: Adrian Crum
Priority: Minor
Attachments: conversion.patch
This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
Re: [jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New Conversion
Framework Into The Entity Engine
Posted by Adam Heath <do...@brainfood.com>.
Khosrow Khoramian wrote:
> PLEASE LET ME KNOW HOW I CAN REMOVE MISELF FROM EMAIL LIST. I DON'T WANT TO RECEIVE ALL THESE EMAILS BUT I DO NOT SEE ANY UNSUBSCRBE LINK.
Look at the raw headers of your email, there's a List-Unsubscribe link.
RE: [jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by Khosrow Khoramian <kk...@hotmail.com>.
PLEASE LET ME KNOW HOW I CAN REMOVE MISELF FROM EMAIL LIST. I DON'T WANT TO RECEIVE ALL THESE EMAILS BUT I DO NOT SEE ANY UNSUBSCRBE LINK.
ELI
> Date: Thu, 26 Nov 2009 17:46:40 +0000
> From: jira@apache.org
> To: dev@ofbiz.apache.org
> Subject: [jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New Conversion Framework Into The Entity Engine
>
>
> [ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12782951#action_12782951 ]
>
> David E. Jones commented on OFBIZ-3245:
> ---------------------------------------
>
> It sounds like you're still misunderstanding Adrian. Remember that you are adding the idea of supporting multiple object types externally, and that didn't exist before. The Entity Engine previously dealt with only one object type for each field type, and that object type was the same for the external API as it was for the JDBC driver.
>
> This was done by using the JDBC API to set a specific type of object when writing, and also using the JDBC API to get a specific type of object when reading. There is nothing that just does a get and lets the JDBC driver choose what sort of object to return.
>
> So, in other words there was only a need for one object type.
>
> With what you have going now, I still think there is only a need for one java object type. Having multiple attributes for this would be confusing, or at least it is to me...
>
> I still don't see an answer to the question of what you would do with the current java-type attribute if you introduced a new one, no matter what it was named. So, what would it be used for?
>
> If it's not used for anything else in your scheme, then let's use it for what it has always been used for and that is to specify the main java object type that will be used to represent a field, and in the case of supporting conversions it would be the one that we trying to convert to before setting in the JDBC API, and for getting the one we would use to get a specific object type from the JDBC API before possibly converting it to the object type requested by the calling code (if you plan to support that, possibly using existing GenericEntity.get* methods).
>
> In short, if we're changing the semantics, why does it matter what sort of interpretation you had before for the java-type attribute? Why not just use it instead of introducing something else that makes it tough to figure out what these things mean... since it sounds like there wouldn't be any sort of meaning for the java-type attribute any more.
>
> > Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> > ------------------------------------------------------------------------
> >
> > Key: OFBIZ-3245
> > URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> > Project: OFBiz
> > Issue Type: Improvement
> > Components: framework
> > Affects Versions: SVN trunk
> > Reporter: Adrian Crum
> > Assignee: Adrian Crum
> > Priority: Minor
> > Attachments: conversion.patch, conversion.patch, conversion.patch, conversion.patch
> >
> >
> > This issue contains a patch intended for evaluation before it is committed. See comments for details.
>
> --
> This message is automatically generated by JIRA.
> -
> You can reply to this email to add a comment to the issue online.
>
_________________________________________________________________
Bing brings you maps, menus, and reviews organized in one place.
http://www.bing.com/search?q=restaurants&form=MFESRP&publ=WLHMTAG&crea=TEXT_MFESRP_Local_MapsMenu_Resturants_1x1
[jira] Updated: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Adrian Crum (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Adrian Crum updated OFBIZ-3245:
-------------------------------
Attachment: conversion.patch
Updated patch based on David's suggestion.
fieldtypes*.xml files now accept a sql-object-type attribute. I updated the fieldtypesadvantage.xml file to demonstrate the difference.
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Erwan de FERRIERES (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12783427#action_12783427 ]
Erwan de FERRIERES commented on OFBIZ-3245:
-------------------------------------------
Adrian,
here is what I found :
[java] 2009-11-29 17:51:46,336 (main) [ModelFieldTypeReader.java:139:WARN ] JDBC data type 'BYTEA' for blob not found in fieldtypepostgres. Fields using this type will be ignored.
[java] 2009-11-29 17:51:46,336 (main) [ModelFieldTypeReader.java:139:WARN ] JDBC data type 'TIMESTAMPTZ' for date-time not found in fieldtypepostgres. Fields using this type will be ignored.
[java] 2009-11-29 17:51:46,413 (main) [ModelFieldTypeReader.java:139:WARN ] JDBC data type 'FLOAT8' for floating-point not found in fieldtypepostgres. Fields using this type will be ignored.
[java] 2009-11-29 17:51:46,414 (main) [ModelFieldTypeReader.java:139:WARN ] JDBC data type 'TEXT' for very-long not found in fieldtypepostgres. Fields using this type will be ignored.
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch, conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Adrian Crum (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12782107#action_12782107 ]
Adrian Crum commented on OFBIZ-3245:
------------------------------------
David,
I agree. Like I said, it looks like a kludge.
I'm sure you are aware that different database vendors are going to use different Java object types for fields, plus different vendors have different levels of JDBC support.
If you know of a better way to determine a driver's choice of object type for a particular field, then please share it.
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Adrian Crum (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12781091#action_12781091 ]
Adrian Crum commented on OFBIZ-3245:
------------------------------------
David,
Thank you so much for the review and comments! I will include them in whatever version makes its way into the trunk.
You said:
"Previously the Entity Engine expected you to pass a valid data type, would warn you if it wasn't what was expected (according to the fieldtypes*.xml file that was active), and then pass it on as-is to the JDBC driver to handle, or to blow up on."
The change I'm trying to introduce is this: You can give the Entity Engine any Java data type, and it will attempt to get/store it. There is no need to "guess" what the driver expects. If the attempt fails, it is because the conversion is not logical, it is not because there is some preconceived idea of what is acceptable.
As far as performance on switch statements is concerned, I have written C++ code that is similar and I'm pretty sure that complicated conditionals are not "free." I have not evaluated Java switch statements, so I might be wrong.
By the way, what database did you evaluate this with? I need as much input as I can get.
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Adrian Crum (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12782140#action_12782140 ]
Adrian Crum commented on OFBIZ-3245:
------------------------------------
Okay, how about a sql-object-type attribute? The current sql-type attribute contains the type needed for a CREATE statement, and what I need is the Java object type the database vendor uses to represent it.
For example, Derby uses BigDecimal for the numeric type, so it would look something like:
{code}
<field-type-def type="numeric" sql-type="NUMERIC(20,0)" sql-object-type="BigDecimal" java-type="Long"></field-type-def>
{code}
I could set it up as an optional attribute. In the absence of the sql-object-type attribute, the java-type attribute will be used.
The duration type would look like:
{code}
<field-type-def type="duration" sql-type="NUMERIC(20,0)" sql-object-type="BigDecimal" java-type="TimeDuration"></field-type-def>
{code}
What do you think?
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "David E. Jones (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12783206#action_12783206 ]
David E. Jones commented on OFBIZ-3245:
---------------------------------------
Then let's just use the java-type attribute, and not introduce a new one.
For most (all?) databases this means that no changes will be needed to the fieldtype*.xml files.
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch, conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Adrian Crum (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12782544#action_12782544 ]
Adrian Crum commented on OFBIZ-3245:
------------------------------------
A good example of how the java-type attribute is not being used as intended: all fieldtypes*.xml files have the "numeric" field type set to a Java type of "Long." According to documentation I found online and elsewhere:
{{Database SQL type JDBC driver Java type
-------- ------------------ ---------------------
Advantage Integer java.lang.Integer
Derby NUMERIC(20,0) java.math.BigDecimal
MS SQL INT int
MySql DECIMAL(20,0) java.math.BigDecimal
Oracle NUMBER(20,0) java.math.BigDecimal}}
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Adrian Crum (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12783422#action_12783422 ]
Adrian Crum commented on OFBIZ-3245:
------------------------------------
David,
Agreed. I will make that change.
Erwan,
There should be a warning message before those messages that starts with "*** No converter found," - did you see any of those?
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch, conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Adrian Crum (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12790794#action_12790794 ]
Adrian Crum commented on OFBIZ-3245:
------------------------------------
Nathan,
I am confused. Are you saying the attached patch doesn't fix the problem?
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Adrian Crum (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Adrian Crum updated OFBIZ-3245:
-------------------------------
Attachment: conversion.patch
The attached patch integrates the new conversion code into the entity engine. The patch is a work in progress, so it isn't finished yet - I still need to do some cleanups and finish the JavaDocs.
It would really help if other developers could try out the patch with various databases to insure compatibility. I have tested it with Derby and Advantage. I would like for it to be tested with MySql and Postgres. Any help in this area would be greatly appreciated! Just apply the patch and run ant run-install. Check the log for any exceptions. Report any exceptions in this issue.
Summary
Using the converters with values retrieved from the database was easy - because the ResultSet can be queried for the object type of the field. Getting the converters to work when setting a value is tricky - because there is no easy way to know what object type the JDBC driver is expecting. There is a way to get that information from the PreparedStatement, but that method was introduced in JDBC 3, and not all drivers support JDBC 3.
The solution I came up with was to create an entity with every field type in it (EntityDataTypes). When the ModelFieldType objects are created, the EntityDataTypes entity is queried, and the information contained in the returned ResultSet is used to set up the correct object types for that JDBC driver. It looks like a kludge, but it is the only way I could come up with to create accurate conversions for any database.
This change might improve throughput - because the get and store operations are more direct - so there is no navigating long switch statements and additional conditional code.
Comments and suggestions are welcome!
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "David E. Jones (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12782130#action_12782130 ]
David E. Jones commented on OFBIZ-3245:
---------------------------------------
Mainly just put it in a file instead of in the db.
Also though, consider using what has been used in OFBiz since the beginning, and what everyone is used to: the fieldtypes*.xml files.
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "David E. Jones (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12781285#action_12781285 ]
David E. Jones commented on OFBIZ-3245:
---------------------------------------
In C++ or Java switch statements are pretty close to free... but I'm not sure what you mean by "complicated conditionals"... and if you mean a long series of switch statements then those are certainly more expensive, especially if each if clause involved a significant compare or prepare/compare operation. Still, it is nearly nothing compared to other things that impact performance more. It's not like we're writing something to go through millions of data points already loaded into memory...
No, I haven't tried to run it.
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Erwan de FERRIERES (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12781999#action_12781999 ]
Erwan de FERRIERES commented on OFBIZ-3245:
-------------------------------------------
I've got this error :
[java] 2009-11-24 16:31:24,812 (main) [ModelFieldTypeReader.java:131:ERROR]
[java] ---- exception report ----------------------------------------------------------
[java] SELECT * FROM OFBIZ.ENTITY_DATA_TYPES statement failed:
[java] Exception: org.ofbiz.entity.GenericDataSourceException
[java] Message: SQL Exception while executing the following:SELECT * FROM OFBIZ.ENTITY_DATA_TYPES (Table/View 'OFBIZ.ENTITY_DATA_TYPES' does not exist.)
[java] ---- cause ---------------------------------------------------------------------
[java] Exception: java.sql.SQLSyntaxErrorException
[java] Message: Table/View 'OFBIZ.ENTITY_DATA_TYPES' does not exist.
[java] ---- cause ---------------------------------------------------------------------
[java] Exception: org.apache.derby.impl.jdbc.EmbedSQLException
[java] Message: Table/View 'OFBIZ.ENTITY_DATA_TYPES' does not exist.
[java] ---- cause ---------------------------------------------------------------------
[java] Exception: org.apache.derby.iapi.error.StandardException
[java] Message: Table/View 'OFBIZ.ENTITY_DATA_TYPES' does not exist.
[java] ---- stack trace ---------------------------------------------------------------
[java] ERROR 42X05: Table/View 'OFBIZ.ENTITY_DATA_TYPES' does not exist.
[java] org.apache.derby.iapi.error.StandardException.newException(Unknown Source)
[java] org.apache.derby.impl.sql.compile.FromBaseTable.bindTableDescriptor(Unknown Source)
[java] org.apache.derby.impl.sql.compile.FromBaseTable.bindNonVTITables(Unknown Source)
[java] org.apache.derby.impl.sql.compile.FromList.bindTables(Unknown Source)
[java] org.apache.derby.impl.sql.compile.SelectNode.bindNonVTITables(Unknown Source)
[java] org.apache.derby.impl.sql.compile.DMLStatementNode.bindTables(Unknown Source)
[java] org.apache.derby.impl.sql.compile.DMLStatementNode.bind(Unknown Source)
[java] org.apache.derby.impl.sql.compile.CursorNode.bindStatement(Unknown Source)
[java] org.apache.derby.impl.sql.GenericStatement.prepMinion(Unknown Source)
[java] org.apache.derby.impl.sql.GenericStatement.prepare(Unknown Source)
[java] org.apache.derby.impl.sql.conn.GenericLanguageConnectionContext.prepareInternalStatement(Unknown Source)
[java] org.apache.derby.impl.jdbc.EmbedPreparedStatement.<init>(Unknown Source)
[java] org.apache.derby.impl.jdbc.EmbedPreparedStatement20.<init>(Unknown Source)
[java] org.apache.derby.impl.jdbc.EmbedPreparedStatement30.<init>(Unknown Source)
[java] org.apache.derby.impl.jdbc.EmbedPreparedStatement40.<init>(Unknown Source)
[java] org.apache.derby.jdbc.Driver40.newEmbedPreparedStatement(Unknown Source)
[java] org.apache.derby.impl.jdbc.EmbedConnection.prepareStatement(Unknown Source)
[java] org.apache.derby.impl.jdbc.EmbedConnection.prepareStatement(Unknown Source)
[java] org.apache.commons.dbcp.DelegatingConnection.prepareStatement(DelegatingConnection.java:291)
[java] org.apache.commons.dbcp.DelegatingConnection.prepareStatement(DelegatingConnection.java:291)
[java] org.ofbiz.entity.jdbc.SQLProcessor.prepareStatement(SQLProcessor.java:365)
[java] org.ofbiz.entity.jdbc.SQLProcessor.prepareStatement(SQLProcessor.java:342)
[java] org.ofbiz.entity.model.ModelFieldTypeReader.initializeFieldTypes(ModelFieldTypeReader.java:125)
[java] org.ofbiz.entity.GenericDelegator.<init>(GenericDelegator.java:269)
[java] org.ofbiz.entity.DelegatorFactoryImpl.getInstance(DelegatorFactoryImpl.java:43)
[java] org.ofbiz.entity.DelegatorFactoryImpl.getInstance(DelegatorFactoryImpl.java:25)
[java] org.ofbiz.base.util.UtilObject.getObjectFromFactory(UtilObject.java:181)
[java] org.ofbiz.entity.DelegatorFactory.getDelegator(DelegatorFactory.java:31)
[java] org.ofbiz.entityext.data.EntityDataLoadContainer.start(EntityDataLoadContainer.java:229)
[java] org.ofbiz.base.container.ContainerLoader.start(ContainerLoader.java:100)
[java] org.ofbiz.base.start.Start.startStartLoaders(Start.java:271)
[java] org.ofbiz.base.start.Start.startServer(Start.java:321)
[java] org.ofbiz.base.start.Start.start(Start.java:325)
[java] org.ofbiz.base.start.Start.main(Start.java:410)
[java] --------------------------------------------------------------------------------
[java]
and some
[java] 2009-11-24 16:58:16,549 (main) [ SqlJdbcUtil.java:510:INFO ] Unable to convert, falling back on switch statement
[java] 2009-11-24 16:58:16,550 (main) [ SqlJdbcUtil.java:510:INFO ] Unable to convert, falling back on switch statement
[java] 2009-11-24 16:58:16,550 (main) [ SqlJdbcUtil.java:510:INFO ] Unable to convert, falling back on switch statement
HTH,
Erwan
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Adrian Crum (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12782001#action_12782001 ]
Adrian Crum commented on OFBIZ-3245:
------------------------------------
Did you run ant run-install?
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Adrian Crum (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Adrian Crum updated OFBIZ-3245:
-------------------------------
Attachment: conversion.patch
Updated patch. This patch should fix the errors reported by Erwan and also an error reported by Jacopo when using Oracle.
I still need to use the new fieldtypes*.xml attribute. I improved the code to do a better job of guessing the JDBC data type of each field, but there are still cases where it must be specified.
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Adrian Crum (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12781470#action_12781470 ]
Adrian Crum commented on OFBIZ-3245:
------------------------------------
David,
I re-read your initial comment and you are correct - this change will affect things from the API point of view. Actually, that was my original goal.
The Java type specified in the fieldtypes*.xml files must be a Java class that the JDBC driver recognizes, otherwise an exception will be thrown. Let's say we want to add a new Java object type to the framework - like the TimeDuration that I'm trying get implemented. In the existing code, having something like
{code}
<field-type-def type="duration" sql-type="NUMERIC(20,0)" java-type="TimeDuration"></field-type-def>
{code}
won't work because the JDBC driver doesn't know what to do with a TimeDuration Java object type. Like you said, the TimeDuration object is passed to the JDBC driver as-is, and the result is it blows up.
So, this change will make the entity engine more flexible, more adaptable. Users will be able to introduce their own data types without having to change entity engine Java code.
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Erwan de FERRIERES (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12781836#action_12781836 ]
Erwan de FERRIERES commented on OFBIZ-3245:
-------------------------------------------
Adrian,
i'm working on a postgres databas, using java 1.6. But I will try with your update, during the day.
Cheers,
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Erwan de FERRIERES (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12798604#action_12798604 ]
Erwan de FERRIERES commented on OFBIZ-3245:
-------------------------------------------
Hi Adrian,
I tested your patch with postgreSQL, and I found some errors in the log when data is loaded. Here is a part of the log file, if needed, I can attach it to this issue.
[java] 2010-01-11 08:38:34,281 (main) [ EntitySaxReader.java:220:INFO ] Beginning import from URL: file:/home/erwan/workspace/ofbizTrunk/applications/content/data/ContentTypeData.xml
[java] 2010-01-11 08:38:34,281 (main) [ EntitySaxReader.java:258:INFO ] Transaction Timeout set to 2 hours (7200 seconds)
[java] 2010-01-11 08:38:34,861 (main) [ SqlJdbcUtil.java:751:INFO ]
[java] ---- exception report ----------------------------------------------------------
[java] Exception: javax.sql.rowset.serial.SerialException
[java] Message: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] ---- stack trace ---------------------------------------------------------------
[java] javax.sql.rowset.serial.SerialException: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] javax.sql.rowset.serial.SerialClob.getAsciiStream(SerialClob.java:195)
[java] org.postgresql.jdbc2.AbstractJdbc2Statement.setClob(AbstractJdbc2Statement.java:2980)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.ofbiz.entity.jdbc.SqlTypes$ClobSqlObjectHandler.castSetObject(SqlTypes.java:317)
[java] org.ofbiz.entity.jdbc.SqlTypes$HandlerDecorator.setObject(SqlTypes.java:225)
[java] org.ofbiz.entity.jdbc.SQLProcessor.setObject(SQLProcessor.java:540)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:748)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:727)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValues(SqlJdbcUtil.java:445)
[java] org.ofbiz.entity.datasource.GenericDAO.singleInsert(GenericDAO.java:172)
[java] org.ofbiz.entity.datasource.GenericDAO.insert(GenericDAO.java:119)
[java] org.ofbiz.entity.datasource.GenericHelperDAO.create(GenericHelperDAO.java:64)
[java] org.ofbiz.entity.GenericDelegator.create(GenericDelegator.java:810)
[java] org.ofbiz.entity.GenericDelegator.storeAll(GenericDelegator.java:1372)
[java] org.ofbiz.entity.util.EntitySaxReader.writeValues(EntitySaxReader.java:285)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:264)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:221)
[java] org.ofbiz.entity.util.EntityDataLoader.loadData(EntityDataLoader.java:213)
[java] org.ofbiz.entityext.data.EntityDataLoadContainer.start(EntityDataLoadContainer.java:382)
[java] org.ofbiz.base.container.ContainerLoader.start(ContainerLoader.java:100)
[java] org.ofbiz.base.start.Start.startStartLoaders(Start.java:272)
[java] org.ofbiz.base.start.Start.startServer(Start.java:322)
[java] org.ofbiz.base.start.Start.start(Start.java:326)
[java] org.ofbiz.base.start.Start.main(Start.java:411)
[java] --------------------------------------------------------------------------------
[java]
[java] 2010-01-11 08:38:34,862 (main) [ SqlJdbcUtil.java:754:INFO ] Unable to convert, falling back on switch statement
[java] 2010-01-11 08:38:34,883 (main) [ EntitySaxReader.java:277:INFO ] Finished 185 values from file:/home/erwan/workspace/ofbizTrunk/applications/content/data/ContentTypeData.xml
[java] 2010-01-11 08:38:34,883 (main) [ EntitySaxReader.java:220:INFO ] Beginning import from URL: file:/home/erwan/workspace/ofbizTrunk/applications/content/data/ContentOperationData.xml
[java] 2010-01-11 08:38:34,883 (main) [ EntitySaxReader.java:258:INFO ] Transaction Timeout set to 2 hours (7200 seconds)
[java] 2010-01-11 08:38:35,106 (main) [ EntitySaxReader.java:277:INFO ] Finished 97 values from file:/home/erwan/workspace/ofbizTrunk/applications/content/data/ContentOperationData.xml
[java] 2010-01-11 08:38:35,106 (main) [ EntitySaxReader.java:220:INFO ] Beginning import from URL: file:/home/erwan/workspace/ofbizTrunk/applications/content/data/MimeTypeData.xml
[java] 2010-01-11 08:38:35,107 (main) [ EntitySaxReader.java:258:INFO ] Transaction Timeout set to 2 hours (7200 seconds)
[java] Jan 11, 2010 8:38:35 AM java.util.logging.LogManager$RootLogger log
[java] INFO: XMLStreamReaderImpl: Data buffer increased to 16384
[java] Jan 11, 2010 8:38:35 AM java.util.logging.LogManager$RootLogger log
[java] INFO: XMLStreamReaderImpl: Data buffer increased to 32768
[java] Jan 11, 2010 8:38:35 AM java.util.logging.LogManager$RootLogger log
[java] INFO: XMLStreamReaderImpl: Data buffer increased to 65536
[java] 2010-01-11 08:38:35,367 (main) [ EntitySaxReader.java:277:INFO ] Finished 109 values from file:/home/erwan/workspace/ofbizTrunk/applications/content/data/MimeTypeData.xml
[java] 2010-01-11 08:38:35,368 (main) [ EntitySaxReader.java:220:INFO ] Beginning import from URL: file:/home/erwan/workspace/ofbizTrunk/applications/content/data/MimeTypeTemplate.xml
[java] 2010-01-11 08:38:35,368 (main) [ EntitySaxReader.java:258:INFO ] Transaction Timeout set to 2 hours (7200 seconds)
[java] 2010-01-11 08:38:35,391 (main) [ EntitySaxReader.java:277:INFO ] Finished 9 values from file:/home/erwan/workspace/ofbizTrunk/applications/content/data/MimeTypeTemplate.xml
[java] 2010-01-11 08:38:35,392 (main) [ EntitySaxReader.java:220:INFO ] Beginning import from URL: file:/home/erwan/workspace/ofbizTrunk/applications/content/data/DataCategoryData.xml
[java] 2010-01-11 08:38:35,393 (main) [ EntitySaxReader.java:258:INFO ] Transaction Timeout set to 2 hours (7200 seconds)
[java] 2010-01-11 08:38:35,427 (main) [ EntitySaxReader.java:277:INFO ] Finished 17 values from file:/home/erwan/workspace/ofbizTrunk/applications/content/data/DataCategoryData.xml
[java] 2010-01-11 08:38:35,427 (main) [ EntitySaxReader.java:220:INFO ] Beginning import from URL: file:/home/erwan/workspace/ofbizTrunk/applications/content/data/SeedBlogData.xml
[java] 2010-01-11 08:38:35,428 (main) [ EntitySaxReader.java:258:INFO ] Transaction Timeout set to 2 hours (7200 seconds)
[java] 2010-01-11 08:38:35,502 (main) [ EntitySaxReader.java:277:INFO ] Finished 1 values from file:/home/erwan/workspace/ofbizTrunk/applications/content/data/SeedBlogData.xml
[java] 2010-01-11 08:38:35,502 (main) [ EntitySaxReader.java:220:INFO ] Beginning import from URL: file:/home/erwan/workspace/ofbizTrunk/applications/content/data/TemplateData.xml
[java] 2010-01-11 08:38:35,502 (main) [ EntitySaxReader.java:258:INFO ] Transaction Timeout set to 2 hours (7200 seconds)
[java] 2010-01-11 08:38:35,607 (main) [ SqlJdbcUtil.java:751:INFO ]
[java] ---- exception report ----------------------------------------------------------
[java] Exception: javax.sql.rowset.serial.SerialException
[java] Message: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] ---- stack trace ---------------------------------------------------------------
[java] javax.sql.rowset.serial.SerialException: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] javax.sql.rowset.serial.SerialClob.getAsciiStream(SerialClob.java:195)
[java] org.postgresql.jdbc2.AbstractJdbc2Statement.setClob(AbstractJdbc2Statement.java:2980)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.ofbiz.entity.jdbc.SqlTypes$ClobSqlObjectHandler.castSetObject(SqlTypes.java:317)
[java] org.ofbiz.entity.jdbc.SqlTypes$HandlerDecorator.setObject(SqlTypes.java:225)
[java] org.ofbiz.entity.jdbc.SQLProcessor.setObject(SQLProcessor.java:540)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:748)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:727)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValues(SqlJdbcUtil.java:445)
[java] org.ofbiz.entity.datasource.GenericDAO.singleInsert(GenericDAO.java:172)
[java] org.ofbiz.entity.datasource.GenericDAO.insert(GenericDAO.java:119)
[java] org.ofbiz.entity.datasource.GenericHelperDAO.create(GenericHelperDAO.java:64)
[java] org.ofbiz.entity.GenericDelegator.create(GenericDelegator.java:810)
[java] org.ofbiz.entity.GenericDelegator.storeAll(GenericDelegator.java:1372)
[java] org.ofbiz.entity.util.EntitySaxReader.writeValues(EntitySaxReader.java:285)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:264)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:221)
[java] org.ofbiz.entity.util.EntityDataLoader.loadData(EntityDataLoader.java:213)
[java] org.ofbiz.entityext.data.EntityDataLoadContainer.start(EntityDataLoadContainer.java:382)
[java] org.ofbiz.base.container.ContainerLoader.start(ContainerLoader.java:100)
[java] org.ofbiz.base.start.Start.startStartLoaders(Start.java:272)
[java] org.ofbiz.base.start.Start.startServer(Start.java:322)
[java] org.ofbiz.base.start.Start.start(Start.java:326)
[java] org.ofbiz.base.start.Start.main(Start.java:411)
[java] --------------------------------------------------------------------------------
[java]
[java] 2010-01-11 08:38:35,608 (main) [ SqlJdbcUtil.java:754:INFO ] Unable to convert, falling back on switch statement
[java] 2010-01-11 08:38:35,621 (main) [ SqlJdbcUtil.java:506:ERROR]
[java] ---- exception report ----------------------------------------------------------
[java] Exception: org.postgresql.util.PSQLException
[java] Message: Bad value for type long : <#assign mapKey=wrapMapKey?if_exists/>
[java] <#assign subDataResourceId=wrapDataResourceId?if_exists/>
[java] <#assign subDataResourceTypeId=wrapDataResourceTypeId?if_exists/>
[java] <#assign contentIdTo=wrapContentIdTo?if_exists/>
[java] <#assign mimeTypeId=wrapMimeTypeId?if_exists/>
[java] <#assign subContentId=wrapSubContentId?if_exists/>
[java] <div id="divTwo" class="wrapOuter">
[java] <div class="tabletext">
[java] ${mapKey?if_exists}
[java] <a class="buttontext" href="javascript:lookupSubContent('<@o...@ofbizUrl>', '${contentIdTo?if_exists}','${mapKey?if_exists}', '${subDataResourceTypeId?if_exists}', '${mimeTypeId?if_exists}')">[Find]</a>
[java] <#assign ofbizRequest=""/>
[java] <#assign httpParams="contentIdTo=" + contentIdTo?if_exists + "&mapKey=" + mapKey?if_exists />
[java] <#if subDataResourceTypeId == "IMAGE_OBJECT">
[java] <#assign ofbizRequest="EditLayoutImage"/>
[java] <#else>
[java] <#if subDataResourceTypeId == "URL_RESOURCE">
[java] <#assign ofbizRequest="EditLayoutUrl"/>
[java] <#else>
[java] <#assign ofbizRequest="EditLayoutSubContent"/>
[java] </#if>
[java] </#if>
[java] <a class="buttontext" href="<@o...@ofbizUrl>">[New]</a>
[java] <#if subContentId?exists && (0 < subContentId?length)>
[java] <a class="buttontext" href="<@o...@ofbizUrl>">[Edit]</a>
[java] </#if>
[java] </div>
[java] <div id="divOne" class="wrapInner">
[java] <@renderWrappedText/>
[java] </div>
[java] </div>
[java] ---- stack trace ---------------------------------------------------------------
[java] org.postgresql.util.PSQLException: Bad value for type long : <#assign mapKey=wrapMapKey?if_exists/>
[java] <#assign subDataResourceId=wrapDataResourceId?if_exists/>
[java] <#assign subDataResourceTypeId=wrapDataResourceTypeId?if_exists/>
[java] <#assign contentIdTo=wrapContentIdTo?if_exists/>
[java] <#assign mimeTypeId=wrapMimeTypeId?if_exists/>
[java] <#assign subContentId=wrapSubContentId?if_exists/>
[java] <div id="divTwo" class="wrapOuter">
[java] <div class="tabletext">
[java] ${mapKey?if_exists}
[java] <a class="buttontext" href="javascript:lookupSubContent('<@o...@ofbizUrl>', '${contentIdTo?if_exists}','${mapKey?if_exists}', '${subDataResourceTypeId?if_exists}', '${mimeTypeId?if_exists}')">[Find]</a>
[java] <#assign ofbizRequest=""/>
[java] <#assign httpParams="contentIdTo=" + contentIdTo?if_exists + "&mapKey=" + mapKey?if_exists />
[java] <#if subDataResourceTypeId == "IMAGE_OBJECT">
[java] <#assign ofbizRequest="EditLayoutImage"/>
[java] <#else>
[java] <#if subDataResourceTypeId == "URL_RESOURCE">
[java] <#assign ofbizRequest="EditLayoutUrl"/>
[java] <#else>
[java] <#assign ofbizRequest="EditLayoutSubContent"/>
[java] </#if>
[java] </#if>
[java] <a class="buttontext" href="<@o...@ofbizUrl>">[New]</a>
[java] <#if subContentId?exists && (0 < subContentId?length)>
[java] <a class="buttontext" href="<@o...@ofbizUrl>">[Edit]</a>
[java] </#if>
[java] </div>
[java] <div id="divOne" class="wrapInner">
[java] <@renderWrappedText/>
[java] </div>
[java] </div>
[java] org.postgresql.jdbc2.AbstractJdbc2ResultSet.toLong(AbstractJdbc2ResultSet.java:2796)
[java] org.postgresql.jdbc2.AbstractJdbc2ResultSet.getLong(AbstractJdbc2ResultSet.java:2019)
[java] org.postgresql.jdbc4.Jdbc4ResultSet.getClob(Jdbc4ResultSet.java:43)
[java] org.apache.commons.dbcp.DelegatingResultSet.getClob(DelegatingResultSet.java:553)
[java] org.apache.commons.dbcp.DelegatingResultSet.getClob(DelegatingResultSet.java:553)
[java] org.ofbiz.entity.jdbc.SqlTypes$ClobSqlObjectHandler.getObject(SqlTypes.java:321)
[java] org.ofbiz.entity.jdbc.SqlTypes$HandlerDecorator.getObject(SqlTypes.java:229)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.getValue(SqlJdbcUtil.java:503)
[java] org.ofbiz.entity.datasource.GenericDAO.select(GenericDAO.java:531)
[java] org.ofbiz.entity.datasource.GenericDAO.select(GenericDAO.java:493)
[java] org.ofbiz.entity.datasource.GenericHelperDAO.findByPrimaryKey(GenericHelperDAO.java:79)
[java] org.ofbiz.entity.GenericDelegator.storeAll(GenericDelegator.java:1362)
[java] org.ofbiz.entity.util.EntitySaxReader.writeValues(EntitySaxReader.java:285)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:264)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:221)
[java] org.ofbiz.entity.util.EntityDataLoader.loadData(EntityDataLoader.java:213)
[java] org.ofbiz.entityext.data.EntityDataLoadContainer.start(EntityDataLoadContainer.java:382)
[java] org.ofbiz.base.container.ContainerLoader.start(ContainerLoader.java:100)
[java] org.ofbiz.base.start.Start.startStartLoaders(Start.java:272)
[java] org.ofbiz.base.start.Start.startServer(Start.java:322)
[java] org.ofbiz.base.start.Start.start(Start.java:326)
[java] org.ofbiz.base.start.Start.main(Start.java:411)
[java] --------------------------------------------------------------------------------
[java]
[java] 2010-01-11 08:38:35,624 (main) [ SqlJdbcUtil.java:509:INFO ] Unable to convert, falling back on switch statement
[java] 2010-01-11 08:38:35,635 (main) [ SqlJdbcUtil.java:751:INFO ]
[java] ---- exception report ----------------------------------------------------------
[java] Exception: javax.sql.rowset.serial.SerialException
[java] Message: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] ---- stack trace ---------------------------------------------------------------
[java] javax.sql.rowset.serial.SerialException: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] javax.sql.rowset.serial.SerialClob.getAsciiStream(SerialClob.java:195)
[java] org.postgresql.jdbc2.AbstractJdbc2Statement.setClob(AbstractJdbc2Statement.java:2980)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.ofbiz.entity.jdbc.SqlTypes$ClobSqlObjectHandler.castSetObject(SqlTypes.java:317)
[java] org.ofbiz.entity.jdbc.SqlTypes$HandlerDecorator.setObject(SqlTypes.java:225)
[java] org.ofbiz.entity.jdbc.SQLProcessor.setObject(SQLProcessor.java:540)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:748)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:727)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValues(SqlJdbcUtil.java:445)
[java] org.ofbiz.entity.datasource.GenericDAO.singleUpdate(GenericDAO.java:276)
[java] org.ofbiz.entity.datasource.GenericDAO.customUpdate(GenericDAO.java:219)
[java] org.ofbiz.entity.datasource.GenericDAO.update(GenericDAO.java:213)
[java] org.ofbiz.entity.datasource.GenericHelperDAO.store(GenericHelperDAO.java:171)
[java] org.ofbiz.entity.GenericDelegator.store(GenericDelegator.java:1292)
[java] org.ofbiz.entity.GenericDelegator.storeAll(GenericDelegator.java:1398)
[java] org.ofbiz.entity.util.EntitySaxReader.writeValues(EntitySaxReader.java:285)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:264)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:221)
[java] org.ofbiz.entity.util.EntityDataLoader.loadData(EntityDataLoader.java:213)
[java] org.ofbiz.entityext.data.EntityDataLoadContainer.start(EntityDataLoadContainer.java:382)
[java] org.ofbiz.base.container.ContainerLoader.start(ContainerLoader.java:100)
[java] org.ofbiz.base.start.Start.startStartLoaders(Start.java:272)
[java] org.ofbiz.base.start.Start.startServer(Start.java:322)
[java] org.ofbiz.base.start.Start.start(Start.java:326)
[java] org.ofbiz.base.start.Start.main(Start.java:411)
[java] --------------------------------------------------------------------------------
[java]
[java] 2010-01-11 08:38:35,635 (main) [ SqlJdbcUtil.java:754:INFO ] Unable to convert, falling back on switch statement
[java] 2010-01-11 08:38:35,638 (main) [ SqlJdbcUtil.java:751:INFO ]
[java] ---- exception report ----------------------------------------------------------
[java] Exception: javax.sql.rowset.serial.SerialException
[java] Message: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] ---- stack trace ---------------------------------------------------------------
[java] javax.sql.rowset.serial.SerialException: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] javax.sql.rowset.serial.SerialClob.getAsciiStream(SerialClob.java:195)
[java] org.postgresql.jdbc2.AbstractJdbc2Statement.setClob(AbstractJdbc2Statement.java:2980)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.ofbiz.entity.jdbc.SqlTypes$ClobSqlObjectHandler.castSetObject(SqlTypes.java:317)
[java] org.ofbiz.entity.jdbc.SqlTypes$HandlerDecorator.setObject(SqlTypes.java:225)
[java] org.ofbiz.entity.jdbc.SQLProcessor.setObject(SQLProcessor.java:540)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:748)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:727)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValues(SqlJdbcUtil.java:445)
[java] org.ofbiz.entity.datasource.GenericDAO.singleInsert(GenericDAO.java:172)
[java] org.ofbiz.entity.datasource.GenericDAO.insert(GenericDAO.java:119)
[java] org.ofbiz.entity.datasource.GenericHelperDAO.create(GenericHelperDAO.java:64)
[java] org.ofbiz.entity.GenericDelegator.create(GenericDelegator.java:810)
[java] org.ofbiz.entity.GenericDelegator.storeAll(GenericDelegator.java:1372)
[java] org.ofbiz.entity.util.EntitySaxReader.writeValues(EntitySaxReader.java:285)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:264)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:221)
[java] org.ofbiz.entity.util.EntityDataLoader.loadData(EntityDataLoader.java:213)
[java] org.ofbiz.entityext.data.EntityDataLoadContainer.start(EntityDataLoadContainer.java:382)
[java] org.ofbiz.base.container.ContainerLoader.start(ContainerLoader.java:100)
[java] org.ofbiz.base.start.Start.startStartLoaders(Start.java:272)
[java] org.ofbiz.base.start.Start.startServer(Start.java:322)
[java] org.ofbiz.base.start.Start.start(Start.java:326)
[java] org.ofbiz.base.start.Start.main(Start.java:411)
[java] --------------------------------------------------------------------------------
[java]
[java] 2010-01-11 08:38:35,639 (main) [ SqlJdbcUtil.java:754:INFO ] Unable to convert, falling back on switch statement
[java] 2010-01-11 08:38:35,641 (main) [ SqlJdbcUtil.java:751:INFO ]
[java] ---- exception report ----------------------------------------------------------
[java] Exception: javax.sql.rowset.serial.SerialException
[java] Message: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] ---- stack trace ---------------------------------------------------------------
[java] javax.sql.rowset.serial.SerialException: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] javax.sql.rowset.serial.SerialClob.getAsciiStream(SerialClob.java:195)
[java] org.postgresql.jdbc2.AbstractJdbc2Statement.setClob(AbstractJdbc2Statement.java:2980)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.ofbiz.entity.jdbc.SqlTypes$ClobSqlObjectHandler.castSetObject(SqlTypes.java:317)
[java] org.ofbiz.entity.jdbc.SqlTypes$HandlerDecorator.setObject(SqlTypes.java:225)
[java] org.ofbiz.entity.jdbc.SQLProcessor.setObject(SQLProcessor.java:540)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:748)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:727)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValues(SqlJdbcUtil.java:445)
[java] org.ofbiz.entity.datasource.GenericDAO.singleInsert(GenericDAO.java:172)
[java] org.ofbiz.entity.datasource.GenericDAO.insert(GenericDAO.java:119)
[java] org.ofbiz.entity.datasource.GenericHelperDAO.create(GenericHelperDAO.java:64)
[java] org.ofbiz.entity.GenericDelegator.create(GenericDelegator.java:810)
[java] org.ofbiz.entity.GenericDelegator.storeAll(GenericDelegator.java:1372)
[java] org.ofbiz.entity.util.EntitySaxReader.writeValues(EntitySaxReader.java:285)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:264)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:221)
[java] org.ofbiz.entity.util.EntityDataLoader.loadData(EntityDataLoader.java:213)
[java] org.ofbiz.entityext.data.EntityDataLoadContainer.start(EntityDataLoadContainer.java:382)
[java] org.ofbiz.base.container.ContainerLoader.start(ContainerLoader.java:100)
[java] org.ofbiz.base.start.Start.startStartLoaders(Start.java:272)
[java] org.ofbiz.base.start.Start.startServer(Start.java:322)
[java] org.ofbiz.base.start.Start.start(Start.java:326)
[java] org.ofbiz.base.start.Start.main(Start.java:411)
[java] --------------------------------------------------------------------------------
[java]
[java] 2010-01-11 08:38:35,641 (main) [ SqlJdbcUtil.java:754:INFO ] Unable to convert, falling back on switch statement
[java] 2010-01-11 08:38:35,643 (main) [ SqlJdbcUtil.java:751:INFO ]
[java] ---- exception report ----------------------------------------------------------
[java] Exception: javax.sql.rowset.serial.SerialException
[java] Message: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] ---- stack trace ---------------------------------------------------------------
[java] javax.sql.rowset.serial.SerialException: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] javax.sql.rowset.serial.SerialClob.getAsciiStream(SerialClob.java:195)
[java] org.postgresql.jdbc2.AbstractJdbc2Statement.setClob(AbstractJdbc2Statement.java:2980)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.ofbiz.entity.jdbc.SqlTypes$ClobSqlObjectHandler.castSetObject(SqlTypes.java:317)
[java] org.ofbiz.entity.jdbc.SqlTypes$HandlerDecorator.setObject(SqlTypes.java:225)
[java] org.ofbiz.entity.jdbc.SQLProcessor.setObject(SQLProcessor.java:540)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:748)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:727)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValues(SqlJdbcUtil.java:445)
[java] org.ofbiz.entity.datasource.GenericDAO.singleInsert(GenericDAO.java:172)
[java] org.ofbiz.entity.datasource.GenericDAO.insert(GenericDAO.java:119)
[java] org.ofbiz.entity.datasource.GenericHelperDAO.create(GenericHelperDAO.java:64)
[java] org.ofbiz.entity.GenericDelegator.create(GenericDelegator.java:810)
[java] org.ofbiz.entity.GenericDelegator.storeAll(GenericDelegator.java:1372)
[java] org.ofbiz.entity.util.EntitySaxReader.writeValues(EntitySaxReader.java:285)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:264)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:221)
[java] org.ofbiz.entity.util.EntityDataLoader.loadData(EntityDataLoader.java:213)
[java] org.ofbiz.entityext.data.EntityDataLoadContainer.start(EntityDataLoadContainer.java:382)
[java] org.ofbiz.base.container.ContainerLoader.start(ContainerLoader.java:100)
[java] org.ofbiz.base.start.Start.startStartLoaders(Start.java:272)
[java] org.ofbiz.base.start.Start.startServer(Start.java:322)
[java] org.ofbiz.base.start.Start.start(Start.java:326)
[java] org.ofbiz.base.start.Start.main(Start.java:411)
[java] --------------------------------------------------------------------------------
[java]
[java] 2010-01-11 08:38:35,643 (main) [ SqlJdbcUtil.java:754:INFO ] Unable to convert, falling back on switch statement
[java] 2010-01-11 08:38:35,648 (main) [ SqlJdbcUtil.java:751:INFO ]
[java] ---- exception report ----------------------------------------------------------
[java] Exception: javax.sql.rowset.serial.SerialException
[java] Message: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] ---- stack trace ---------------------------------------------------------------
[java] javax.sql.rowset.serial.SerialException: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] javax.sql.rowset.serial.SerialClob.getAsciiStream(SerialClob.java:195)
[java] org.postgresql.jdbc2.AbstractJdbc2Statement.setClob(AbstractJdbc2Statement.java:2980)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.ofbiz.entity.jdbc.SqlTypes$ClobSqlObjectHandler.castSetObject(SqlTypes.java:317)
[java] org.ofbiz.entity.jdbc.SqlTypes$HandlerDecorator.setObject(SqlTypes.java:225)
[java] org.ofbiz.entity.jdbc.SQLProcessor.setObject(SQLProcessor.java:540)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:748)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:727)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValues(SqlJdbcUtil.java:445)
[java] org.ofbiz.entity.datasource.GenericDAO.singleInsert(GenericDAO.java:172)
[java] org.ofbiz.entity.datasource.GenericDAO.insert(GenericDAO.java:119)
[java] org.ofbiz.entity.datasource.GenericHelperDAO.create(GenericHelperDAO.java:64)
[java] org.ofbiz.entity.GenericDelegator.create(GenericDelegator.java:810)
[java] org.ofbiz.entity.GenericDelegator.storeAll(GenericDelegator.java:1372)
[java] org.ofbiz.entity.util.EntitySaxReader.writeValues(EntitySaxReader.java:285)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:264)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:221)
[java] org.ofbiz.entity.util.EntityDataLoader.loadData(EntityDataLoader.java:213)
[java] org.ofbiz.entityext.data.EntityDataLoadContainer.start(EntityDataLoadContainer.java:382)
[java] org.ofbiz.base.container.ContainerLoader.start(ContainerLoader.java:100)
[java] org.ofbiz.base.start.Start.startStartLoaders(Start.java:272)
[java] org.ofbiz.base.start.Start.startServer(Start.java:322)
[java] org.ofbiz.base.start.Start.start(Start.java:326)
[java] org.ofbiz.base.start.Start.main(Start.java:411)
[java] --------------------------------------------------------------------------------
[java]
[java] 2010-01-11 08:38:35,649 (main) [ SqlJdbcUtil.java:754:INFO ] Unable to convert, falling back on switch statement
[java] 2010-01-11 08:38:35,651 (main) [ SqlJdbcUtil.java:751:INFO ]
[java] ---- exception report ----------------------------------------------------------
[java] Exception: javax.sql.rowset.serial.SerialException
[java] Message: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] ---- stack trace ---------------------------------------------------------------
[java] javax.sql.rowset.serial.SerialException: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] javax.sql.rowset.serial.SerialClob.getAsciiStream(SerialClob.java:195)
[java] org.postgresql.jdbc2.AbstractJdbc2Statement.setClob(AbstractJdbc2Statement.java:2980)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.ofbiz.entity.jdbc.SqlTypes$ClobSqlObjectHandler.castSetObject(SqlTypes.java:317)
[java] org.ofbiz.entity.jdbc.SqlTypes$HandlerDecorator.setObject(SqlTypes.java:225)
[java] org.ofbiz.entity.jdbc.SQLProcessor.setObject(SQLProcessor.java:540)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:748)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:727)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValues(SqlJdbcUtil.java:445)
[java] org.ofbiz.entity.datasource.GenericDAO.singleInsert(GenericDAO.java:172)
[java] org.ofbiz.entity.datasource.GenericDAO.insert(GenericDAO.java:119)
[java] org.ofbiz.entity.datasource.GenericHelperDAO.create(GenericHelperDAO.java:64)
[java] org.ofbiz.entity.GenericDelegator.create(GenericDelegator.java:810)
[java] org.ofbiz.entity.GenericDelegator.storeAll(GenericDelegator.java:1372)
[java] org.ofbiz.entity.util.EntitySaxReader.writeValues(EntitySaxReader.java:285)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:264)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:221)
[java] org.ofbiz.entity.util.EntityDataLoader.loadData(EntityDataLoader.java:213)
[java] org.ofbiz.entityext.data.EntityDataLoadContainer.start(EntityDataLoadContainer.java:382)
[java] org.ofbiz.base.container.ContainerLoader.start(ContainerLoader.java:100)
[java] org.ofbiz.base.start.Start.startStartLoaders(Start.java:272)
[java] org.ofbiz.base.start.Start.startServer(Start.java:322)
[java] org.ofbiz.base.start.Start.start(Start.java:326)
[java] org.ofbiz.base.start.Start.main(Start.java:411)
[java] --------------------------------------------------------------------------------
[java]
[java] 2010-01-11 08:38:35,651 (main) [ SqlJdbcUtil.java:754:INFO ] Unable to convert, falling back on switch statement
[java] 2010-01-11 08:38:35,654 (main) [ SqlJdbcUtil.java:751:INFO ]
[java] ---- exception report ----------------------------------------------------------
[java] Exception: javax.sql.rowset.serial.SerialException
[java] Message: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] ---- stack trace ---------------------------------------------------------------
[java] javax.sql.rowset.serial.SerialException: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] javax.sql.rowset.serial.SerialClob.getAsciiStream(SerialClob.java:195)
[java] org.postgresql.jdbc2.AbstractJdbc2Statement.setClob(AbstractJdbc2Statement.java:2980)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.ofbiz.entity.jdbc.SqlTypes$ClobSqlObjectHandler.castSetObject(SqlTypes.java:317)
[java] org.ofbiz.entity.jdbc.SqlTypes$HandlerDecorator.setObject(SqlTypes.java:225)
[java] org.ofbiz.entity.jdbc.SQLProcessor.setObject(SQLProcessor.java:540)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:748)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:727)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValues(SqlJdbcUtil.java:445)
[java] org.ofbiz.entity.datasource.GenericDAO.singleInsert(GenericDAO.java:172)
[java] org.ofbiz.entity.datasource.GenericDAO.insert(GenericDAO.java:119)
[java] org.ofbiz.entity.datasource.GenericHelperDAO.create(GenericHelperDAO.java:64)
[java] org.ofbiz.entity.GenericDelegator.create(GenericDelegator.java:810)
[java] org.ofbiz.entity.GenericDelegator.storeAll(GenericDelegator.java:1372)
[java] org.ofbiz.entity.util.EntitySaxReader.writeValues(EntitySaxReader.java:285)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:264)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:221)
[java] org.ofbiz.entity.util.EntityDataLoader.loadData(EntityDataLoader.java:213)
[java] org.ofbiz.entityext.data.EntityDataLoadContainer.start(EntityDataLoadContainer.java:382)
[java] org.ofbiz.base.container.ContainerLoader.start(ContainerLoader.java:100)
[java] org.ofbiz.base.start.Start.startStartLoaders(Start.java:272)
[java] org.ofbiz.base.start.Start.startServer(Start.java:322)
[java] org.ofbiz.base.start.Start.start(Start.java:326)
[java] org.ofbiz.base.start.Start.main(Start.java:411)
[java] --------------------------------------------------------------------------------
[java]
[java] 2010-01-11 08:38:35,654 (main) [ SqlJdbcUtil.java:754:INFO ] Unable to convert, falling back on switch statement
[java] 2010-01-11 08:38:35,658 (main) [ SqlJdbcUtil.java:751:INFO ]
[java] ---- exception report ----------------------------------------------------------
[java] Exception: javax.sql.rowset.serial.SerialException
[java] Message: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] ---- stack trace ---------------------------------------------------------------
[java] javax.sql.rowset.serial.SerialException: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] javax.sql.rowset.serial.SerialClob.getAsciiStream(SerialClob.java:195)
[java] org.postgresql.jdbc2.AbstractJdbc2Statement.setClob(AbstractJdbc2Statement.java:2980)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.ofbiz.entity.jdbc.SqlTypes$ClobSqlObjectHandler.castSetObject(SqlTypes.java:317)
[java] org.ofbiz.entity.jdbc.SqlTypes$HandlerDecorator.setObject(SqlTypes.java:225)
[java] org.ofbiz.entity.jdbc.SQLProcessor.setObject(SQLProcessor.java:540)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:748)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:727)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValues(SqlJdbcUtil.java:445)
[java] org.ofbiz.entity.datasource.GenericDAO.singleInsert(GenericDAO.java:172)
[java] org.ofbiz.entity.datasource.GenericDAO.insert(GenericDAO.java:119)
[java] org.ofbiz.entity.datasource.GenericHelperDAO.create(GenericHelperDAO.java:64)
[java] org.ofbiz.entity.GenericDelegator.create(GenericDelegator.java:810)
[java] org.ofbiz.entity.GenericDelegator.storeAll(GenericDelegator.java:1372)
[java] org.ofbiz.entity.util.EntitySaxReader.writeValues(EntitySaxReader.java:285)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:264)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:221)
[java] org.ofbiz.entity.util.EntityDataLoader.loadData(EntityDataLoader.java:213)
[java] org.ofbiz.entityext.data.EntityDataLoadContainer.start(EntityDataLoadContainer.java:382)
[java] org.ofbiz.base.container.ContainerLoader.start(ContainerLoader.java:100)
[java] org.ofbiz.base.start.Start.startStartLoaders(Start.java:272)
[java] org.ofbiz.base.start.Start.startServer(Start.java:322)
[java] org.ofbiz.base.start.Start.start(Start.java:326)
[java] org.ofbiz.base.start.Start.main(Start.java:411)
[java] --------------------------------------------------------------------------------
[java]
[java] 2010-01-11 08:38:35,658 (main) [ SqlJdbcUtil.java:754:INFO ] Unable to convert, falling back on switch statement
[java] 2010-01-11 08:38:35,669 (main) [ SqlJdbcUtil.java:751:INFO ]
[java] ---- exception report ----------------------------------------------------------
[java] Exception: javax.sql.rowset.serial.SerialException
[java] Message: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] ---- stack trace ---------------------------------------------------------------
[java] javax.sql.rowset.serial.SerialException: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] javax.sql.rowset.serial.SerialClob.getAsciiStream(SerialClob.java:195)
[java] org.postgresql.jdbc2.AbstractJdbc2Statement.setClob(AbstractJdbc2Statement.java:2980)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.ofbiz.entity.jdbc.SqlTypes$ClobSqlObjectHandler.castSetObject(SqlTypes.java:317)
[java] org.ofbiz.entity.jdbc.SqlTypes$HandlerDecorator.setObject(SqlTypes.java:225)
[java] org.ofbiz.entity.jdbc.SQLProcessor.setObject(SQLProcessor.java:540)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:748)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:727)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValues(SqlJdbcUtil.java:445)
[java] org.ofbiz.entity.datasource.GenericDAO.singleInsert(GenericDAO.java:172)
[java] org.ofbiz.entity.datasource.GenericDAO.insert(GenericDAO.java:119)
[java] org.ofbiz.entity.datasource.GenericHelperDAO.create(GenericHelperDAO.java:64)
[java] org.ofbiz.entity.GenericDelegator.create(GenericDelegator.java:810)
[java] org.ofbiz.entity.GenericDelegator.storeAll(GenericDelegator.java:1372)
[java] org.ofbiz.entity.util.EntitySaxReader.writeValues(EntitySaxReader.java:285)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:264)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:221)
[java] org.ofbiz.entity.util.EntityDataLoader.loadData(EntityDataLoader.java:213)
[java] org.ofbiz.entityext.data.EntityDataLoadContainer.start(EntityDataLoadContainer.java:382)
[java] org.ofbiz.base.container.ContainerLoader.start(ContainerLoader.java:100)
[java] org.ofbiz.base.start.Start.startStartLoaders(Start.java:272)
[java] org.ofbiz.base.start.Start.startServer(Start.java:322)
[java] org.ofbiz.base.start.Start.start(Start.java:326)
[java] org.ofbiz.base.start.Start.main(Start.java:411)
[java] --------------------------------------------------------------------------------
[java]
[java] 2010-01-11 08:38:35,669 (main) [ SqlJdbcUtil.java:754:INFO ] Unable to convert, falling back on switch statement
[java] 2010-01-11 08:38:35,672 (main) [ SqlJdbcUtil.java:751:INFO ]
[java] ---- exception report ----------------------------------------------------------
[java] Exception: javax.sql.rowset.serial.SerialException
[java] Message: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] ---- stack trace ---------------------------------------------------------------
[java] javax.sql.rowset.serial.SerialException: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] javax.sql.rowset.serial.SerialClob.getAsciiStream(SerialClob.java:195)
[java] org.postgresql.jdbc2.AbstractJdbc2Statement.setClob(AbstractJdbc2Statement.java:2980)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.ofbiz.entity.jdbc.SqlTypes$ClobSqlObjectHandler.castSetObject(SqlTypes.java:317)
[java] org.ofbiz.entity.jdbc.SqlTypes$HandlerDecorator.setObject(SqlTypes.java:225)
[java] org.ofbiz.entity.jdbc.SQLProcessor.setObject(SQLProcessor.java:540)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:748)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:727)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValues(SqlJdbcUtil.java:445)
[java] org.ofbiz.entity.datasource.GenericDAO.singleInsert(GenericDAO.java:172)
[java] org.ofbiz.entity.datasource.GenericDAO.insert(GenericDAO.java:119)
[java] org.ofbiz.entity.datasource.GenericHelperDAO.create(GenericHelperDAO.java:64)
[java] org.ofbiz.entity.GenericDelegator.create(GenericDelegator.java:810)
[java] org.ofbiz.entity.GenericDelegator.storeAll(GenericDelegator.java:1372)
[java] org.ofbiz.entity.util.EntitySaxReader.writeValues(EntitySaxReader.java:285)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:264)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:221)
[java] org.ofbiz.entity.util.EntityDataLoader.loadData(EntityDataLoader.java:213)
[java] org.ofbiz.entityext.data.EntityDataLoadContainer.start(EntityDataLoadContainer.java:382)
[java] org.ofbiz.base.container.ContainerLoader.start(ContainerLoader.java:100)
[java] org.ofbiz.base.start.Start.startStartLoaders(Start.java:272)
[java] org.ofbiz.base.start.Start.startServer(Start.java:322)
[java] org.ofbiz.base.start.Start.start(Start.java:326)
[java] org.ofbiz.base.start.Start.main(Start.java:411)
[java] --------------------------------------------------------------------------------
[java]
[java] 2010-01-11 08:38:35,672 (main) [ SqlJdbcUtil.java:754:INFO ] Unable to convert, falling back on switch statement
[java] 2010-01-11 08:38:35,674 (main) [ SqlJdbcUtil.java:751:INFO ]
[java] ---- exception report ----------------------------------------------------------
[java] Exception: javax.sql.rowset.serial.SerialException
[java] Message: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] ---- stack trace ---------------------------------------------------------------
[java] javax.sql.rowset.serial.SerialException: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] javax.sql.rowset.serial.SerialClob.getAsciiStream(SerialClob.java:195)
[java] org.postgresql.jdbc2.AbstractJdbc2Statement.setClob(AbstractJdbc2Statement.java:2980)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.ofbiz.entity.jdbc.SqlTypes$ClobSqlObjectHandler.castSetObject(SqlTypes.java:317)
[java] org.ofbiz.entity.jdbc.SqlTypes$HandlerDecorator.setObject(SqlTypes.java:225)
[java] org.ofbiz.entity.jdbc.SQLProcessor.setObject(SQLProcessor.java:540)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:748)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:727)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValues(SqlJdbcUtil.java:445)
[java] org.ofbiz.entity.datasource.GenericDAO.singleInsert(GenericDAO.java:172)
[java] org.ofbiz.entity.datasource.GenericDAO.insert(GenericDAO.java:119)
[java] org.ofbiz.entity.datasource.GenericHelperDAO.create(GenericHelperDAO.java:64)
[java] org.ofbiz.entity.GenericDelegator.create(GenericDelegator.java:810)
[java] org.ofbiz.entity.GenericDelegator.storeAll(GenericDelegator.java:1372)
[java] org.ofbiz.entity.util.EntitySaxReader.writeValues(EntitySaxReader.java:285)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:264)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:221)
[java] org.ofbiz.entity.util.EntityDataLoader.loadData(EntityDataLoader.java:213)
[java] org.ofbiz.entityext.data.EntityDataLoadContainer.start(EntityDataLoadContainer.java:382)
[java] org.ofbiz.base.container.ContainerLoader.start(ContainerLoader.java:100)
[java] org.ofbiz.base.start.Start.startStartLoaders(Start.java:272)
[java] org.ofbiz.base.start.Start.startServer(Start.java:322)
[java] org.ofbiz.base.start.Start.start(Start.java:326)
[java] org.ofbiz.base.start.Start.main(Start.java:411)
[java] --------------------------------------------------------------------------------
[java]
[java] 2010-01-11 08:38:35,675 (main) [ SqlJdbcUtil.java:754:INFO ] Unable to convert, falling back on switch statement
[java] 2010-01-11 08:38:35,680 (main) [ SqlJdbcUtil.java:751:INFO ]
[java] ---- exception report ----------------------------------------------------------
[java] Exception: javax.sql.rowset.serial.SerialException
[java] Message: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] ---- stack trace ---------------------------------------------------------------
[java] javax.sql.rowset.serial.SerialException: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] javax.sql.rowset.serial.SerialClob.getAsciiStream(SerialClob.java:195)
[java] org.postgresql.jdbc2.AbstractJdbc2Statement.setClob(AbstractJdbc2Statement.java:2980)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.ofbiz.entity.jdbc.SqlTypes$ClobSqlObjectHandler.castSetObject(SqlTypes.java:317)
[java] org.ofbiz.entity.jdbc.SqlTypes$HandlerDecorator.setObject(SqlTypes.java:225)
[java] org.ofbiz.entity.jdbc.SQLProcessor.setObject(SQLProcessor.java:540)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:748)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:727)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValues(SqlJdbcUtil.java:445)
[java] org.ofbiz.entity.datasource.GenericDAO.singleInsert(GenericDAO.java:172)
[java] org.ofbiz.entity.datasource.GenericDAO.insert(GenericDAO.java:119)
[java] org.ofbiz.entity.datasource.GenericHelperDAO.create(GenericHelperDAO.java:64)
[java] org.ofbiz.entity.GenericDelegator.create(GenericDelegator.java:810)
[java] org.ofbiz.entity.GenericDelegator.storeAll(GenericDelegator.java:1372)
[java] org.ofbiz.entity.util.EntitySaxReader.writeValues(EntitySaxReader.java:285)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:264)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:221)
[java] org.ofbiz.entity.util.EntityDataLoader.loadData(EntityDataLoader.java:213)
[java] org.ofbiz.entityext.data.EntityDataLoadContainer.start(EntityDataLoadContainer.java:382)
[java] org.ofbiz.base.container.ContainerLoader.start(ContainerLoader.java:100)
[java] org.ofbiz.base.start.Start.startStartLoaders(Start.java:272)
[java] org.ofbiz.base.start.Start.startServer(Start.java:322)
[java] org.ofbiz.base.start.Start.start(Start.java:326)
[java] org.ofbiz.base.start.Start.main(Start.java:411)
[java] --------------------------------------------------------------------------------
[java]
[java] 2010-01-11 08:38:35,680 (main) [ SqlJdbcUtil.java:754:INFO ] Unable to convert, falling back on switch statement
[java] 2010-01-11 08:38:35,682 (main) [ SqlJdbcUtil.java:751:INFO ]
[java] ---- exception report ----------------------------------------------------------
[java] Exception: javax.sql.rowset.serial.SerialException
[java] Message: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] ---- stack trace ---------------------------------------------------------------
[java] javax.sql.rowset.serial.SerialException: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] javax.sql.rowset.serial.SerialClob.getAsciiStream(SerialClob.java:195)
[java] org.postgresql.jdbc2.AbstractJdbc2Statement.setClob(AbstractJdbc2Statement.java:2980)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.ofbiz.entity.jdbc.SqlTypes$ClobSqlObjectHandler.castSetObject(SqlTypes.java:317)
[java] org.ofbiz.entity.jdbc.SqlTypes$HandlerDecorator.setObject(SqlTypes.java:225)
[java] org.ofbiz.entity.jdbc.SQLProcessor.setObject(SQLProcessor.java:540)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:748)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:727)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValues(SqlJdbcUtil.java:445)
[java] org.ofbiz.entity.datasource.GenericDAO.singleInsert(GenericDAO.java:172)
[java] org.ofbiz.entity.datasource.GenericDAO.insert(GenericDAO.java:119)
[java] org.ofbiz.entity.datasource.GenericHelperDAO.create(GenericHelperDAO.java:64)
[java] org.ofbiz.entity.GenericDelegator.create(GenericDelegator.java:810)
[java] org.ofbiz.entity.GenericDelegator.storeAll(GenericDelegator.java:1372)
[java] org.ofbiz.entity.util.EntitySaxReader.writeValues(EntitySaxReader.java:285)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:264)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:221)
[java] org.ofbiz.entity.util.EntityDataLoader.loadData(EntityDataLoader.java:213)
[java] org.ofbiz.entityext.data.EntityDataLoadContainer.start(EntityDataLoadContainer.java:382)
[java] org.ofbiz.base.container.ContainerLoader.start(ContainerLoader.java:100)
[java] org.ofbiz.base.start.Start.startStartLoaders(Start.java:272)
[java] org.ofbiz.base.start.Start.startServer(Start.java:322)
[java] org.ofbiz.base.start.Start.start(Start.java:326)
[java] org.ofbiz.base.start.Start.main(Start.java:411)
[java] --------------------------------------------------------------------------------
[java]
[java] 2010-01-11 08:38:35,706 (main) [ SqlJdbcUtil.java:754:INFO ] Unable to convert, falling back on switch statement
[java] 2010-01-11 08:38:35,710 (main) [ SqlJdbcUtil.java:751:INFO ]
[java] ---- exception report ----------------------------------------------------------
[java] Exception: javax.sql.rowset.serial.SerialException
[java] Message: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] ---- stack trace ---------------------------------------------------------------
[java] javax.sql.rowset.serial.SerialException: Unsupported operation. SerialClob cannot return a the CLOB value as an ascii stream, unless instantiated with a fully implemented Clob object.
[java] javax.sql.rowset.serial.SerialClob.getAsciiStream(SerialClob.java:195)
[java] org.postgresql.jdbc2.AbstractJdbc2Statement.setClob(AbstractJdbc2Statement.java:2980)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.apache.commons.dbcp.DelegatingPreparedStatement.setClob(DelegatingPreparedStatement.java:187)
[java] org.ofbiz.entity.jdbc.SqlTypes$ClobSqlObjectHandler.castSetObject(SqlTypes.java:317)
[java] org.ofbiz.entity.jdbc.SqlTypes$HandlerDecorator.setObject(SqlTypes.java:225)
[java] org.ofbiz.entity.jdbc.SQLProcessor.setObject(SQLProcessor.java:540)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:748)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValue(SqlJdbcUtil.java:727)
[java] org.ofbiz.entity.jdbc.SqlJdbcUtil.setValues(SqlJdbcUtil.java:445)
[java] org.ofbiz.entity.datasource.GenericDAO.singleInsert(GenericDAO.java:172)
[java] org.ofbiz.entity.datasource.GenericDAO.insert(GenericDAO.java:119)
[java] org.ofbiz.entity.datasource.GenericHelperDAO.create(GenericHelperDAO.java:64)
[java] org.ofbiz.entity.GenericDelegator.create(GenericDelegator.java:810)
[java] org.ofbiz.entity.GenericDelegator.storeAll(GenericDelegator.java:1372)
[java] org.ofbiz.entity.util.EntitySaxReader.writeValues(EntitySaxReader.java:285)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:264)
[java] org.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:221)
[java] org.ofbiz.entity.util.EntityDataLoader.loadData(EntityDataLoader.java:213)
[java] org.ofbiz.entityext.data.EntityDataLoadContainer.start(EntityDataLoadContainer.java:382)
[java] org.ofbiz.base.container.ContainerLoader.start(ContainerLoader.java:100)
[java] org.ofbiz.base.start.Start.startStartLoaders(Start.java:272)
[java] org.ofbiz.base.start.Start.startServer(Start.java:322)
[java] org.ofbiz.base.start.Start.start(Start.java:326)
[java] org.ofbiz.base.start.Start.main(Start.java:411)
[java] --------------------------------------------------------------------------------
[java]
[java] 2010-01-11 08:38:35,711 (main) [ SqlJdbcUtil.java:754:INFO ] Unable to convert, falling back on switch statement
[java] 2010-01-11 08:38:35,718 (main) [ EntitySaxReader.java:277:INFO ] Finished 52 values from file:/home/erwan/workspace/ofbizTrunk/applications/content/data/TemplateData.xml
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Erwan de FERRIERES (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12783215#action_12783215 ]
Erwan de FERRIERES commented on OFBIZ-3245:
-------------------------------------------
Adrian,
The error I had before is now gone. But, when loading data in the postgres database, a lot of those lines are showing up
[java] 2009-11-28 08:08:08,335 (main) [ SqlJdbcUtil.java:754:INFO ] Unable to convert, falling back on switch statement
[java] 2009-11-28 08:08:08,335 (main) [ SqlJdbcUtil.java:754:INFO ] Unable to convert, falling back on switch statement
[java] 2009-11-28 08:08:08,335 (main) [ SqlJdbcUtil.java:754:INFO ] Unable to convert, falling back on switch statement
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch, conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Scott Gray (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12781047#action_12781047 ]
Scott Gray commented on OFBIZ-3245:
-----------------------------------
Hi Adrian
Looks like the patch is missing a couple of classes: SqlTypes and SqlObjectHandler.
Regards
Scott
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Issue Comment Edited: (OFBIZ-3245) Sandbox: Integrating The
New Conversion Framework Into The Entity Engine
Posted by "Adrian Crum (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12782481#action_12782481 ]
Adrian Crum edited comment on OFBIZ-3245 at 11/25/09 4:25 PM:
--------------------------------------------------------------
I'm sure I am the one who is confused. It appeared to me the java-type attribute was being used as a target object type for the framework. If it was originally intended to be the object type the JDBC driver is expecting, then that's not how it is being used today. Or the fieldtype*.xml files are very much out-of-date.
It appeared to me that the java-type attribute was a way of abstracting the database details, in effect saying "regardless of how this value in stored in the database, it will be xxx type when used in the framework." Based on your comment, I now know this is wrong, but like I said - that is how it is being used in the current code.
My inaccurate evaluation of the java-type's use actually makes more sense than the original intent. For example, what Java object type should you expect to get when you call GenericValue.get()? I always assumed it was the type specified in the java-type attribute. Using that attribute the way it was originally intended, I won't know what Java object type I will get - because each JDBC driver might return something different.
So, based on my misunderstanding of what that attribute was used for, this is how I pictured the changes proposed here working:
Database -> JDBC driver -> sql-object-type -> (converted to) java-type -> framework code
Last night I came up with a better name for the new attribute to help make things clearer:
Database -> JDBC driver -> jdbc-type -> (converted to) java-type -> framework code
In the majority of field types there is no conversion necessary. For example, all JDBC drivers are going to use the java.lang.String java object type for CHAR and VARCHAR, java.sql.Timestamp for TIMESTAMP, etc. But there are differences in how drivers handle some of the other SQL data types. It would be nice if client code didn't need to know about those differences.
was (Author: adrianc@hlmksw.com):
I'm sure I am the one who is confused. It appeared to me the java-type attribute was being used as a target object type for the framework. If it was originally intended to be the object type the JDBC driver is expecting, then that's not how it is being used today. Or the fieldtype*.xml files are very much out-of-date.
It appeared to me that the java-type attribute was a way of abstracting the database details, in effect saying "regardless of how this value in stored in the database, it will be xxx type when used in the framework." Based on your comment, I now know this is wrong, but like I said - that is how it is being used in the current code.
My inaccurate evaluation of the java-type's use actually makes more sense than the original intent. For example, what Java object type should you expect to get when you call GenericValue.get()? I always assumed it was the type specified in the java-type attribute. Using that attribute the way it was originally intended, I won't know what Java object type I will get - because each JDBC driver might return something different.
So, based on my misunderstanding of what that attribute was used for, this is how I pictured the changes proposed here working:
Database -> JDBC driver -> sql-object-type (converted to) -> java-type -> framework code
Last night I came up with a better name for the new attribute to help make things clearer:
Database -> JDBC driver -> jdbc-type (converted to) -> java-type -> framework code
In the majority of field types there is no conversion necessary. For example, all JDBC drivers are going to use the java.lang.String java object type for CHAR and VARCHAR, java.sql.Timestamp for TIMESTAMP, etc. But there are differences in how drivers handle some of the other SQL data types. It would be nice if client code didn't need to know about those differences.
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Closed: (OFBIZ-3245) Sandbox: Integrating The New Conversion
Framework Into The Entity Engine
Posted by "Adrian Crum (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Adrian Crum closed OFBIZ-3245.
------------------------------
Resolution: Won't Fix
I'm closing this because the approach I tried to take caused issues with some JDBC drivers. Many thanks to everyone who helped out.
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Adrian Crum (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12781684#action_12781684 ]
Adrian Crum commented on OFBIZ-3245:
------------------------------------
Erwan,
The exception you reported was expected, because no Blob converters were developed. It should work with rev 883529. What database did you use?
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Adrian Crum (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Adrian Crum updated OFBIZ-3245:
-------------------------------
Attachment: conversion.patch
Updated patch. The new field-type attribute is called jdbc-data-type.
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch, conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "David E. Jones (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12782101#action_12782101 ]
David E. Jones commented on OFBIZ-3245:
---------------------------------------
Looking at the patch there isn't anything that populates the EntityDataTypes entity, which may be related to the problem Erwan is seeing.
I was looking at to see more about this idea of storing data types in the database... which I really don't like. That is a framework/technical level configuration and IMO it belongs in a file, NOT in the database.
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Adrian Crum (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Adrian Crum updated OFBIZ-3245:
-------------------------------
Attachment: conversion.patch
Updated patch. This should solve the Clob error messages.
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Adrian Crum (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12782545#action_12782545 ]
Adrian Crum commented on OFBIZ-3245:
------------------------------------
Bah. Jira's Wiki markup doesn't work. C&P the table into a monospaced font.
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Erwan de FERRIERES (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12781101#action_12781101 ]
Erwan de FERRIERES commented on OFBIZ-3245:
-------------------------------------------
Hi Adrian,
I've got this error on my machine :
[java] 2009-11-22 09:20:31,391 (main) [ Converters.java:91 :WARN ] *** No converter found, converting from [B to java.sql.Blob. Please report this message to the developer community so a suitable converter can be created. ***
[java] 2009-11-22 09:20:31,400 (main) [ModelFieldTypeReader.java:177:ERROR]
[java] ---- exception report ----------------------------------------------------------
[java] Exception: java.lang.ClassNotFoundException
[java] Message: No converter found for [B->java.sql.Blob
[java] ---- stack trace ---------------------------------------------------------------
[java] java.lang.ClassNotFoundException: No converter found for [B->java.sql.Blob
[java] org.ofbiz.base.conversion.Converters.getConverter(Converters.java:97)
[java] org.ofbiz.entity.jdbc.SqlTypes$HandlerDecorator.<init>(SqlTypes.java:202)
[java] org.ofbiz.entity.jdbc.SqlTypes.toSqlObjectHandler(SqlTypes.java:126)
[java] org.ofbiz.entity.model.ModelFieldTypeReader.initializeFieldTypes(ModelFieldTypeReader.java:175)
[java] org.ofbiz.entity.GenericDelegator.<init>(GenericDelegator.java:269)
[java] org.ofbiz.entity.DelegatorFactoryImpl.getInstance(DelegatorFactoryImpl.java:43)
[java] org.ofbiz.entity.DelegatorFactoryImpl.getInstance(DelegatorFactoryImpl.java:25)
[java] org.ofbiz.base.util.UtilObject.getObjectFromFactory(UtilObject.java:181)
[java] org.ofbiz.entity.DelegatorFactory.getDelegator(DelegatorFactory.java:31)
[java] org.ofbiz.entityext.data.EntityDataLoadContainer.start(EntityDataLoadContainer.java:229)
[java] org.ofbiz.base.container.ContainerLoader.start(ContainerLoader.java:100)
[java] org.ofbiz.base.start.Start.startStartLoaders(Start.java:271)
[java] org.ofbiz.base.start.Start.startServer(Start.java:321)
[java] org.ofbiz.base.start.Start.start(Start.java:325)
[java] org.ofbiz.base.start.Start.main(Start.java:410)
[java] --------------------------------------------------------------------------------
[java]
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Adrian Crum (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12783178#action_12783178 ]
Adrian Crum commented on OFBIZ-3245:
------------------------------------
David,
Thank you for continuing to participate in the discussion. I think all of your questions have already been answered in my previous comments.
Regardless of what the java-type attribute meant originally, it is not being used that way today - the proposed changes won't change that. The additional attribute is optional - if you don't understand it then just leave it out.
I still need this patch tested against other databases.
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch, conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Adrian Crum (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Adrian Crum updated OFBIZ-3245:
-------------------------------
Attachment: conversion.patch
Updated patch includes missing file. Thanks Scott!
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Adrian Crum (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12782481#action_12782481 ]
Adrian Crum commented on OFBIZ-3245:
------------------------------------
I'm sure I am the one who is confused. It appeared to me the java-type attribute was being used as a target object type for the framework. If it was originally intended to be the object type the JDBC driver is expecting, then that's not how it is being used today. Or the fieldtype*.xml files are very much out-of-date.
It appeared to me that the java-type attribute was a way of abstracting the database details, in effect saying "regardless of how this value in stored in the database, it will be xxx type when used in the framework." Based on your comment, I now know this is wrong, but like I said - that is how it is being used in the current code.
My inaccurate evaluation of the java-type's use actually makes more sense than the original intent. For example, what Java object type should you expect to get when you call GenericValue.get()? I always assumed it was the type specified in the java-type attribute. Using that attribute the way it was originally intended, I won't know what Java object type I will get - because each JDBC driver might return something different.
So, based on my misunderstanding of what that attribute was used for, this is how I pictured the changes proposed here working:
Database -> JDBC driver -> sql-object-type (converted to) -> java-type -> framework code
Last night I came up with a better name for the new attribute to help make things clearer:
Database -> JDBC driver -> jdbc-type (converted to) -> java-type -> framework code
In the majority of field types there is no conversion necessary. For example, all JDBC drivers are going to use the java.lang.String java object type for CHAR and VARCHAR, java.sql.Timestamp for TIMESTAMP, etc. But there are differences in how drivers handle some of the other SQL data types. It would be nice if client code didn't need to know about those differences.
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Jacopo Cappellato (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12858481#action_12858481 ]
Jacopo Cappellato commented on OFBIZ-3245:
------------------------------------------
Adrian,
unfortunately I didn't find time to test your patch.
However, I don't know if it helps or not, it seems that the Oracle error has been resolved by my customer with the following patch:
+ public static class OracleTIMESTAMPToTimestamp extends AbstractConverter<oracle.sql.TIMESTAMP, java.sql.Timestamp> {
+ public OracleTIMESTAMPToTimestamp() {
+ super(oracle.sql.TIMESTAMP.class, java.sql.Timestamp.class);
+ }
+
+ public java.sql.Timestamp convert(oracle.sql.TIMESTAMP obj) throws ConversionException {
+ try {
+ return obj.timestampValue();
+ } catch (Exception e) {
+ throw new ConversionException(e);
+ }
+ }
+ }
+
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Erwan de FERRIERES (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12782004#action_12782004 ]
Erwan de FERRIERES commented on OFBIZ-3245:
-------------------------------------------
yes, it was during the run-install. When I ran it with a derby database, no problem. But this error comes when I use the posgres driver
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "David E. Jones (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12781089#action_12781089 ]
David E. Jones commented on OFBIZ-3245:
---------------------------------------
This is an interesting change.
Just to clarify: this is a change in the way the Entity Engine works from an external (ie API usage). Previously the Entity Engine expected you to pass a valid data type, would warn you if it wasn't what was expected (according to the fieldtypes*.xml file that was active), and then pass it on as-is to the JDBC driver to handle, or to blow up on. After this change the Entity Engine will attempt to convert whatever is passed in to whatever the JDBC driver expects.
Quick question: why not just convert to the java-type specified in the fieldtypes*.xml file?
Performance comment: doing a data type check and possible data type conversion will always be slower than what was done before; on a side note long if/else blocks do take a number of operations to work through, but switch statements are as close to free as you can get in terms of performance (usually a single low-level operation to jump to the desired code block); either way the performance impact of this will be so small compared to more expensive operations that are commonly done, like serialization/network/deserialization that the JDBC driver and database have to do, that I wouldn't expect to see any noticeable difference in performance
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "David E. Jones (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12782951#action_12782951 ]
David E. Jones commented on OFBIZ-3245:
---------------------------------------
It sounds like you're still misunderstanding Adrian. Remember that you are adding the idea of supporting multiple object types externally, and that didn't exist before. The Entity Engine previously dealt with only one object type for each field type, and that object type was the same for the external API as it was for the JDBC driver.
This was done by using the JDBC API to set a specific type of object when writing, and also using the JDBC API to get a specific type of object when reading. There is nothing that just does a get and lets the JDBC driver choose what sort of object to return.
So, in other words there was only a need for one object type.
With what you have going now, I still think there is only a need for one java object type. Having multiple attributes for this would be confusing, or at least it is to me...
I still don't see an answer to the question of what you would do with the current java-type attribute if you introduced a new one, no matter what it was named. So, what would it be used for?
If it's not used for anything else in your scheme, then let's use it for what it has always been used for and that is to specify the main java object type that will be used to represent a field, and in the case of supporting conversions it would be the one that we trying to convert to before setting in the JDBC API, and for getting the one we would use to get a specific object type from the JDBC API before possibly converting it to the object type requested by the calling code (if you plan to support that, possibly using existing GenericEntity.get* methods).
In short, if we're changing the semantics, why does it matter what sort of interpretation you had before for the java-type attribute? Why not just use it instead of introducing something else that makes it tough to figure out what these things mean... since it sounds like there wouldn't be any sort of meaning for the java-type attribute any more.
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch, conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "David E. Jones (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12782321#action_12782321 ]
David E. Jones commented on OFBIZ-3245:
---------------------------------------
Actually the java-type IS the object that the database driver expects. Historically it has only been used to check the incoming type and log a warning if they are different.
Why not just use the java-type attribute instead of introducing a new one?
Or, on the other hand, if the sql-object-type is what the conversion code will use, then what will the java-type be used for? Or am I getting this backward?
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Adrian Crum (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Adrian Crum updated OFBIZ-3245:
-------------------------------
Attachment: conversion.patch
Updated patch to latest trunk rev.
If any one is available to test the latest patch I would really appreciate it! It needs to be tested using Postgres and Oracle databases.
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Adrian Crum (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Adrian Crum updated OFBIZ-3245:
-------------------------------
Attachment: conversion.patch
Nathan,
Thank you for trying out the patch. The error you encountered was due to a bug in the patch. Please try the updated patch.
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Adrian Crum (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12858541#action_12858541 ]
Adrian Crum commented on OFBIZ-3245:
------------------------------------
Thanks Jacopo. I would prefer to keep OFBiz database-agnostic, so the code you suggested won't help.
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Adrian Crum (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12783430#action_12783430 ]
Adrian Crum commented on OFBIZ-3245:
------------------------------------
Erwan - thank you, that really helps!
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch, conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Nathan Liang (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12791175#action_12791175 ]
Nathan Liang commented on OFBIZ-3245:
-------------------------------------
Hi Adrian,
After applying the patch, we got these errors when doing ant run-install:
2009-12-16 11:28:45,937 (main) [ModelFieldTypeReader.java:148:WARN ] jdbc-data-type '.BIGDECIMAL' for currency-amount not found in fieldtypeoracle. Fields using this type will be ignored.
2009-12-16 11:28:45,937 (main) [ModelFieldTypeReader.java:148:WARN ] jdbc-data-type '.BIGDECIMAL' for currency-precise not found in fieldtypeoracle. Fields using this type will be ignored.
2009-12-16 11:28:45,937 (main) [ModelFieldTypeReader.java:148:WARN ] jdbc-data-type '.BIGDECIMAL' for fixed-point not found in fieldtypeoracle. Fields using this type will be ignored.
2009-12-16 11:28:45,953 (OFBiz_Shutdown_Hook) [ ContainerLoader.java:113:INFO ] Shutting down containers
Maybe we need more efforts on changing fieldtypeoracle.xml as well as other fieldtype*.xml to get oracle and other databases running. before these improvement get merged into trunk, we would like some temporary solution.
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OFBIZ-3245) Sandbox: Integrating The New
Conversion Framework Into The Entity Engine
Posted by "Nathan Liang (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OFBIZ-3245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12790630#action_12790630 ]
Nathan Liang commented on OFBIZ-3245:
-------------------------------------
Hi,
Here is our workaround for the converter error when using oracle, there are some hacks to get around that oracle driver returning non-standard object for JDBC type TIMESTAMP and DATE etc.
{noformat}
Index: framework/entity/src/org/ofbiz/entity/jdbc/SqlJdbcUtil.java
===================================================================
--- framework/entity/src/org/ofbiz/entity/jdbc/SqlJdbcUtil.java (revision 774)
+++ framework/entity/src/org/ofbiz/entity/jdbc/SqlJdbcUtil.java (working copy)
@@ -501,7 +501,7 @@
Object sourceObject = null;
try {
- sourceObject = rs.getObject(ind);
+ sourceObject = getResultSetValue(rs, ind);
if (sourceObject == null) {
entity.dangerousSetNoCheckButFast(curField, null);
return;
@@ -960,4 +960,30 @@
addValueSingle(buffer, field, value, params);
}
}
+
+ public static Object getResultSetValue(ResultSet rs, int index) throws SQLException {
+ Object obj = rs.getObject(index);
+ String className = null;
+ if (obj != null) {
+ className = obj.getClass().getName();
+ }
+ if (className != null &&
+ ("oracle.sql.TIMESTAMP".equals(className) ||
+ "oracle.sql.TIMESTAMPTZ".equals(className))) {
+ obj = rs.getTimestamp(index);
+ } else if (className != null && className.startsWith("oracle.sql.DATE")) {
+ String metaDataClassName = rs.getMetaData().getColumnClassName(index);
+ if ("java.sql.Timestamp".equals(metaDataClassName) ||
+ "oracle.sql.TIMESTAMP".equals(metaDataClassName)) {
+ obj = rs.getTimestamp(index);
+ } else {
+ obj = rs.getDate(index);
+ }
+ } else if (obj != null && obj instanceof java.sql.Date) {
+ if ("java.sql.Timestamp".equals(rs.getMetaData().getColumnClassName(index))) {
+ obj = rs.getTimestamp(index);
+ }
+ }
+ return obj;
+ }
}
{noformat}
thanks,
Nathan
> Sandbox: Integrating The New Conversion Framework Into The Entity Engine
> ------------------------------------------------------------------------
>
> Key: OFBIZ-3245
> URL: https://issues.apache.org/jira/browse/OFBIZ-3245
> Project: OFBiz
> Issue Type: Improvement
> Components: framework
> Affects Versions: SVN trunk
> Reporter: Adrian Crum
> Assignee: Adrian Crum
> Priority: Minor
> Attachments: conversion.patch, conversion.patch, conversion.patch, conversion.patch, conversion.patch
>
>
> This issue contains a patch intended for evaluation before it is committed. See comments for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.