Re: Derby to MYSQL connector location?

2018-09-13 Thread Taher Alkhateeb
Hi Shane,

Multiple options exist for you:
- Place the DB driver jar in $OFBIZ_HOME/lib
- Place the DB driver jar in "lib" directory of any component
- Add the DB driver as a dependency in build.gradle. Go to JCenter and
find the latest driver compatible with your database to achieve this
step.
On Thu, Sep 13, 2018 at 7:14 PM Shane F. MacIntyre
 wrote:
>
>
> OS: Ubuntu 18.04
> MYSQL Version: 5.7.23
>
> I added localmysql, localmysqolap and localmysqltenant databases to mysql 
> server with ofbiz user permissions added to them.
> I modified the entityengine.xml to reflect the delegator changes, and 
> verified that the datasource user and pass was right for the databases I had 
> created.
> I downloaded the latest JDBC connector from Oracle, but do not have the 
> /framework/entity/lib/jdbc path referenced in 
> https://cwiki.apache.org/confluence/display/OFBIZ/How+to+migrate+OfBiz+from+Derby+to+MySQL+database
>  .
> I do have /framework/entity/src/main/java/org/apache/ofbiz/entity/jdbc. So I 
> blindly tried putting the connector driver in there, but I get errors (see 
> snippet below).
>
> 2018-09-13 16:07:19,880 |OFBiz-JobPoller  |GenericDelegator  
> |E| Failure in findListIteratorByCondition operation for entity 
> [DynamicView]: org.apache.ofbiz.entity.GenericEntityException: 
> com.mysql.jdbc.Driver (com.mysql.jdbc.Driver). Rolling back transaction.
> org.apache.ofbiz.entity.GenericEntityException: com.mysql.jdbc.Driver 
> (com.mysql.jdbc.Driver)
> at 
> org.apache.ofbiz.entity.connection.DBCPConnectionFactory.getConnection(DBCPConnectionFactory.java:93)
>  ~[ofbiz.jar:?]
> at 
> org.apache.ofbiz.entity.transaction.GeronimoTransactionFactory.getConnection(GeronimoTransactionFactory.java:79)
>  ~[ofbiz.jar:?]
> at 
> org.apache.ofbiz.entity.jdbc.SQLProcessor.getConnection(SQLProcessor.java:260)
>  ~[ofbiz.jar:?]
> at 
> org.apache.ofbiz.entity.jdbc.SQLProcessor.prepareStatement(SQLProcessor.java:366)
>  ~[ofbiz.jar:?]
> at 
> org.apache.ofbiz.entity.datasource.GenericDAO.selectCountByCondition(GenericDAO.java:1105)
>  ~[ofbiz.jar:?]
> at 
> org.apache.ofbiz.entity.datasource.GenericDAO.selectCountByCondition(GenericDAO.java:1006)
>  ~[ofbiz.jar:?]
> at 
> org.apache.ofbiz.entity.datasource.GenericHelperDAO.findCountByCondition(GenericHelperDAO.java:149)
>  ~[ofbiz.jar:?]
> at 
> org.apache.ofbiz.entity.GenericDelegator.findCountByCondition(GenericDelegator.java:1657)
>  [ofbiz.jar:?]
> at 
> org.apache.ofbiz.service.job.JobManager.isAvailable(JobManager.java:154) 
> [ofbiz.jar:?]
> at 
> org.apache.ofbiz.service.job.JobPoller$JobManagerPoller.run(JobPoller.java:223)
>  [ofbiz.jar:?]
> at java.lang.Thread.run(Thread.java:748) [?:1.8.0_181]
> Caused by: java.lang.ClassNotFoundException: com.mysql.jdbc.Driver
> at java.net.URLClassLoader.findClass(URLClassLoader.java:381) 
> ~[?:1.8.0_181]
> at java.lang.ClassLoader.loadClass(ClassLoader.java:424) 
> ~[?:1.8.0_181]
> at java.lang.ClassLoader.loadClass(ClassLoader.java:357) 
> ~[?:1.8.0_181]
> at java.lang.Class.forName0(Native Method) ~[?:1.8.0_181]
> at java.lang.Class.forName(Class.java:348) ~[?:1.8.0_181]
> at 
> org.apache.ofbiz.entity.connection.DBCPConnectionFactory.getConnection(DBCPConnectionFactory.java:90)
>  ~[ofbiz.jar:?]
> ... 10 more
>
>
> Any help as to where to put the connector would be greatly appreciated.
>
> -Shane MacIntyre


Derby to MYSQL connector location?

2018-09-13 Thread Shane F. MacIntyre

OS: Ubuntu 18.04
MYSQL Version: 5.7.23

I added localmysql, localmysqolap and localmysqltenant databases to mysql 
server with ofbiz user permissions added to them.
I modified the entityengine.xml to reflect the delegator changes, and verified 
that the datasource user and pass was right for the databases I had created.
I downloaded the latest JDBC connector from Oracle, but do not have the 
/framework/entity/lib/jdbc path referenced in 
https://cwiki.apache.org/confluence/display/OFBIZ/How+to+migrate+OfBiz+from+Derby+to+MySQL+database
 .
I do have /framework/entity/src/main/java/org/apache/ofbiz/entity/jdbc. So I 
blindly tried putting the connector driver in there, but I get errors (see 
snippet below).

2018-09-13 16:07:19,880 |OFBiz-JobPoller  |GenericDelegator  
|E| Failure in findListIteratorByCondition operation for entity [DynamicView]: 
org.apache.ofbiz.entity.GenericEntityException: com.mysql.jdbc.Driver 
(com.mysql.jdbc.Driver). Rolling back transaction.
org.apache.ofbiz.entity.GenericEntityException: com.mysql.jdbc.Driver 
(com.mysql.jdbc.Driver)
at 
org.apache.ofbiz.entity.connection.DBCPConnectionFactory.getConnection(DBCPConnectionFactory.java:93)
 ~[ofbiz.jar:?]
at 
org.apache.ofbiz.entity.transaction.GeronimoTransactionFactory.getConnection(GeronimoTransactionFactory.java:79)
 ~[ofbiz.jar:?]
at 
org.apache.ofbiz.entity.jdbc.SQLProcessor.getConnection(SQLProcessor.java:260) 
~[ofbiz.jar:?]
at 
org.apache.ofbiz.entity.jdbc.SQLProcessor.prepareStatement(SQLProcessor.java:366)
 ~[ofbiz.jar:?]
at 
org.apache.ofbiz.entity.datasource.GenericDAO.selectCountByCondition(GenericDAO.java:1105)
 ~[ofbiz.jar:?]
at 
org.apache.ofbiz.entity.datasource.GenericDAO.selectCountByCondition(GenericDAO.java:1006)
 ~[ofbiz.jar:?]
at 
org.apache.ofbiz.entity.datasource.GenericHelperDAO.findCountByCondition(GenericHelperDAO.java:149)
 ~[ofbiz.jar:?]
at 
org.apache.ofbiz.entity.GenericDelegator.findCountByCondition(GenericDelegator.java:1657)
 [ofbiz.jar:?]
at 
org.apache.ofbiz.service.job.JobManager.isAvailable(JobManager.java:154) 
[ofbiz.jar:?]
at 
org.apache.ofbiz.service.job.JobPoller$JobManagerPoller.run(JobPoller.java:223) 
[ofbiz.jar:?]
at java.lang.Thread.run(Thread.java:748) [?:1.8.0_181]
Caused by: java.lang.ClassNotFoundException: com.mysql.jdbc.Driver
at java.net.URLClassLoader.findClass(URLClassLoader.java:381) 
~[?:1.8.0_181]
at java.lang.ClassLoader.loadClass(ClassLoader.java:424) ~[?:1.8.0_181]
at java.lang.ClassLoader.loadClass(ClassLoader.java:357) ~[?:1.8.0_181]
at java.lang.Class.forName0(Native Method) ~[?:1.8.0_181]
at java.lang.Class.forName(Class.java:348) ~[?:1.8.0_181]
at 
org.apache.ofbiz.entity.connection.DBCPConnectionFactory.getConnection(DBCPConnectionFactory.java:90)
 ~[ofbiz.jar:?]
... 10 more


Any help as to where to put the connector would be greatly appreciated.

-Shane MacIntyre


Re: Error Migrating Ofbiz from derby to mysql

2017-04-25 Thread Pranay Pandey
+1

On 24-Apr-2017 2:29 PM, "Taher Alkhateeb" <slidingfilame...@gmail.com>
wrote:

> Hello Craig,
>
> Given that you are now working on improving the documentation instead of
> asking questions, I think perhaps it makes more sense to move this
> discussion to dev@
>
> Cheers,
>
> Taher Alkhateeb
>
> On Mon, Apr 24, 2017 at 6:34 AM, Craig Parker <cr...@fossfolks.com> wrote:
>
> > Ok... With a couple corrections, this appears to work fine for me. I made
> > some changes starting around line 59.
> >
> > I also, accidentally, grabbed Lubuntu 17.04 (not 16.04) but I believe the
> > changes I had to make to this text file were just things I glossed over
> > anyway. Nothing jumps out at me as being specific to Ubuntu variants
> 16.04
> > or 17.04. I'm pretty sure if I went back into my Mint 18 install and
> looked
> > at command history, they'd be the same.
> >
> > Stuff I forgot and rushed through (so pay attention if you're eyes work
> > like mine) was forgetting to add credentials for the other (as in, not
> > ofbiz) two databases. That screwed me up for a half hour before I
> realized.
> > I do a genuine facepalm about once a month -- this was one of them...
> >
> > I also added how to get sample data vs a clean db. If anyone wants to
> > point out any errors, please do. I'm game for another facepalm. :)  I'd
> > also like to start polishing this for Sharon to use with whatever final
> > "install it in Ubuntu" guide we end up with in the end.
> >
> >
> >
> > On 04/22/2017 01:19 PM, Craig Parker wrote:
> >
> >> Howdy, Adeel. Have a gander at these are notes I sent off to a friend.
> >> I'm very sarcastic by nature, but I think I've cleaned most of the snark
> >> out of them...
> >>
> >> I've got an old box that's struggling with Mint/XFCE horsepower-wise, so
> >> I'm throwing a clean Lubuntu 16.04 on it today. I'll be running through
> >> this whole OFBiz procedure from scratch in the process to see if I
> missed
> >> anything, and I'll keep you posted.
> >>
> >> There are some "loading default vs clean data" messages in the group
> from
> >> earlier this week. The results of those discussions have not yet made it
> >> into my notes.
> >>
> >> I'm currently running Mint18 64bit (I believe this is the equivalent of
> >> Ubuntu 16.04), openjdk 1.8.0_121 (although I noticed this morning on
> >> someone's Windows box that Oracle has _131 out in the wild -- I've not
> run
> >> an apt-get update/upgrade for a few days on my own stuff to see if
> openjdk
> >> 131 is out there too), and MySQL 5.7.17
> >>
> >>
> >> On 04/22/2017 12:30 PM, Muhammad Adeel Zahid wrote:
> >>
> >>> Hi Craig,
> >>>
> >>>
> >>> Is it working for you on ubuntu/debian/mint using openjdk and mysql?
> Its
> >>> not working for me on ubuntu 16.04 TLS, mysql mysql Ver 14.14 Distrib
> >>> 5.7.11, for Linux (x86_64) using  EditLine wrapper.
> >>>
> >>>
> >>> However, it works fine when i switch to oracle jdk. Can you update me
> on
> >>> what version of mysql and ubuntu you were using? Also, are there any
> >>> changes to make in mysql.cnf or my.cnf?
> >>>
> >>>
> >>> Regards
> >>>
> >>> Adeel
> >>>
> >>>
> >>> 
> >>> From: Craig Parker <cr...@fossfolks.com>
> >>> Sent: Saturday, April 22, 2017 6:07:36 AM
> >>> To: user@ofbiz.apache.org
> >>> Subject: Re: Error Migrating Ofbiz from derby to mysql
> >>>
> >>> I've got a walkthrough in the works using openjdk and mysql, but for
> >>> ubuntu/debina/mint, not windows...
> >>>
> >>>
> >>> On 04/21/2017 04:53 PM, Muhammad Adeel Zahid wrote:
> >>>
> >>>> Yes, I was right. When I replaced openjdk-8 with oracle-jdk-8, the
> data
> >>>> loaded just fine. However, we are more interested in open source
> solution.
> >>>> Is there a way, I can run Ofbiz, with openjdk and mysql.
> >>>>
> >>>>
> >>>> Regards
> >>>>
> >>>> Adeel
> >>>>
> >>>> 
> >>>> From: Muhammad Adeel Zahid <16030...@lums.edu.pk>
> >>>> Sent: Friday, April 21, 2017 10:44:37

