DEMO DBs

Topics: Data Access, SharpMap Project, SharpMap v0.9 / v1.x
Mar 4, 2010 at 11:31 AM

I am using SharpMap v0.9.  I am using POSTGIS 1.5.1 on top of PostgreSQL 8.4.  I am also using MSSQL2005.  The I cannot restore the backup examples to the databases mentioned. 

The POSTGIS just gives no error messages but does not ungrey the OK button to restore once I have selected the *.backup file.   In MSSQL2005 I get


------------------------------

An exception occurred while executing a Transact-SQL statement or batch. (Microsoft.SqlServer.ConnectionInfo)

------------------------------
ADDITIONAL INFORMATION:

The media family on device 'C:\MyPath\SharpMapMsSqlSpatialDemoDb.bak' is incorrectly formed. SQL Server cannot process this media family.
RESTORE HEADERONLY is terminating abnormally. (Microsoft SQL Server, Error: 3241)

For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=09.00.1399&EvtSrc=MSSQLServer&EvtID=3241&LinkId=20476

 

Otherwise all is fine.  Any ideas?

 

Cheers

 

James

Coordinator
Mar 4, 2010 at 12:20 PM

Hello james,

on the postgres/postgis side I have no idea why the "OK" button does not ungray.

If you follow the instructions provided in the (just updated) ReadMe.txt you still can restore the postgis database.

I'm not familiar with the SqlServer side.

Hth FObermaier

Mar 4, 2010 at 12:32 PM
I have run...

    psql -U postgres -c "CREATE DATABASE postgis_sample OWNER postgres TEMPLATE template_postgis ENCODING 'UTF8';"
    psql -d postgis_sample -U postgres < postgisdemodb.backup

From a PSQL console (on MS Windows box where POSTGIS/POSTGRESQL are installed) with no success.


Cheers

James



On 4 March 2010 12:20, fobermaier <notifications@codeplex.com> wrote:

From: fobermaier

Hello james,

on the postgres/postgis side I have no idea why the "OK" button does not ungray.

If you follow the instructions provided in the (just updated) ReadMe.txt you still can restore the postgis database.

I'm not familiar with the SqlServer side.

Hth FObermaier

Read the full discussion online.

To add a post to this discussion, reply to this email (SharpMap@discussions.codeplex.com)

To start a new discussion for this project, email SharpMap@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe on CodePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at CodePlex.com


Coordinator
Mar 4, 2010 at 12:59 PM
Edited Mar 4, 2010 at 1:01 PM

Hello James,

if you have an active psql session, the commands would be:

\c postgres
DROP DATABASE postgis_sample;
CREATE DATABASE postgis_sample OWNER postgres TEMPLATE template_postgis ENCODING 'UTF8'; \c postgis_sample \i <path to postgisdemodb.backup with '/' instead of '\'>

The commands in the ReadMe.txt refer to standard windows console, invoking psql and executing the given command.
It has just been updated. The second line should read

psql -d postgis_sample -U postgres -f <path to postgisdemodb.backup>

 

Hth FObermaier

Mar 4, 2010 at 3:08 PM
Brilliant that worked perfectly!

Thanks a million

Cheers

James



On 4 March 2010 13:00, fobermaier <notifications@codeplex.com> wrote:

From: fobermaier

Hello James,

if you have an active psql session, the commands would be:

\c postgres
DROP DATABASE posgis_sample;

CREATE DATABASE postgis_sample OWNER postgres TEMPLATE template_postgis ENCODING 'UTF8'
; \c postgis_sample \i <path to postgisdemodb.backup with '/' instead of '\'>

The commands in the ReadMe.txt refer to standard windows console, invoking psql and executing the given command.
It has just been updated. The second line should read

psql -d postgis_sample -U postgres -f <path to postgisdemodb.backup>

 

Hth FObermaier

Read the full discussion online.

To add a post to this discussion, reply to this email (SharpMap@discussions.codeplex.com)

To start a new discussion for this project, email SharpMap@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe on CodePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at CodePlex.com