Re: [Bacula-users] migration sqlite > postgresql

2005-09-24 Thread Mathieu Arnold
+-le 23/09/2005 15:01 +0200, Florian Schnabel écrivait :
| now ... i decided to migrate to postgresql ...
| did set up the database and tried to import the .sql
| about every line gives an error ^^
| 
| f.ex.
| 
| psql:/var/lib/bacula/test.sql:8: FEHLER:  Fehler »Syntaxfehler« bei
| »UNSIGNED« at character 44
| psql:/var/lib/bacula/test.sql:8: ZEILE 2:BaseId INTEGER UNSIGNED
| AUTOINCREMENT,
| 
| is there any way to convert it so postgres likes it ?
| don't really want to start with an empty database ...

You will have to create the database with the scripts coming with bacula,
it's not the same script for sqlite and postgresql (not the same keywords,
semantic, etc...)
Then, you'll have some problem with the time fields, as sqlite makes some
strange things in some rare cases.
I've already done that migration twice, and it's the only thing I do remember.

After the import, you'll have to set the sequences to the right number for
each table so that you don't run into conflicting id's.

Regards,

-- 
Mathieu Arnold


---
SF.Net email is sponsored by:
Tame your development challenges with Apache's Geronimo App Server.
Download it for free - -and be entered to win a 42" plasma tv or your very
own Sony(tm)PSP.  Click here to play: http://sourceforge.net/geronimo.php
___
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users


[Bacula-users] migration sqlite > postgresql

2005-09-23 Thread Florian Schnabel

now ... i decided to migrate to postgresql ...
did set up the database and tried to import the .sql
about every line gives an error ^^

f.ex.

psql:/var/lib/bacula/test.sql:8: FEHLER:  Fehler »Syntaxfehler« bei 
»UNSIGNED« at character 44
psql:/var/lib/bacula/test.sql:8: ZEILE 2:BaseId INTEGER UNSIGNED 
AUTOINCREMENT,


is there any way to convert it so postgres likes it ?
don't really want to start with an empty database ...

--

Florian Schnabel


---
SF.Net email is sponsored by:
Tame your development challenges with Apache's Geronimo App Server. 
Download it for free - -and be entered to win a 42" plasma tv or your very

own Sony(tm)PSP.  Click here to play: http://sourceforge.net/geronimo.php
___
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users