Re: Error Migrating Ofbiz from derby to mysql

2017-04-24 Thread Taher Alkhateeb
Hello Craig,

Given that you are now working on improving the documentation instead of
asking questions, I think perhaps it makes more sense to move this
discussion to dev@

Cheers,

Taher Alkhateeb

On Mon, Apr 24, 2017 at 6:34 AM, Craig Parker <cr...@fossfolks.com> wrote:

> Ok... With a couple corrections, this appears to work fine for me. I made
> some changes starting around line 59.
>
> I also, accidentally, grabbed Lubuntu 17.04 (not 16.04) but I believe the
> changes I had to make to this text file were just things I glossed over
> anyway. Nothing jumps out at me as being specific to Ubuntu variants 16.04
> or 17.04. I'm pretty sure if I went back into my Mint 18 install and looked
> at command history, they'd be the same.
>
> Stuff I forgot and rushed through (so pay attention if you're eyes work
> like mine) was forgetting to add credentials for the other (as in, not
> ofbiz) two databases. That screwed me up for a half hour before I realized.
> I do a genuine facepalm about once a month -- this was one of them...
>
> I also added how to get sample data vs a clean db. If anyone wants to
> point out any errors, please do. I'm game for another facepalm. :)  I'd
> also like to start polishing this for Sharon to use with whatever final
> "install it in Ubuntu" guide we end up with in the end.
>
>
>
> On 04/22/2017 01:19 PM, Craig Parker wrote:
>
>> Howdy, Adeel. Have a gander at these are notes I sent off to a friend.
>> I'm very sarcastic by nature, but I think I've cleaned most of the snark
>> out of them...
>>
>> I've got an old box that's struggling with Mint/XFCE horsepower-wise, so
>> I'm throwing a clean Lubuntu 16.04 on it today. I'll be running through
>> this whole OFBiz procedure from scratch in the process to see if I missed
>> anything, and I'll keep you posted.
>>
>> There are some "loading default vs clean data" messages in the group from
>> earlier this week. The results of those discussions have not yet made it
>> into my notes.
>>
>> I'm currently running Mint18 64bit (I believe this is the equivalent of
>> Ubuntu 16.04), openjdk 1.8.0_121 (although I noticed this morning on
>> someone's Windows box that Oracle has _131 out in the wild -- I've not run
>> an apt-get update/upgrade for a few days on my own stuff to see if openjdk
>> 131 is out there too), and MySQL 5.7.17
>>
>>
>> On 04/22/2017 12:30 PM, Muhammad Adeel Zahid wrote:
>>
>>> Hi Craig,
>>>
>>>
>>> Is it working for you on ubuntu/debian/mint using openjdk and mysql? Its
>>> not working for me on ubuntu 16.04 TLS, mysql mysql Ver 14.14 Distrib
>>> 5.7.11, for Linux (x86_64) using  EditLine wrapper.
>>>
>>>
>>> However, it works fine when i switch to oracle jdk. Can you update me on
>>> what version of mysql and ubuntu you were using? Also, are there any
>>> changes to make in mysql.cnf or my.cnf?
>>>
>>>
>>> Regards
>>>
>>> Adeel
>>>
>>>
>>> 
>>> From: Craig Parker <cr...@fossfolks.com>
>>> Sent: Saturday, April 22, 2017 6:07:36 AM
>>> To: user@ofbiz.apache.org
>>> Subject: Re: Error Migrating Ofbiz from derby to mysql
>>>
>>> I've got a walkthrough in the works using openjdk and mysql, but for
>>> ubuntu/debina/mint, not windows...
>>>
>>>
>>> On 04/21/2017 04:53 PM, Muhammad Adeel Zahid wrote:
>>>
>>>> Yes, I was right. When I replaced openjdk-8 with oracle-jdk-8, the data
>>>> loaded just fine. However, we are more interested in open source solution.
>>>> Is there a way, I can run Ofbiz, with openjdk and mysql.
>>>>
>>>>
>>>> Regards
>>>>
>>>> Adeel
>>>>
>>>> 
>>>> From: Muhammad Adeel Zahid <16030...@lums.edu.pk>
>>>> Sent: Friday, April 21, 2017 10:44:37 PM
>>>> To: user@ofbiz.apache.org
>>>> Subject: Re: Error Migrating Ofbiz from derby to mysql
>>>>
>>>> Hi Pranay Panday,
>>>>
>>>>
>>>> Thanks for the prompt response. I was trying your solution on different
>>>> systems and it worked great on windows machine. On windows, I have been
>>>> able to load demo data into mysql and run the application with mysql.
>>>> However, on debian and ubuntu machines, ofbiz can create database with all
>>>> 861 tables in ofbizdb and some other in tenant and olap dbs. But it fails
>>>> to 

Re: Error Migrating Ofbiz from derby to mysql

2017-04-23 Thread Craig Parker
Ok... With a couple corrections, this appears to work fine for me. I 
made some changes starting around line 59.


I also, accidentally, grabbed Lubuntu 17.04 (not 16.04) but I believe 
the changes I had to make to this text file were just things I glossed 
over anyway. Nothing jumps out at me as being specific to Ubuntu 
variants 16.04 or 17.04. I'm pretty sure if I went back into my Mint 18 
install and looked at command history, they'd be the same.


Stuff I forgot and rushed through (so pay attention if you're eyes work 
like mine) was forgetting to add credentials for the other (as in, not 
ofbiz) two databases. That screwed me up for a half hour before I 
realized. I do a genuine facepalm about once a month -- this was one of 
them...


I also added how to get sample data vs a clean db. If anyone wants to 
point out any errors, please do. I'm game for another facepalm. :)  I'd 
also like to start polishing this for Sharon to use with whatever final 
"install it in Ubuntu" guide we end up with in the end.



On 04/22/2017 01:19 PM, Craig Parker wrote:
Howdy, Adeel. Have a gander at these are notes I sent off to a friend. 
I'm very sarcastic by nature, but I think I've cleaned most of the 
snark out of them...


I've got an old box that's struggling with Mint/XFCE horsepower-wise, 
so I'm throwing a clean Lubuntu 16.04 on it today. I'll be running 
through this whole OFBiz procedure from scratch in the process to see 
if I missed anything, and I'll keep you posted.


There are some "loading default vs clean data" messages in the group 
from earlier this week. The results of those discussions have not yet 
made it into my notes.


I'm currently running Mint18 64bit (I believe this is the equivalent 
of Ubuntu 16.04), openjdk 1.8.0_121 (although I noticed this morning 
on someone's Windows box that Oracle has _131 out in the wild -- I've 
not run an apt-get update/upgrade for a few days on my own stuff to 
see if openjdk 131 is out there too), and MySQL 5.7.17



On 04/22/2017 12:30 PM, Muhammad Adeel Zahid wrote:

Hi Craig,


Is it working for you on ubuntu/debian/mint using openjdk and mysql? 
Its not working for me on ubuntu 16.04 TLS, mysql mysql Ver 14.14 
Distrib 5.7.11, for Linux (x86_64) using  EditLine wrapper.



However, it works fine when i switch to oracle jdk. Can you update me 
on what version of mysql and ubuntu you were using? Also, are there 
any changes to make in mysql.cnf or my.cnf?



Regards

Adeel



From: Craig Parker <cr...@fossfolks.com>
Sent: Saturday, April 22, 2017 6:07:36 AM
To: user@ofbiz.apache.org
Subject: Re: Error Migrating Ofbiz from derby to mysql

I've got a walkthrough in the works using openjdk and mysql, but for
ubuntu/debina/mint, not windows...


On 04/21/2017 04:53 PM, Muhammad Adeel Zahid wrote:
Yes, I was right. When I replaced openjdk-8 with oracle-jdk-8, the 
data loaded just fine. However, we are more interested in open 
source solution. Is there a way, I can run Ofbiz, with openjdk and 
mysql.



Regards

Adeel


From: Muhammad Adeel Zahid <16030...@lums.edu.pk>
Sent: Friday, April 21, 2017 10:44:37 PM
To: user@ofbiz.apache.org
Subject: Re: Error Migrating Ofbiz from derby to mysql

Hi Pranay Panday,


Thanks for the prompt response. I was trying your solution on 
different systems and it worked great on windows machine. On 
windows, I have been able to load demo data into mysql and run the 
application with mysql. However, on debian and ubuntu machines, 
ofbiz can create database with all 861 tables in ofbizdb and some 
other in tenant and olap dbs. But it fails to load demo data into 
db. There are many exceptions when inserting data into the db. Some 
of the example exceptions are .



org.xml.sax.SAXException: A transaction error occurred reading data
at 
org.apache.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:240) 
~[ofbiz.jar:?]
at 
org.apache.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:199) 
~[ofbiz.jar:?]
at 
org.apache.ofbiz.entity.util.EntityDataLoader.loadData(EntityDataLoader.java:257) 
[ofbiz.jar:?]
at 
org.apache.ofbiz.entityext.data.EntityDataLoadContainer.loadContainer(EntityDataLoadContainer.java:492) 
[ofbiz.jar:?]
at 
org.apache.ofbiz.entityext.data.EntityDataLoadContainer.start(EntityDataLoadContainer.java:246) 
[ofbiz.jar:?]
at 
org.apache.ofbiz.base.container.ContainerLoader.startLoadedContainers(ContainerLoader.java:155) 
[ofbiz.jar:?]
at 
org.apache.ofbiz.base.container.ContainerLoader.load(ContainerLoader.java:80) 
[ofbiz.jar:?]
at 
org.apache.ofbiz.base.start.StartupControlPanel.loadStartupLoaders(StartupControlPanel.java:240) 
[ofbiz.jar:?]
at 
org.apache.ofbiz.base.start.StartupControlPanel.start(StartupControlPanel.java:71) 
[ofbiz.jar:?]

at org.apache.ofbiz.base.start.Start.main(Start.java:84) [ofbiz.jar:?]
Caused by: org.apache.ofbiz.entity.GenericEntityException: 
org.apache.ofb

Re: Error Migrating Ofbiz from derby to mysql

2017-04-22 Thread Craig Parker
Howdy, Adeel. Have a gander at these are notes I sent off to a friend. 
I'm very sarcastic by nature, but I think I've cleaned most of the snark 
out of them...


I've got an old box that's struggling with Mint/XFCE horsepower-wise, so 
I'm throwing a clean Lubuntu 16.04 on it today. I'll be running through 
this whole OFBiz procedure from scratch in the process to see if I 
missed anything, and I'll keep you posted.


There are some "loading default vs clean data" messages in the group 
from earlier this week. The results of those discussions have not yet 
made it into my notes.


I'm currently running Mint18 64bit (I believe this is the equivalent of 
Ubuntu 16.04), openjdk 1.8.0_121 (although I noticed this morning on 
someone's Windows box that Oracle has _131 out in the wild -- I've not 
run an apt-get update/upgrade for a few days on my own stuff to see if 
openjdk 131 is out there too), and MySQL 5.7.17



On 04/22/2017 12:30 PM, Muhammad Adeel Zahid wrote:

Hi Craig,


Is it working for you on ubuntu/debian/mint using openjdk and mysql? Its not 
working for me on ubuntu 16.04 TLS, mysql mysql  Ver 14.14 Distrib 5.7.11, for 
Linux (x86_64) using  EditLine wrapper.


However, it works fine when i switch to oracle jdk. Can you update me on what 
version of mysql and ubuntu you were using? Also, are there any changes to make 
in mysql.cnf or my.cnf?


Regards

Adeel



From: Craig Parker <cr...@fossfolks.com>
Sent: Saturday, April 22, 2017 6:07:36 AM
To: user@ofbiz.apache.org
Subject: Re: Error Migrating Ofbiz from derby to mysql

I've got a walkthrough in the works using openjdk and mysql, but for
ubuntu/debina/mint, not windows...


On 04/21/2017 04:53 PM, Muhammad Adeel Zahid wrote:

Yes, I was right. When I replaced openjdk-8 with oracle-jdk-8, the data loaded 
just fine. However, we are more interested in open source solution. Is there a 
way, I can run Ofbiz, with openjdk and mysql.


Regards

Adeel


From: Muhammad Adeel Zahid <16030...@lums.edu.pk>
Sent: Friday, April 21, 2017 10:44:37 PM
To: user@ofbiz.apache.org
Subject: Re: Error Migrating Ofbiz from derby to mysql

Hi Pranay Panday,


Thanks for the prompt response. I was trying your solution on different systems 
and it worked great on windows machine. On windows, I have been able to load 
demo data into mysql and run the application with mysql. However, on debian and 
ubuntu machines, ofbiz can create database with all 861 tables in ofbizdb and 
some other in tenant and olap dbs. But it fails to load demo data into db. 
There are many exceptions when inserting data into the db. Some of the example 
exceptions are .


org.xml.sax.SAXException: A transaction error occurred reading data
at org.apache.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:240) 
~[ofbiz.jar:?]
at org.apache.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:199) 
~[ofbiz.jar:?]
at 
org.apache.ofbiz.entity.util.EntityDataLoader.loadData(EntityDataLoader.java:257)
 [ofbiz.jar:?]
at 
org.apache.ofbiz.entityext.data.EntityDataLoadContainer.loadContainer(EntityDataLoadContainer.java:492)
 [ofbiz.jar:?]
at 
org.apache.ofbiz.entityext.data.EntityDataLoadContainer.start(EntityDataLoadContainer.java:246)
 [ofbiz.jar:?]
at 
org.apache.ofbiz.base.container.ContainerLoader.startLoadedContainers(ContainerLoader.java:155)
 [ofbiz.jar:?]
at 
org.apache.ofbiz.base.container.ContainerLoader.load(ContainerLoader.java:80) 
[ofbiz.jar:?]
at 
org.apache.ofbiz.base.start.StartupControlPanel.loadStartupLoaders(StartupControlPanel.java:240)
 [ofbiz.jar:?]
at 
org.apache.ofbiz.base.start.StartupControlPanel.start(StartupControlPanel.java:71)
 [ofbiz.jar:?]
at org.apache.ofbiz.base.start.Start.main(Start.java:84) [ofbiz.jar:?]
Caused by: org.apache.ofbiz.entity.GenericEntityException: 
org.apache.ofbiz.entity.GenericEntityException: 
org.apache.ofbiz.entity.GenericEntityException: Error while inserting: 
[GenericEntity:WebSite][createdStamp,2017-04-21 
22:26:40.665(java.sql.Timestamp)][createdTxStamp,2017-04-21 
22:26:40.662(java.sql.Timestamp)][lastUpdatedStamp,2017-04-21 
22:26:40.665(java.sql.Timestamp)][lastUpdatedTxStamp,2017-04-21 
22:26:40.662(java.sql.Timestamp)][productStoreId,9100(java.lang.String)][siteName,Web
 POS 
Site(java.lang.String)][visualThemeSetId,BACKOFFICE(java.lang.String)][webSiteId,WebStorePos(java.lang.String)]
 (SQL Exception while executing the following:INSERT INTO WEB_SITE 
(WEB_SITE_ID, SITE_NAME, HTTP_HOST, HTTP_PORT, HTTPS_HOST, HTTPS_PORT, 
ENABLE_HTTPS, STANDARD_CONTENT_PREFIX, SECURE_CONTENT_PREFIX, COOKIE_DOMAIN, 
VISUAL_THEME_SET_ID, LAST_UPDATED_STAMP, LAST_UPDATED_TX_STAMP, CREATED_STAMP, 
CREATED_TX_STAMP, PRODUCT_STORE_ID, ALLOW_PRODUCT_STORE_CHANGE, 
HOSTED_PATH_ALIAS, IS_DEFAULT, DISPLAY_MAINTENANCE_PAGE) VALUES (?, ?, ?, ?, ?, 
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) (Cannot add or update a child row: 
a foreign key constraint fa

Re: Error Migrating Ofbiz from derby to mysql

2017-04-22 Thread Muhammad Adeel Zahid
Hi Craig,


Is it working for you on ubuntu/debian/mint using openjdk and mysql? Its not 
working for me on ubuntu 16.04 TLS, mysql mysql  Ver 14.14 Distrib 5.7.11, for 
Linux (x86_64) using  EditLine wrapper.


However, it works fine when i switch to oracle jdk. Can you update me on what 
version of mysql and ubuntu you were using? Also, are there any changes to make 
in mysql.cnf or my.cnf?


Regards

Adeel



From: Craig Parker <cr...@fossfolks.com>
Sent: Saturday, April 22, 2017 6:07:36 AM
To: user@ofbiz.apache.org
Subject: Re: Error Migrating Ofbiz from derby to mysql

I've got a walkthrough in the works using openjdk and mysql, but for
ubuntu/debina/mint, not windows...


On 04/21/2017 04:53 PM, Muhammad Adeel Zahid wrote:
> Yes, I was right. When I replaced openjdk-8 with oracle-jdk-8, the data 
> loaded just fine. However, we are more interested in open source solution. Is 
> there a way, I can run Ofbiz, with openjdk and mysql.
>
>
> Regards
>
> Adeel
>
> 
> From: Muhammad Adeel Zahid <16030...@lums.edu.pk>
> Sent: Friday, April 21, 2017 10:44:37 PM
> To: user@ofbiz.apache.org
> Subject: Re: Error Migrating Ofbiz from derby to mysql
>
> Hi Pranay Panday,
>
>
> Thanks for the prompt response. I was trying your solution on different 
> systems and it worked great on windows machine. On windows, I have been able 
> to load demo data into mysql and run the application with mysql. However, on 
> debian and ubuntu machines, ofbiz can create database with all 861 tables in 
> ofbizdb and some other in tenant and olap dbs. But it fails to load demo data 
> into db. There are many exceptions when inserting data into the db. Some of 
> the example exceptions are .
>
>
> org.xml.sax.SAXException: A transaction error occurred reading data
> at 
> org.apache.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:240) 
> ~[ofbiz.jar:?]
> at 
> org.apache.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:199) 
> ~[ofbiz.jar:?]
> at 
> org.apache.ofbiz.entity.util.EntityDataLoader.loadData(EntityDataLoader.java:257)
>  [ofbiz.jar:?]
> at 
> org.apache.ofbiz.entityext.data.EntityDataLoadContainer.loadContainer(EntityDataLoadContainer.java:492)
>  [ofbiz.jar:?]
> at 
> org.apache.ofbiz.entityext.data.EntityDataLoadContainer.start(EntityDataLoadContainer.java:246)
>  [ofbiz.jar:?]
> at 
> org.apache.ofbiz.base.container.ContainerLoader.startLoadedContainers(ContainerLoader.java:155)
>  [ofbiz.jar:?]
> at 
> org.apache.ofbiz.base.container.ContainerLoader.load(ContainerLoader.java:80) 
> [ofbiz.jar:?]
> at 
> org.apache.ofbiz.base.start.StartupControlPanel.loadStartupLoaders(StartupControlPanel.java:240)
>  [ofbiz.jar:?]
> at 
> org.apache.ofbiz.base.start.StartupControlPanel.start(StartupControlPanel.java:71)
>  [ofbiz.jar:?]
> at org.apache.ofbiz.base.start.Start.main(Start.java:84) [ofbiz.jar:?]
> Caused by: org.apache.ofbiz.entity.GenericEntityException: 
> org.apache.ofbiz.entity.GenericEntityException: 
> org.apache.ofbiz.entity.GenericEntityException: Error while inserting: 
> [GenericEntity:WebSite][createdStamp,2017-04-21 
> 22:26:40.665(java.sql.Timestamp)][createdTxStamp,2017-04-21 
> 22:26:40.662(java.sql.Timestamp)][lastUpdatedStamp,2017-04-21 
> 22:26:40.665(java.sql.Timestamp)][lastUpdatedTxStamp,2017-04-21 
> 22:26:40.662(java.sql.Timestamp)][productStoreId,9100(java.lang.String)][siteName,Web
>  POS 
> Site(java.lang.String)][visualThemeSetId,BACKOFFICE(java.lang.String)][webSiteId,WebStorePos(java.lang.String)]
>  (SQL Exception while executing the following:INSERT INTO WEB_SITE 
> (WEB_SITE_ID, SITE_NAME, HTTP_HOST, HTTP_PORT, HTTPS_HOST, HTTPS_PORT, 
> ENABLE_HTTPS, STANDARD_CONTENT_PREFIX, SECURE_CONTENT_PREFIX, COOKIE_DOMAIN, 
> VISUAL_THEME_SET_ID, LAST_UPDATED_STAMP, LAST_UPDATED_TX_STAMP, 
> CREATED_STAMP, CREATED_TX_STAMP, PRODUCT_STORE_ID, 
> ALLOW_PRODUCT_STORE_CHANGE, HOSTED_PATH_ALIAS, IS_DEFAULT, 
> DISPLAY_MAINTENANCE_PAGE) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, 
> ?, ?, ?, ?, ?, ?) (Cannot add or update a child row: a foreign key constraint 
> fails (`ofbiz`.`WEB_SITE`, CONSTRAINT `WEB_SITE_PRDS` FOREIGN KEY 
> (`PRODUCT_STORE_ID`) REFERENCES `PRODUCT_STORE` (`PRODUCT_STORE_ID` 
> (Error while inserting: [GenericEntity:WebSite][createdStamp,2017-04-21 
> 22:26:40.665(java.sql.Timestamp)][createdTxStamp,2017-04-21 
> 22:26:40.662(java.sql.Timestamp)][lastUpdatedStamp,2017-04-21 
> 22:26:40.665(java.sql.Timestamp)][lastUpdatedTxStamp,2017-04-21 
> 22:26:40.662(java.sql.Timestamp)][productStoreId,9100(java.lang.String)][siteName,Web
>  POS 
> Site(java.lang.String)][visualThemeSetId,BACKOFFICE(java.lang.String)][w

Re: Error Migrating Ofbiz from derby to mysql

2017-04-21 Thread Craig Parker
I've got a walkthrough in the works using openjdk and mysql, but for 
ubuntu/debina/mint, not windows...



On 04/21/2017 04:53 PM, Muhammad Adeel Zahid wrote:

Yes, I was right. When I replaced openjdk-8 with oracle-jdk-8, the data loaded 
just fine. However, we are more interested in open source solution. Is there a 
way, I can run Ofbiz, with openjdk and mysql.


Regards

Adeel


From: Muhammad Adeel Zahid <16030...@lums.edu.pk>
Sent: Friday, April 21, 2017 10:44:37 PM
To: user@ofbiz.apache.org
Subject: Re: Error Migrating Ofbiz from derby to mysql

Hi Pranay Panday,


Thanks for the prompt response. I was trying your solution on different systems 
and it worked great on windows machine. On windows, I have been able to load 
demo data into mysql and run the application with mysql. However, on debian and 
ubuntu machines, ofbiz can create database with all 861 tables in ofbizdb and 
some other in tenant and olap dbs. But it fails to load demo data into db. 
There are many exceptions when inserting data into the db. Some of the example 
exceptions are .


org.xml.sax.SAXException: A transaction error occurred reading data
at org.apache.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:240) 
~[ofbiz.jar:?]
at org.apache.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:199) 
~[ofbiz.jar:?]
at 
org.apache.ofbiz.entity.util.EntityDataLoader.loadData(EntityDataLoader.java:257)
 [ofbiz.jar:?]
at 
org.apache.ofbiz.entityext.data.EntityDataLoadContainer.loadContainer(EntityDataLoadContainer.java:492)
 [ofbiz.jar:?]
at 
org.apache.ofbiz.entityext.data.EntityDataLoadContainer.start(EntityDataLoadContainer.java:246)
 [ofbiz.jar:?]
at 
org.apache.ofbiz.base.container.ContainerLoader.startLoadedContainers(ContainerLoader.java:155)
 [ofbiz.jar:?]
at 
org.apache.ofbiz.base.container.ContainerLoader.load(ContainerLoader.java:80) 
[ofbiz.jar:?]
at 
org.apache.ofbiz.base.start.StartupControlPanel.loadStartupLoaders(StartupControlPanel.java:240)
 [ofbiz.jar:?]
at 
org.apache.ofbiz.base.start.StartupControlPanel.start(StartupControlPanel.java:71)
 [ofbiz.jar:?]
at org.apache.ofbiz.base.start.Start.main(Start.java:84) [ofbiz.jar:?]
Caused by: org.apache.ofbiz.entity.GenericEntityException: 
org.apache.ofbiz.entity.GenericEntityException: 
org.apache.ofbiz.entity.GenericEntityException: Error while inserting: 
[GenericEntity:WebSite][createdStamp,2017-04-21 
22:26:40.665(java.sql.Timestamp)][createdTxStamp,2017-04-21 
22:26:40.662(java.sql.Timestamp)][lastUpdatedStamp,2017-04-21 
22:26:40.665(java.sql.Timestamp)][lastUpdatedTxStamp,2017-04-21 
22:26:40.662(java.sql.Timestamp)][productStoreId,9100(java.lang.String)][siteName,Web
 POS 
Site(java.lang.String)][visualThemeSetId,BACKOFFICE(java.lang.String)][webSiteId,WebStorePos(java.lang.String)]
 (SQL Exception while executing the following:INSERT INTO WEB_SITE 
(WEB_SITE_ID, SITE_NAME, HTTP_HOST, HTTP_PORT, HTTPS_HOST, HTTPS_PORT, 
ENABLE_HTTPS, STANDARD_CONTENT_PREFIX, SECURE_CONTENT_PREFIX, COOKIE_DOMAIN, 
VISUAL_THEME_SET_ID, LAST_UPDATED_STAMP, LAST_UPDATED_TX_STAMP, CREATED_STAMP, 
CREATED_TX_STAMP, PRODUCT_STORE_ID, ALLOW_PRODUCT_STORE_CHANGE, 
HOSTED_PATH_ALIAS, IS_DEFAULT, DISPLAY_MAINTENANCE_PAGE) VALUES (?, ?, ?, ?, ?, 
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) (Cannot add or update a child row: 
a foreign key constraint fails (`ofbiz`.`WEB_SITE`, CONSTRAINT `WEB_SITE_PRDS` 
FOREIGN KEY (`PRODUCT_STORE_ID`) REFERENCES `PRODUCT_STORE` 
(`PRODUCT_STORE_ID` (Error while inserting: 
[GenericEntity:WebSite][createdStamp,2017-04-21 
22:26:40.665(java.sql.Timestamp)][createdTxStamp,2017-04-21 
22:26:40.662(java.sql.Timestamp)][lastUpdatedStamp,2017-04-21 
22:26:40.665(java.sql.Timestamp)][lastUpdatedTxStamp,2017-04-21 
22:26:40.662(java.sql.Timestamp)][productStoreId,9100(java.lang.String)][siteName,Web
 POS 
Site(java.lang.String)][visualThemeSetId,BACKOFFICE(java.lang.String)][webSiteId,WebStorePos(java.lang.String)]
 (SQL Exception while executing the following:INSERT INTO WEB_SITE 
(WEB_SITE_ID, SITE_NAME, HTTP_HOST, HTTP_PORT, HTTPS_HOST, HTTPS_PORT, 
ENABLE_HTTPS, STANDARD_CONTENT_PREFIX, SECURE_CONTENT_PREFIX, COOKIE_DOMAIN, 
VISUAL_THEME_SET_ID, LAST_UPDATED_STAMP, LAST_UPDATED_TX_STAMP, CREATED_STAMP, 
CREATED_TX_STAMP, PRODUCT_STORE_ID, ALLOW_PRODUCT_STORE_CHANGE, 
HOSTED_PATH_ALIAS, IS_DEFAULT, DISPLAY_MAINTENANCE_PAGE) VALUES (?, ?, ?, ?, ?, 
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) (Cannot add or update a child row: 
a foreign key constraint fails (`ofbiz`.`WEB_SITE`, CONSTRAINT `WEB_SITE_PRDS` 
FOREIGN KEY (`PRODUCT_STORE_ID`) REFERENCES `PRODUCT_STORE` 
(`PRODUCT_STORE_ID`) (org.apache.ofbiz.entity.GenericEntityException: Error 
while inserting: [GenericEntity:WebSite][createdStamp,2017-04-21 
22:26:40.665(java.sql.Timestamp)][createdTxStamp,2017-04-21 
22:26:40.662(java.sql.Timestamp)][lastUpdatedStamp,2017-04-21 
22:26:40.665(java.sql.Timestamp)][lastUpdatedTxStamp,2017-04-21 

Re: Error Migrating Ofbiz from derby to mysql

2017-04-21 Thread Muhammad Adeel Zahid
Yes, I was right. When I replaced openjdk-8 with oracle-jdk-8, the data loaded 
just fine. However, we are more interested in open source solution. Is there a 
way, I can run Ofbiz, with openjdk and mysql.


Regards

Adeel


From: Muhammad Adeel Zahid <16030...@lums.edu.pk>
Sent: Friday, April 21, 2017 10:44:37 PM
To: user@ofbiz.apache.org
Subject: Re: Error Migrating Ofbiz from derby to mysql

Hi Pranay Panday,


Thanks for the prompt response. I was trying your solution on different systems 
and it worked great on windows machine. On windows, I have been able to load 
demo data into mysql and run the application with mysql. However, on debian and 
ubuntu machines, ofbiz can create database with all 861 tables in ofbizdb and 
some other in tenant and olap dbs. But it fails to load demo data into db. 
There are many exceptions when inserting data into the db. Some of the example 
exceptions are .


org.xml.sax.SAXException: A transaction error occurred reading data
at org.apache.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:240) 
~[ofbiz.jar:?]
at org.apache.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:199) 
~[ofbiz.jar:?]
at 
org.apache.ofbiz.entity.util.EntityDataLoader.loadData(EntityDataLoader.java:257)
 [ofbiz.jar:?]
at 
org.apache.ofbiz.entityext.data.EntityDataLoadContainer.loadContainer(EntityDataLoadContainer.java:492)
 [ofbiz.jar:?]
at 
org.apache.ofbiz.entityext.data.EntityDataLoadContainer.start(EntityDataLoadContainer.java:246)
 [ofbiz.jar:?]
at 
org.apache.ofbiz.base.container.ContainerLoader.startLoadedContainers(ContainerLoader.java:155)
 [ofbiz.jar:?]
at 
org.apache.ofbiz.base.container.ContainerLoader.load(ContainerLoader.java:80) 
[ofbiz.jar:?]
at 
org.apache.ofbiz.base.start.StartupControlPanel.loadStartupLoaders(StartupControlPanel.java:240)
 [ofbiz.jar:?]
at 
org.apache.ofbiz.base.start.StartupControlPanel.start(StartupControlPanel.java:71)
 [ofbiz.jar:?]
at org.apache.ofbiz.base.start.Start.main(Start.java:84) [ofbiz.jar:?]
Caused by: org.apache.ofbiz.entity.GenericEntityException: 
org.apache.ofbiz.entity.GenericEntityException: 
org.apache.ofbiz.entity.GenericEntityException: Error while inserting: 
[GenericEntity:WebSite][createdStamp,2017-04-21 
22:26:40.665(java.sql.Timestamp)][createdTxStamp,2017-04-21 
22:26:40.662(java.sql.Timestamp)][lastUpdatedStamp,2017-04-21 
22:26:40.665(java.sql.Timestamp)][lastUpdatedTxStamp,2017-04-21 
22:26:40.662(java.sql.Timestamp)][productStoreId,9100(java.lang.String)][siteName,Web
 POS 
Site(java.lang.String)][visualThemeSetId,BACKOFFICE(java.lang.String)][webSiteId,WebStorePos(java.lang.String)]
 (SQL Exception while executing the following:INSERT INTO WEB_SITE 
(WEB_SITE_ID, SITE_NAME, HTTP_HOST, HTTP_PORT, HTTPS_HOST, HTTPS_PORT, 
ENABLE_HTTPS, STANDARD_CONTENT_PREFIX, SECURE_CONTENT_PREFIX, COOKIE_DOMAIN, 
VISUAL_THEME_SET_ID, LAST_UPDATED_STAMP, LAST_UPDATED_TX_STAMP, CREATED_STAMP, 
CREATED_TX_STAMP, PRODUCT_STORE_ID, ALLOW_PRODUCT_STORE_CHANGE, 
HOSTED_PATH_ALIAS, IS_DEFAULT, DISPLAY_MAINTENANCE_PAGE) VALUES (?, ?, ?, ?, ?, 
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) (Cannot add or update a child row: 
a foreign key constraint fails (`ofbiz`.`WEB_SITE`, CONSTRAINT `WEB_SITE_PRDS` 
FOREIGN KEY (`PRODUCT_STORE_ID`) REFERENCES `PRODUCT_STORE` 
(`PRODUCT_STORE_ID` (Error while inserting: 
[GenericEntity:WebSite][createdStamp,2017-04-21 
22:26:40.665(java.sql.Timestamp)][createdTxStamp,2017-04-21 
22:26:40.662(java.sql.Timestamp)][lastUpdatedStamp,2017-04-21 
22:26:40.665(java.sql.Timestamp)][lastUpdatedTxStamp,2017-04-21 
22:26:40.662(java.sql.Timestamp)][productStoreId,9100(java.lang.String)][siteName,Web
 POS 
Site(java.lang.String)][visualThemeSetId,BACKOFFICE(java.lang.String)][webSiteId,WebStorePos(java.lang.String)]
 (SQL Exception while executing the following:INSERT INTO WEB_SITE 
(WEB_SITE_ID, SITE_NAME, HTTP_HOST, HTTP_PORT, HTTPS_HOST, HTTPS_PORT, 
ENABLE_HTTPS, STANDARD_CONTENT_PREFIX, SECURE_CONTENT_PREFIX, COOKIE_DOMAIN, 
VISUAL_THEME_SET_ID, LAST_UPDATED_STAMP, LAST_UPDATED_TX_STAMP, CREATED_STAMP, 
CREATED_TX_STAMP, PRODUCT_STORE_ID, ALLOW_PRODUCT_STORE_CHANGE, 
HOSTED_PATH_ALIAS, IS_DEFAULT, DISPLAY_MAINTENANCE_PAGE) VALUES (?, ?, ?, ?, ?, 
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) (Cannot add or update a child row: 
a foreign key constraint fails (`ofbiz`.`WEB_SITE`, CONSTRAINT `WEB_SITE_PRDS` 
FOREIGN KEY (`PRODUCT_STORE_ID`) REFERENCES `PRODUCT_STORE` 
(`PRODUCT_STORE_ID`) (org.apache.ofbiz.entity.GenericEntityException: Error 
while inserting: [GenericEntity:WebSite][createdStamp,2017-04-21 
22:26:40.665(java.sql.Timestamp)][createdTxStamp,2017-04-21 
22:26:40.662(java.sql.Timestamp)][lastUpdatedStamp,2017-04-21 
22:26:40.665(java.sql.Timestamp)][lastUpdatedTxStamp,2017-04-21 
22:26:40.662(java.sql.Timestamp)][productStoreId,9100(java.lang.String)][siteName,Web
 POS 
Site(java.lang.String)][visualThemeSetId,BACKOFFICE(java.lang.String)][web

Re: Error Migrating Ofbiz from derby to mysql

2017-04-21 Thread Muhammad Adeel Zahid
Hi Pranay Panday,


Thanks for the prompt response. I was trying your solution on different systems 
and it worked great on windows machine. On windows, I have been able to load 
demo data into mysql and run the application with mysql. However, on debian and 
ubuntu machines, ofbiz can create database with all 861 tables in ofbizdb and 
some other in tenant and olap dbs. But it fails to load demo data into db. 
There are many exceptions when inserting data into the db. Some of the example 
exceptions are .


org.xml.sax.SAXException: A transaction error occurred reading data
at org.apache.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:240) 
~[ofbiz.jar:?]
at org.apache.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:199) 
~[ofbiz.jar:?]
at 
org.apache.ofbiz.entity.util.EntityDataLoader.loadData(EntityDataLoader.java:257)
 [ofbiz.jar:?]
at 
org.apache.ofbiz.entityext.data.EntityDataLoadContainer.loadContainer(EntityDataLoadContainer.java:492)
 [ofbiz.jar:?]
at 
org.apache.ofbiz.entityext.data.EntityDataLoadContainer.start(EntityDataLoadContainer.java:246)
 [ofbiz.jar:?]
at 
org.apache.ofbiz.base.container.ContainerLoader.startLoadedContainers(ContainerLoader.java:155)
 [ofbiz.jar:?]
at 
org.apache.ofbiz.base.container.ContainerLoader.load(ContainerLoader.java:80) 
[ofbiz.jar:?]
at 
org.apache.ofbiz.base.start.StartupControlPanel.loadStartupLoaders(StartupControlPanel.java:240)
 [ofbiz.jar:?]
at 
org.apache.ofbiz.base.start.StartupControlPanel.start(StartupControlPanel.java:71)
 [ofbiz.jar:?]
at org.apache.ofbiz.base.start.Start.main(Start.java:84) [ofbiz.jar:?]
Caused by: org.apache.ofbiz.entity.GenericEntityException: 
org.apache.ofbiz.entity.GenericEntityException: 
org.apache.ofbiz.entity.GenericEntityException: Error while inserting: 
[GenericEntity:WebSite][createdStamp,2017-04-21 
22:26:40.665(java.sql.Timestamp)][createdTxStamp,2017-04-21 
22:26:40.662(java.sql.Timestamp)][lastUpdatedStamp,2017-04-21 
22:26:40.665(java.sql.Timestamp)][lastUpdatedTxStamp,2017-04-21 
22:26:40.662(java.sql.Timestamp)][productStoreId,9100(java.lang.String)][siteName,Web
 POS 
Site(java.lang.String)][visualThemeSetId,BACKOFFICE(java.lang.String)][webSiteId,WebStorePos(java.lang.String)]
 (SQL Exception while executing the following:INSERT INTO WEB_SITE 
(WEB_SITE_ID, SITE_NAME, HTTP_HOST, HTTP_PORT, HTTPS_HOST, HTTPS_PORT, 
ENABLE_HTTPS, STANDARD_CONTENT_PREFIX, SECURE_CONTENT_PREFIX, COOKIE_DOMAIN, 
VISUAL_THEME_SET_ID, LAST_UPDATED_STAMP, LAST_UPDATED_TX_STAMP, CREATED_STAMP, 
CREATED_TX_STAMP, PRODUCT_STORE_ID, ALLOW_PRODUCT_STORE_CHANGE, 
HOSTED_PATH_ALIAS, IS_DEFAULT, DISPLAY_MAINTENANCE_PAGE) VALUES (?, ?, ?, ?, ?, 
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) (Cannot add or update a child row: 
a foreign key constraint fails (`ofbiz`.`WEB_SITE`, CONSTRAINT `WEB_SITE_PRDS` 
FOREIGN KEY (`PRODUCT_STORE_ID`) REFERENCES `PRODUCT_STORE` 
(`PRODUCT_STORE_ID` (Error while inserting: 
[GenericEntity:WebSite][createdStamp,2017-04-21 
22:26:40.665(java.sql.Timestamp)][createdTxStamp,2017-04-21 
22:26:40.662(java.sql.Timestamp)][lastUpdatedStamp,2017-04-21 
22:26:40.665(java.sql.Timestamp)][lastUpdatedTxStamp,2017-04-21 
22:26:40.662(java.sql.Timestamp)][productStoreId,9100(java.lang.String)][siteName,Web
 POS 
Site(java.lang.String)][visualThemeSetId,BACKOFFICE(java.lang.String)][webSiteId,WebStorePos(java.lang.String)]
 (SQL Exception while executing the following:INSERT INTO WEB_SITE 
(WEB_SITE_ID, SITE_NAME, HTTP_HOST, HTTP_PORT, HTTPS_HOST, HTTPS_PORT, 
ENABLE_HTTPS, STANDARD_CONTENT_PREFIX, SECURE_CONTENT_PREFIX, COOKIE_DOMAIN, 
VISUAL_THEME_SET_ID, LAST_UPDATED_STAMP, LAST_UPDATED_TX_STAMP, CREATED_STAMP, 
CREATED_TX_STAMP, PRODUCT_STORE_ID, ALLOW_PRODUCT_STORE_CHANGE, 
HOSTED_PATH_ALIAS, IS_DEFAULT, DISPLAY_MAINTENANCE_PAGE) VALUES (?, ?, ?, ?, ?, 
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) (Cannot add or update a child row: 
a foreign key constraint fails (`ofbiz`.`WEB_SITE`, CONSTRAINT `WEB_SITE_PRDS` 
FOREIGN KEY (`PRODUCT_STORE_ID`) REFERENCES `PRODUCT_STORE` 
(`PRODUCT_STORE_ID`) (org.apache.ofbiz.entity.GenericEntityException: Error 
while inserting: [GenericEntity:WebSite][createdStamp,2017-04-21 
22:26:40.665(java.sql.Timestamp)][createdTxStamp,2017-04-21 
22:26:40.662(java.sql.Timestamp)][lastUpdatedStamp,2017-04-21 
22:26:40.665(java.sql.Timestamp)][lastUpdatedTxStamp,2017-04-21 
22:26:40.662(java.sql.Timestamp)][productStoreId,9100(java.lang.String)][siteName,Web
 POS 
Site(java.lang.String)][visualThemeSetId,BACKOFFICE(java.lang.String)][webSiteId,WebStorePos(java.lang.String)]
 (SQL Exception while executing the following:INSERT INTO WEB_SITE 
(WEB_SITE_ID, SITE_NAME, HTTP_HOST, HTTP_PORT, HTTPS_HOST, HTTPS_PORT, 
ENABLE_HTTPS, STANDARD_CONTENT_PREFIX, SECURE_CONTENT_PREFIX, COOKIE_DOMAIN, 
VISUAL_THEME_SET_ID, LAST_UPDATED_STAMP, LAST_UPDATED_TX_STAMP, CREATED_STAMP, 
CREATED_TX_STAMP, PRODUCT_STORE_ID, ALLOW_PRODUCT_STORE_CHANGE, 
HOSTED_PATH_ALIAS, IS_DEFAULT, 

Re: Error Migrating Ofbiz from derby to mysql

2017-04-21 Thread Pranay Pandey
Hi Muhammad Adeel,

I tried connecting MySQL DB with OFBiz 16.11 and it worked without any
issues.
While copying and pasting details from the mentioned document, please be
careful that group name has been updated in 16.11, not a major change but
addition of apache. So it changed as:

org.ofbiz ==> org.apache.ofbiz

*org.ofbiz.olap ==> org.apache*.ofbiz.olap

*org.ofbiz.tenant ==> org.apache*.ofbiz.tenant

Here is a tutorial video on OFBiz YouTube channel that can help you
with this setup: https://www.youtube.com/watch?v=Lzmv0DCC5N4

Regarding adding connector jar, follow the instructions about adding
build dependency mentioned in the video. You can also add db jar
dependency in your OFBiz build.xml file, In video it has been
demonstrated by adding this dependency in custom component build.xml.

Please let us know how it goes.

Best regards,

Pranay Pandey
HotWax Systems
http://www.hotwaxsystems.com/

On Thu, Apr 20, 2017 at 7:16 PM, Muhammad Adeel Zahid <16030...@lums.edu.pk>
wrote:

> Hi community,
>
>
> I have been using ofbiz 16.11 (latest release) with derby for quite some
> time. Few days ago I started trying to migrate db from derby to mysql. I
> installed mysql 5.7 made the changes in my.ini (I am on windows 10, though
> I tried same on *nix machines with same error). I also created three dbs
> named ofbiz, ofbiztenant and ofbizolap and three users with same name and
> same password.
>
>
> For changes in entityengine.xml, I copy/pasted everything(mysql
> datasources and delegators) from this guide<https://cwiki.apache.
> org/confluence/display/OFBIZ/How+to+migrate+OFBiz+from+
> Derby+to+MySQL+database>. I have also put mysql-java-connector-6.0.6 in
> /framework/entity/lib/jdbc and added the same as runtime dependency in
> build.gradle.
>
>
> After doing all this when I run 'gradlew cleanAll loadDefault', I get the
> following errors
>
> |E| The declared group name org.apache.ofbiz.olap has no corresponding
> group-map in entityengine.xml
>
>
> and the following stacktrace
>
>
> java.util.concurrent.ExecutionException: java.lang.NullPointerException
> at java.util.concurrent.FutureTask.report(FutureTask.java:122)
> ~[?:1.8.0_121]
> at java.util.concurrent.FutureTask.get(FutureTask.java:192)
> ~[?:1.8.0_121]
> at 
> org.apache.ofbiz.entity.DelegatorFactory.getDelegator(DelegatorFactory.java:44)
> [ofbiz.jar:?]
> at org.apache.ofbiz.entityext.data.EntityDataLoadContainer.
> loadContainer(EntityDataLoadContainer.java:283) [ofbiz.jar:?]
> at org.apache.ofbiz.entityext.data.EntityDataLoadContainer.
> start(EntityDataLoadContainer.java:246) [ofbiz.jar:?]
> at org.apache.ofbiz.base.container.ContainerLoader.
> startLoadedContainers(ContainerLoader.java:155) [ofbiz.jar:?]
> at 
> org.apache.ofbiz.base.container.ContainerLoader.load(ContainerLoader.java:80)
> [ofbiz.jar:?]
> at org.apache.ofbiz.base.start.StartupControlPanel.
> loadStartupLoaders(StartupControlPanel.java:240) [ofbiz.jar:?]
> at 
> org.apache.ofbiz.base.start.StartupControlPanel.start(StartupControlPanel.java:71)
> [ofbiz.jar:?]
> at org.apache.ofbiz.base.start.Start.main(Start.java:84)
> [ofbiz.jar:?]
> Caused by: java.lang.NullPointerException
> at 
> org.apache.ofbiz.entity.GenericDelegator.getEntityFieldType(GenericDelegator.java:566)
> ~[ofbiz.jar:?]
> at 
> org.apache.ofbiz.entity.model.ModelEntityChecker.checkEntities(ModelEntityChecker.java:111)
> ~[ofbiz.jar:?]
> at 
> org.apache.ofbiz.entity.GenericDelegator.(GenericDelegator.java:229)
> ~[ofbiz.jar:?]
> at 
> org.apache.ofbiz.entity.DelegatorFactoryImpl.getInstance(DelegatorFactoryImpl.java:34)
> ~[ofbiz.jar:?]
> at 
> org.apache.ofbiz.entity.DelegatorFactoryImpl.getInstance(DelegatorFactoryImpl.java:25)
> ~[ofbiz.jar:?]
> at 
> org.apache.ofbiz.base.util.UtilObject.getObjectFromFactory(UtilObject.java:201)
> ~[ofbiz.jar:?]
> at org.apache.ofbiz.entity.DelegatorFactory$
> DelegatorConfigurable.call(DelegatorFactory.java:83) ~[ofbiz.jar:?]
> at org.apache.ofbiz.entity.DelegatorFactory$
> DelegatorConfigurable.call(DelegatorFactory.java:74) ~[ofbiz.jar:?]
> at java.util.concurrent.FutureTask.run(FutureTask.java:266)
> ~[?:1.8.0_121]
> at 
> java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
> ~[?:1.8.0_121]
> at java.util.concurrent.FutureTask.run(FutureTask.java:266)
> ~[?:1.8.0_121]
> at java.util.concurrent.ScheduledThreadPoolExecutor$
> ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180)
> ~[?:1.8.0_121]
> at java.util.concurrent.ScheduledThreadPoolExecutor$
> ScheduledFutureTas

Re: Error - Migrating from Derby to MySQL

2012-04-27 Thread arvind.kumar.avinash
If you are still stuck, do as instructed below:

I have used the following versions for this topic:

1. MySQL: mysql-5.5.23-winx64 (zip) - the topic is still valid for 32 bit
version
2. MySQL JDBC driver: mysql-connector-java-5.1.14-bin.jar - to be placed in
ofbiz-dir/framework/entity/lib/jdbc
3. OfBiz: apache-ofbiz-10.04

Step - I
C:\mysql-5.5.23-winx64\binmysql -u root
mysqlcreate database ofbiz;
mysqlcreate database ofbizolap;
mysqlcreate database ofbiztenant;
mysqluse mysql;
mysqlselect database();
mysqlcreate user ofbiz@localhost;
mysqlcreate user ofbizolap@localhost;
mysqlcreate user ofbiztenant@localhost;
mysqlupdate user set password=PASSWORD(ofbiz) where User='ofbiz';
mysqlupdate user set password=PASSWORD(ofbizolap) where User='ofbizolap';
mysqlupdate user set password=PASSWORD(ofbiztenant) where
User='ofbiztenant';
mysqlgrant all privileges on *.* to 'ofbiz'@localhost identified by
'ofbiz';
mysqlgrant all privileges on *.* to 'ofbizolap'@localhost identified by
'ofbizolap';
mysqlgrant all privileges on *.* to 'ofbiztenant'@localhost identified by
'ofbiztenant';

Step - II
Use webtools to export all data to XML:
a. Start OfBiz
b. Navigate to http://localhost:8080/catalog/
c. Go to ApplicationsWebTools
d. Go to section 'Entity XML Tools' and click the link 'XML Data Export All'
- export the data to a directory of your choice

Step - III
Stop OfBiz server
Create a backup of ofbiz-dir/framework/entity/config/entityengine.xml
Edit entityengine.xml as follows:
1. Add the following datasources below the datasource 'localmysql'
datasource name=localmysqlolap
helper-class=org.ofbiz.entity.datasource.GenericHelperDAO
field-type-name=mysql
check-on-start=true
add-missing-on-start=true
check-pks-on-start=false
use-foreign-keys=true
join-style=ansi-no-parenthesis
alias-view-columns=false
drop-fk-use-foreign-key-keyword=true
table-type=InnoDB
character-set=latin1
collate=latin1_general_cs
read-data reader-name=seed/
read-data reader-name=seed-initial/
read-data reader-name=demo/
read-data reader-name=ext/
inline-jdbc
jdbc-driver=com.mysql.jdbc.Driver
jdbc-uri=jdbc:mysql://127.0.0.1/ofbiz?autoReconnect=true
jdbc-username=ofbizolap
jdbc-password=ofbizolap
isolation-level=ReadCommitted
pool-minsize=2
pool-maxsize=250
time-between-eviction-runs-millis=60/
/datasource

datasource name=localmysqltenant
helper-class=org.ofbiz.entity.datasource.GenericHelperDAO
field-type-name=mysql
check-on-start=true
add-missing-on-start=true
check-pks-on-start=false
use-foreign-keys=true
join-style=ansi-no-parenthesis
alias-view-columns=false
drop-fk-use-foreign-key-keyword=true
table-type=InnoDB
character-set=latin1
collate=latin1_general_cs
read-data reader-name=seed/
read-data reader-name=seed-initial/
read-data reader-name=demo/
read-data reader-name=ext/
inline-jdbc
jdbc-driver=com.mysql.jdbc.Driver
jdbc-uri=jdbc:mysql://127.0.0.1/ofbiz?autoReconnect=true
jdbc-username=ofbiztenant
jdbc-password=ofbiztenant
isolation-level=ReadCommitted
pool-minsize=2
pool-maxsize=250
time-between-eviction-runs-millis=60/
/datasource
2. Replace derby with mysql in default, default-no-eca and test delegators
as follows:
delegator name=default entity-model-reader=main
entity-group-reader=main entity-eca-reader=main
distributed-cache-clear-enabled=false
group-map group-name=org.ofbiz datasource-name=localmysql/
group-map group-name=org.ofbiz.olap
datasource-name=localmysqlolap/
group-map group-name=org.ofbiz.tenant
datasource-name=localmysqltenant/
/delegator

delegator name=default-no-eca entity-model-reader=main
entity-group-reader=main entity-eca-reader=main
entity-eca-enabled=false distributed-cache-clear-enabled=false
group-map group-name=org.ofbiz datasource-name=localmysql/
group-map group-name=org.ofbiz.olap
datasource-name=localmysqlolap/
group-map group-name=org.ofbiz.tenant
datasource-name=localmysqltenant/
/delegator

delegator name=test entity-model-reader=main
entity-group-reader=main entity-eca-reader=main
group-map group-name=org.ofbiz datasource-name=localmysql/
group-map group-name=org.ofbiz.olap
datasource-name=localmysqlolap/
group-map group-name=org.ofbiz.tenant
datasource-name=localmysqltenant/
/delegator
3. Save this file 

Step -IV
1. Open ofbiz/framework/entity

Re: Error - Migrating from Derby to MySQL

2012-04-27 Thread Jacques Le Roux
Maybe you could add this as a tip at 
https://cwiki.apache.org/confluence/display/OFBIZ/FAQ+-+Tips+-+Tricks+-+Cookbook+-+HowTo


Jacques

From: arvind.kumar.avinash arvindkumar.avin...@hcl.com

If you are still stuck, do as instructed below:

I have used the following versions for this topic:

1. MySQL: mysql-5.5.23-winx64 (zip) - the topic is still valid for 32 bit
version
2. MySQL JDBC driver: mysql-connector-java-5.1.14-bin.jar - to be placed in
ofbiz-dir/framework/entity/lib/jdbc
3. OfBiz: apache-ofbiz-10.04

Step - I
C:\mysql-5.5.23-winx64\binmysql -u root
mysqlcreate database ofbiz;
mysqlcreate database ofbizolap;
mysqlcreate database ofbiztenant;
mysqluse mysql;
mysqlselect database();
mysqlcreate user ofbiz@localhost;
mysqlcreate user ofbizolap@localhost;
mysqlcreate user ofbiztenant@localhost;
mysqlupdate user set password=PASSWORD(ofbiz) where User='ofbiz';
mysqlupdate user set password=PASSWORD(ofbizolap) where User='ofbizolap';
mysqlupdate user set password=PASSWORD(ofbiztenant) where
User='ofbiztenant';
mysqlgrant all privileges on *.* to 'ofbiz'@localhost identified by
'ofbiz';
mysqlgrant all privileges on *.* to 'ofbizolap'@localhost identified by
'ofbizolap';
mysqlgrant all privileges on *.* to 'ofbiztenant'@localhost identified by
'ofbiztenant';

Step - II
Use webtools to export all data to XML:
a. Start OfBiz
b. Navigate to http://localhost:8080/catalog/
c. Go to ApplicationsWebTools
d. Go to section 'Entity XML Tools' and click the link 'XML Data Export All'
- export the data to a directory of your choice

Step - III
Stop OfBiz server
Create a backup of ofbiz-dir/framework/entity/config/entityengine.xml
Edit entityengine.xml as follows:
1. Add the following datasources below the datasource 'localmysql'
datasource name=localmysqlolap
   helper-class=org.ofbiz.entity.datasource.GenericHelperDAO
   field-type-name=mysql
   check-on-start=true
   add-missing-on-start=true
   check-pks-on-start=false
   use-foreign-keys=true
   join-style=ansi-no-parenthesis
   alias-view-columns=false
   drop-fk-use-foreign-key-keyword=true
   table-type=InnoDB
   character-set=latin1
   collate=latin1_general_cs
   read-data reader-name=seed/
   read-data reader-name=seed-initial/
   read-data reader-name=demo/
   read-data reader-name=ext/
   inline-jdbc
   jdbc-driver=com.mysql.jdbc.Driver
   jdbc-uri=jdbc:mysql://127.0.0.1/ofbiz?autoReconnect=true
   jdbc-username=ofbizolap
   jdbc-password=ofbizolap
   isolation-level=ReadCommitted
   pool-minsize=2
   pool-maxsize=250
   time-between-eviction-runs-millis=60/
   /datasource

datasource name=localmysqltenant
   helper-class=org.ofbiz.entity.datasource.GenericHelperDAO
   field-type-name=mysql
   check-on-start=true
   add-missing-on-start=true
   check-pks-on-start=false
   use-foreign-keys=true
   join-style=ansi-no-parenthesis
   alias-view-columns=false
   drop-fk-use-foreign-key-keyword=true
   table-type=InnoDB
   character-set=latin1
   collate=latin1_general_cs
   read-data reader-name=seed/
   read-data reader-name=seed-initial/
   read-data reader-name=demo/
   read-data reader-name=ext/
   inline-jdbc
   jdbc-driver=com.mysql.jdbc.Driver
   jdbc-uri=jdbc:mysql://127.0.0.1/ofbiz?autoReconnect=true
   jdbc-username=ofbiztenant
   jdbc-password=ofbiztenant
   isolation-level=ReadCommitted
   pool-minsize=2
   pool-maxsize=250
   time-between-eviction-runs-millis=60/
   /datasource
2. Replace derby with mysql in default, default-no-eca and test delegators
as follows:
delegator name=default entity-model-reader=main
entity-group-reader=main entity-eca-reader=main
distributed-cache-clear-enabled=false
   group-map group-name=org.ofbiz datasource-name=localmysql/
   group-map group-name=org.ofbiz.olap
datasource-name=localmysqlolap/
   group-map group-name=org.ofbiz.tenant
datasource-name=localmysqltenant/
   /delegator

   delegator name=default-no-eca entity-model-reader=main
entity-group-reader=main entity-eca-reader=main
entity-eca-enabled=false distributed-cache-clear-enabled=false
   group-map group-name=org.ofbiz datasource-name=localmysql/
   group-map group-name=org.ofbiz.olap
datasource-name=localmysqlolap/
   group-map group-name=org.ofbiz.tenant
datasource-name=localmysqltenant/
   /delegator

   delegator name=test entity-model-reader=main
entity-group-reader=main entity-eca-reader=main
   group-map group-name=org.ofbiz datasource-name=localmysql/
   group-map group-name=org.ofbiz.olap
datasource-name=localmysqlolap/
   group-map group-name=org.ofbiz.tenant
datasource-name

Re: Error - Migrating from Derby to MySQL

2012-04-27 Thread arvind.kumar.avinash
Thanks Jacques! I have added the topic at
https://cwiki.apache.org/confluence/display/OFBIZ/FAQ+-+Tips+-+Tricks+-+Cookbook+-+HowTo
as suggested by you

--
View this message in context: 
http://ofbiz.135035.n4.nabble.com/Error-Migrating-from-Derby-to-MySQL-tp2339328p4592359.html
Sent from the OFBiz - User mailing list archive at Nabble.com.


Error - Migrating from Derby to MySQL

2010-08-26 Thread OfBizSuds

I am trying to get ofbiz to work with MySQL DB instead of the default Derby
db. Tried following instructions given in the Production setup  that in the
llnk 
http://www.flagword.net/2010/06/29/how-to-migrate-ofbiz-from-derby-to-mysql-db/

Has anyone tried this? 

I exported the data to XML thru webtools. Then created a Mysql db called
ofbiz  one more called ofbizolap as per instructins given. I can see the 2
databases created also in mySQL (thru Netbeans IDE)

When I try the line 
grant all privileges on ofbiz.* to 'ofbiz'@'localhost' identified by
password 'ofbiz';
OR
grant all privileges on ofbizolap.* to 'ofbiz'@'localhost' identified by
password 'ofbizolap';

I get the error Password hash should be a 41-digit hexadecimal number

Any ideas how to fix this??

-- 
View this message in context: 
http://ofbiz.135035.n4.nabble.com/Error-Migrating-from-Derby-to-MySQL-tp2339328p2339328.html
Sent from the OFBiz - User mailing list archive at Nabble.com.


Re: Error - Migrating from Derby to MySQL

2010-08-26 Thread BJ Freeman

that is a question best asked in the Mysql Forum for fastest response.
it has to-do with setting up Mysql not ofbiz.

=
BJ Freeman  http://bjfreeman.elance.com
Strategic Power Office with Supplier Automation  
http://www.businessesnetwork.com/automation/viewforum.php?f=52
Specialtymarket.com  http://www.specialtymarket.com/
Systems Integrator-- Glad to Assist

Chat  Y! messenger: bjfr33man


OfBizSuds sent the following on 8/26/2010 1:20 AM:


I am trying to get ofbiz to work with MySQL DB instead of the default Derby
db. Tried following instructions given in the Production setup  that in the
llnk
http://www.flagword.net/2010/06/29/how-to-migrate-ofbiz-from-derby-to-mysql-db/

Has anyone tried this?

I exported the data to XML thru webtools. Then created a Mysql db called
ofbiz  one more called ofbizolap as per instructins given. I can see the 2
databases created also in mySQL (thru Netbeans IDE)

When I try the line
grant all privileges on ofbiz.* to 'ofbiz'@'localhost' identified by
password 'ofbiz';
OR
grant all privileges on ofbizolap.* to 'ofbiz'@'localhost' identified by
password 'ofbizolap';

I get the error Password hash should be a 41-digit hexadecimal number

Any ideas how to fix this??





Re: Error - Migrating from Derby to MySQL

2010-08-26 Thread Nico Toerl
 On 08/26/10 16:20, OfBizSuds wrote:
 I am trying to get ofbiz to work with MySQL DB instead of the default Derby
 db. Tried following instructions given in the Production setup  that in the
 llnk 
 http://www.flagword.net/2010/06/29/how-to-migrate-ofbiz-from-derby-to-mysql-db/

 Has anyone tried this? 

 I exported the data to XML thru webtools. Then created a Mysql db called
 ofbiz  one more called ofbizolap as per instructins given. I can see the 2
 databases created also in mySQL (thru Netbeans IDE)

 When I try the line 
 grant all privileges on ofbiz.* to 'ofbiz'@'localhost' identified by
 password 'ofbiz';
 OR
 grant all privileges on ofbizolap.* to 'ofbiz'@'localhost' identified by
 password 'ofbizolap';

 I get the error Password hash should be a 41-digit hexadecimal number

 Any ideas how to fix this??


Password is a mysql system function that generates a hash from the argument 
given.
Just the syntax/typo that caused mysql to produce that error.


|its either IDENTIFIED BY '/password/String'

or
|

PASSWORD('passwordString');

cheers
Nico


-- 
Nico Toerl  
SeniorSysadmin / IT-department
Virtual Village

Tel. +86 21 51718885 ext.7042



Re: Error - Migrating from Derby to MySQL

2010-08-26 Thread Nico Toerl
 On 08/26/10 16:34, Nico Toerl wrote:
  On 08/26/10 16:20, OfBizSuds wrote:
 I am trying to get ofbiz to work with MySQL DB instead of the default Derby
 db. Tried following instructions given in the Production setup  that in the
 llnk 
 http://www.flagword.net/2010/06/29/how-to-migrate-ofbiz-from-derby-to-mysql-db/

 Has anyone tried this? 

 I exported the data to XML thru webtools. Then created a Mysql db called
 ofbiz  one more called ofbizolap as per instructins given. I can see the 2
 databases created also in mySQL (thru Netbeans IDE)

 When I try the line 
 grant all privileges on ofbiz.* to 'ofbiz'@'localhost' identified by
 password 'ofbiz';
 OR
 grant all privileges on ofbizolap.* to 'ofbiz'@'localhost' identified by
 password 'ofbizolap';

 I get the error Password hash should be a 41-digit hexadecimal number

 Any ideas how to fix this??

 Password is a mysql system function that generates a hash from the argument 
 given.
 Just the syntax/typo that caused mysql to produce that error.


 |its either IDENTIFIED BY '/password/String'

 or
 |

 PASSWORD('passwordString');

 cheers
 Nico



sorry for the extra characters, not sure how i managed to type those
what i meant to write was:

its either IDENTIFIED BY 'passwordString'
or
PASSWORD('passwordString');


cheers
Nico

-- 
Nico Toerl  
SeniorSysadmin / IT-department
Virtual Village

Tel. +86 21 51718885 ext.7042



Re: Error - Migrating from Derby to MySQL

2010-08-26 Thread Sudha Viru
Thanks Nico

grant all privileges on ofbiz.* to 'ofbiz'@'localhost' identified by 'ofbiz'; 


worked!





From: Nico Toerl nico.to...@virtualvillage.com
To: user@ofbiz.apache.org
Sent: Thu, August 26, 2010 2:09:13 PM
Subject: Re: Error - Migrating from Derby to MySQL

On 08/26/10 16:34, Nico Toerl wrote:
  On 08/26/10 16:20, OfBizSuds wrote:
 I am trying to get ofbiz to work with MySQL DB instead of the default Derby
 db. Tried following instructions given in the Production setup  that in the
 llnk 
 
http://www.flagword.net/2010/06/29/how-to-migrate-ofbiz-from-derby-to-mysql-db/

 Has anyone tried this? 

 I exported the data to XML thru webtools. Then created a Mysql db called
 ofbiz  one more called ofbizolap as per instructins given. I can see the 2
 databases created also in mySQL (thru Netbeans IDE)

 When I try the line 
 grant all privileges on ofbiz.* to 'ofbiz'@'localhost' identified by
 password 'ofbiz';
 OR
 grant all privileges on ofbizolap.* to 'ofbiz'@'localhost' identified by
 password 'ofbizolap';

 I get the error Password hash should be a 41-digit hexadecimal number

 Any ideas how to fix this??

 Password is a mysql system function that generates a hash from the argument 
given.
 Just the syntax/typo that caused mysql to produce that error.


 |its either IDENTIFIED BY '/password/String'

 or
 |

 PASSWORD('passwordString');

 cheers
 Nico



sorry for the extra characters, not sure how i managed to type those
what i meant to write was:

its either IDENTIFIED BY 'passwordString'
or
PASSWORD('passwordString');


cheers
Nico

-- 
Nico Toerl  
SeniorSysadmin / IT-department
Virtual Village

Tel. +86 21 51718885 ext.7042


  

Re: Error - Migrating from Derby to MySQL

2010-08-26 Thread OfBizSuds

Thanks Nico

grant all privileges on ofbiz.* to 'ofbiz'@'localhost' identified by
'ofbiz';

worked!


-- 
View this message in context: 
http://ofbiz.135035.n4.nabble.com/Error-Migrating-from-Derby-to-MySQL-tp2339328p2339350.html
Sent from the OFBiz - User mailing list archive at Nabble.com.


Derby To MySQL

2008-11-22 Thread Divya Nair

Hi All,

How can the default database of derby which comes with ofbiz be ported to
mysql ?
This is for studying the database using ER tool

Thanks in Advance...

Regards,
Divya



-- 
View this message in context: 
http://www.nabble.com/Derby-To-MySQL-tp20636733p20636733.html
Sent from the OFBiz - User mailing list archive at Nabble.com.



Re: Derby To MySQL

2008-11-22 Thread Hans Bakker
You will be surprised!

The ER tool is build-ingo to webtools and then select 'entity
reference

enjoy!

Regards
Hans

On Sat, 2008-11-22 at 06:04 -0800, Divya Nair wrote:
 Hi All,
 
 How can the default database of derby which comes with ofbiz be ported to
 mysql ?
 This is for studying the database using ER tool
 
 Thanks in Advance...
 
 Regards,
 Divya
 
 
 
-- 
Antwebsystems.com: Quality OFBiz services for competitive prices



Re: Derby To MySQL

2008-11-22 Thread Divesh Dutta
Hi Divya,
 1)Go to framework/entity/config/entityengine.xml
 2)Wherever its written datasource-name=localderby ,you can change it 
to localmysql.
 3)Then go to settings of locamysql
 4)Give jdbc-uri=jdbc:postgresql://127.0.0.1/db_name
 5)Give jdbc-username=user name of your system will come here
jdbc-password=(leave it blank)
 6) And default database will be ported to mysql

Regards
Divesh Dutta


- Original Message -
From: Divya Nair [EMAIL PROTECTED]
To: user@ofbiz.apache.org
Sent: Saturday, November 22, 2008 7:34:46 PM GMT +05:30 Chennai, Kolkata, 
Mumbai, New Delhi
Subject: Derby To MySQL


Hi All,

How can the default database of derby which comes with ofbiz be ported to
mysql ?
This is for studying the database using ER tool

Thanks in Advance...

Regards,
Divya



-- 
View this message in context: 
http://www.nabble.com/Derby-To-MySQL-tp20636733p20636733.html
Sent from the OFBiz - User mailing list archive at Nabble.com.



Re: Derby To MySQL

2008-11-22 Thread Divya Nair

Thank You so much

Divesh Dutta wrote:
 
 Hi Divya,
  1)Go to framework/entity/config/entityengine.xml
  2)Wherever its written datasource-name=localderby ,you can
 change it to localmysql.
  3)Then go to settings of locamysql
  4)Give jdbc-uri=jdbc:postgresql://127.0.0.1/db_name
  5)Give jdbc-username=user name of your system will come here
 jdbc-password=(leave it blank)
  6) And default database will be ported to mysql
 
 Regards
 Divesh Dutta
 
 
 - Original Message -
 From: Divya Nair [EMAIL PROTECTED]
 To: user@ofbiz.apache.org
 Sent: Saturday, November 22, 2008 7:34:46 PM GMT +05:30 Chennai, Kolkata,
 Mumbai, New Delhi
 Subject: Derby To MySQL
 
 
 Hi All,
 
 How can the default database of derby which comes with ofbiz be ported to
 mysql ?
 This is for studying the database using ER tool
 
 Thanks in Advance...
 
 Regards,
 Divya
 
 
 
 -- 
 View this message in context:
 http://www.nabble.com/Derby-To-MySQL-tp20636733p20636733.html
 Sent from the OFBiz - User mailing list archive at Nabble.com.
 
 
 

-- 
View this message in context: 
http://www.nabble.com/Derby-To-MySQL-tp20636733p20637020.html
Sent from the OFBiz - User mailing list archive at Nabble.com.



Re: Derby To MySQL

2008-11-22 Thread Vivek Mishra
A bit amendment in line 4)  jdbc-uri=jdbc:mysql://127.0.0.1

Kind Regards,
--
Vivek Mishra
- Original Message -
From: Divya Nair [EMAIL PROTECTED]
To: user@ofbiz.apache.org
Sent: Saturday, November 22, 2008 8:09:17 PM GMT +05:30 Chennai, Kolkata, 
Mumbai, New Delhi
Subject: Re: Derby To MySQL


Thank You so much

Divesh Dutta wrote:
 
 Hi Divya,
  1)Go to framework/entity/config/entityengine.xml
  2)Wherever its written datasource-name=localderby ,you can
 change it to localmysql.
  3)Then go to settings of locamysql
  4)Give jdbc-uri=jdbc:postgresql://127.0.0.1/db_name
  5)Give jdbc-username=user name of your system will come here
 jdbc-password=(leave it blank)
  6) And default database will be ported to mysql
 
 Regards
 Divesh Dutta
 
 
 - Original Message -
 From: Divya Nair [EMAIL PROTECTED]
 To: user@ofbiz.apache.org
 Sent: Saturday, November 22, 2008 7:34:46 PM GMT +05:30 Chennai, Kolkata,
 Mumbai, New Delhi
 Subject: Derby To MySQL
 
 
 Hi All,
 
 How can the default database of derby which comes with ofbiz be ported to
 mysql ?
 This is for studying the database using ER tool
 
 Thanks in Advance...
 
 Regards,
 Divya
 
 
 
 -- 
 View this message in context:
 http://www.nabble.com/Derby-To-MySQL-tp20636733p20636733.html
 Sent from the OFBiz - User mailing list archive at Nabble.com.
 
 
 

-- 
View this message in context: 
http://www.nabble.com/Derby-To-MySQL-tp20636733p20637020.html
Sent from the OFBiz - User mailing list archive at Nabble.com.



Re: Derby To MySQL

2008-11-22 Thread Sven Wesley
Here's a well explained howto also.
http://friendfeed.s3.amazonaws.com/9578c31cabe457a801b23c9e2d3a5f047b983226

2008/11/22 Vivek Mishra [EMAIL PROTECTED]

 A bit amendment in line 4)  jdbc-uri=jdbc:mysql://127.0.0.1

 Kind Regards,
 --
 Vivek Mishra
 - Original Message -
 From: Divya Nair [EMAIL PROTECTED]
 To: user@ofbiz.apache.org
 Sent: Saturday, November 22, 2008 8:09:17 PM GMT +05:30 Chennai, Kolkata,
 Mumbai, New Delhi
 Subject: Re: Derby To MySQL


 Thank You so much

 Divesh Dutta wrote:
 
  Hi Divya,
   1)Go to framework/entity/config/entityengine.xml
   2)Wherever its written datasource-name=localderby ,you can
  change it to localmysql.
   3)Then go to settings of locamysql
   4)Give jdbc-uri=jdbc:postgresql://127.0.0.1/db_name
   5)Give jdbc-username=user name of your system will come here
  jdbc-password=(leave it blank)
   6) And default database will be ported to mysql
 
  Regards
  Divesh Dutta
 
 
  - Original Message -
  From: Divya Nair [EMAIL PROTECTED]
  To: user@ofbiz.apache.org
  Sent: Saturday, November 22, 2008 7:34:46 PM GMT +05:30 Chennai, Kolkata,
  Mumbai, New Delhi
  Subject: Derby To MySQL
 
 
  Hi All,
 
  How can the default database of derby which comes with ofbiz be ported to
  mysql ?
  This is for studying the database using ER tool
 
  Thanks in Advance...
 
  Regards,
  Divya
 
 
 
  --
  View this message in context:
  http://www.nabble.com/Derby-To-MySQL-tp20636733p20636733.html
  Sent from the OFBiz - User mailing list archive at Nabble.com.
 
 
 

 --
 View this message in context:
 http://www.nabble.com/Derby-To-MySQL-tp20636733p20637020.html
 Sent from the OFBiz - User mailing list archive at Nabble.com.




Re: Derby To MySQL

2008-11-22 Thread Sven Wesley
Darn!!! Wrong URL in the copy buffer. :)
http://lj4newbies.blogspot.com/2008/06/setup-mysql-with-ofbiz.html


2008/11/22 Sven Wesley [EMAIL PROTECTED]

 Here's a well explained howto also.
 http://friendfeed.s3.amazonaws.com/9578c31cabe457a801b23c9e2d3a5f047b983226

 2008/11/22 Vivek Mishra [EMAIL PROTECTED]

 A bit amendment in line 4)  jdbc-uri=jdbc:mysql://127.0.0.1

 Kind Regards,
 --
 Vivek Mishra
 - Original Message -
 From: Divya Nair [EMAIL PROTECTED]
 To: user@ofbiz.apache.org
 Sent: Saturday, November 22, 2008 8:09:17 PM GMT +05:30 Chennai, Kolkata,
 Mumbai, New Delhi
 Subject: Re: Derby To MySQL


 Thank You so much

 Divesh Dutta wrote:
 
  Hi Divya,
   1)Go to framework/entity/config/entityengine.xml
   2)Wherever its written datasource-name=localderby ,you can
  change it to localmysql.
   3)Then go to settings of locamysql
   4)Give jdbc-uri=jdbc:postgresql://127.0.0.1/db_name
   5)Give jdbc-username=user name of your system will come here
  jdbc-password=(leave it blank)
   6) And default database will be ported to mysql
 
  Regards
  Divesh Dutta
 
 
  - Original Message -
  From: Divya Nair [EMAIL PROTECTED]
  To: user@ofbiz.apache.org
  Sent: Saturday, November 22, 2008 7:34:46 PM GMT +05:30 Chennai,
 Kolkata,
  Mumbai, New Delhi
  Subject: Derby To MySQL
 
 
  Hi All,
 
  How can the default database of derby which comes with ofbiz be ported
 to
  mysql ?
  This is for studying the database using ER tool
 
  Thanks in Advance...
 
  Regards,
  Divya
 
 
 
  --
  View this message in context:
  http://www.nabble.com/Derby-To-MySQL-tp20636733p20636733.html
  Sent from the OFBiz - User mailing list archive at Nabble.com.
 
 
 

 --
 View this message in context:
 http://www.nabble.com/Derby-To-MySQL-tp20636733p20637020.html
 Sent from the OFBiz - User mailing list archive at Nabble.com.





Re: Derby To MySQL

2008-11-22 Thread BJ Freeman
here is an explanation
http://ofbiz.apache.org/docs/entityconfig.html
if you look in the entityengine.xml
you will find the mysql you can replace the derby with.
you can export the derby with webtools then import once the mysql is
running, if you have more than the demo data.
other wise
just do
ant run-install.

Divya Nair sent the following on 11/22/2008 6:04 AM:
 Hi All,
 
 How can the default database of derby which comes with ofbiz be ported to
 mysql ?
 This is for studying the database using ER tool
 
 Thanks in Advance...
 
 Regards,
 Divya