BlackBerry Forums Support Community
              

Closed Thread
 
Thread Tools
Old 12-11-2008, 04:32 AM   #1
superspugg
New Member
 
Join Date: Dec 2008
Model: pearl
PIN: N/A
Carrier: O2UK - Telefonica
Posts: 7
Default backing up the BES database to migrate between servers

Please Login to Remove!

Hi,

So I know this topic has been covered many times on this forum already but I have read through a lot of the existing posts and unfrotunately am still not able to back my database up in order to move our BES to another server.

The background to the problem is this: My predecessor set up our BES before I started here and has since left. It's a Windows 2003 Server and an MSDE 2000 Release A engine. Although there is a default BES database (BESMgmt) on the C:Drive the DB that is being used by the BlackBerry Manager is called (3TBES) and is on the server's D:Drive.

The BlackBerry Manager specifies the following:
DB Server name: 3T-AUTO-6\SQLBES
DB Name: 3TBES
Authentication: Windows Authentication

The database itself is saved at the following path:
D:\Program Files\Microsoft SQL Server\MSSQL\MSSQL$SQLBES\Data\3TBES.mdf & .ldf

I have tried to backup the DB using various iterations of the commands mentioned but without any luck. The way I believe I have to do it is by changing the root directory to the D:Drive in the command prompt as I have done below:

Microsoft Windows [Version 5.2.3790]
(C) Copyright 1985-2003 Microsoft Corp.

C:\Documents and Settings\gibss>d:

D:\>osql -E
1> backup database 3TBES to disk = "C:\3TBES.bak"
2> go
Msg 170, Level 15, State 1, Server 3T-AUTO-6, Line 1
Line 1: Incorrect syntax near '3'.
1>


When I run the same command on the C:Drive with the default DB instance (BESMgmt) the backup runs correctly and a file is created.

I am probably just making a simple error but I can't for the life of me figure out what it is. Can anyone help? The only difference I can think of is that the DB has a name starting with a number but I can't see why this would be a problem?

Thanks in advance for your help,
Steve
Offline  
Old 12-11-2008, 05:43 AM   #2
superspugg
New Member
 
Join Date: Dec 2008
Model: pearl
PIN: N/A
Carrier: O2UK - Telefonica
Posts: 7
Default

Forgot to add this to the previous post:

The BES version we are using at the moment is 4.1.4.17. I have also tried using the syntax for the named instance backup with no joy.
Offline  
Old 12-11-2008, 10:01 AM   #3
RadHaz75
Talking BlackBerry Encyclopedia
 
RadHaz75's Avatar
 
Join Date: Feb 2006
Location: Philadelphia
Model: 9650
OS: 6.0.0.524
PIN: BALL
Carrier: Verizon Wireless
Posts: 456
Default

i'm no sql expert, but maybe try quotes (single or double) around the 3TBES? since it has a number maybe its confusing the process.
__________________
Two months ago, I saw a provocative movie on cable TV. It was called The Net, with that girl from the bus.
Offline  
Old 12-12-2008, 09:47 AM   #4
superspugg
New Member
 
Join Date: Dec 2008
Model: pearl
PIN: N/A
Carrier: O2UK - Telefonica
Posts: 7
Default

I have tried this but it comes back with the same error but rather than the:

Line 1: Incorrect syntax near '3'.

it says: Line 1: Incorrect syntax near '"'.
Offline  
Old 12-12-2008, 10:07 AM   #5
superspugg
New Member
 
Join Date: Dec 2008
Model: pearl
PIN: N/A
Carrier: O2UK - Telefonica
Posts: 7
Default

actually I tell a lie. the output when I use the " marks is:

Line 1: Incorrect syntax near '3TBES'
Offline  
Old 12-12-2008, 10:38 AM   #6
gibson_hg
BlackBerry Extraordinaire
 
gibson_hg's Avatar
 
Join Date: Dec 2007
Model: NA
PIN: 80081ES
Carrier: NA
Posts: 1,006
Default

Can you log into the database from the C: drive? Can you use the database? ie.

1> use 3TBES
2>go

1> select * from userconfig
2>go

Does that work?
Offline  
Old 12-12-2008, 10:39 AM   #7
gibson_hg
BlackBerry Extraordinaire
 
gibson_hg's Avatar
 
Join Date: Dec 2007
Model: NA
PIN: 80081ES
Carrier: NA
Posts: 1,006
Default

Are both databases on the same SQL instance? If not, are both instances the same version?
Offline  
Old 12-15-2008, 04:37 AM   #8
superspugg
New Member
 
Join Date: Dec 2008
Model: pearl
PIN: N/A
Carrier: O2UK - Telefonica
Posts: 7
Default

Hi gibson_hg,

I have tried the command you have suggested from both the C: and D: and it brings back the same error

Microsoft Windows [Version 5.2.3790]
(C) Copyright 1985-2003 Microsoft Corp.

C:\Documents and Settings\besadmin>cd \

C:\>osql -E
1> use 3TBES
2> go
Msg 170, Level 15, State 1, Server 3T-AUTO-6, Line 1
Line 1: Incorrect syntax near '3'.
1> quit

C:\>d:

D:\>osql -E
1> use 3TBES
2> go
Msg 170, Level 15, State 1, Server 3T-AUTO-6, Line 1
Line 1: Incorrect syntax near '3'.
1>


I don't think the 2 databases are on the same instance. The default BESMgmt DB is on the C:Drive and 3TBES is on the D:drive. I am not that aux fait with working with SQL DB's so I'm struggling with this.

Thanks for your advice. Does the above information help at all?
Offline  
Old 12-15-2008, 05:57 AM   #9
superspugg
New Member
 
Join Date: Dec 2008
Model: pearl
PIN: N/A
Carrier: O2UK - Telefonica
Posts: 7
Default

ok so I have made some progress this morning. I finally managed to piece together the correct syntax to access the instance.

osql -E -S 3t-auto-6\SQLBES
1>

but then I am still having the incorrect syntax near '3' error when trying to back up the database with this command

backup database 3TBES to disk = "C:\3TBES.bak"

Microsoft Windows [Version 5.2.3790]
(C) Copyright 1985-2003 Microsoft Corp.

C:\Documents and Settings\besadmin>d:

D:\>osql -E -S 3t-auto-6\SQLBES
1> backup database 3TBES to disk ="C:\3TBES.bak"
2> go
Msg 170, Level 15, State 1, Server 3T-AUTO-6\SQLBES, Line 1
Line 1: Incorrect syntax near '3'.
1>
Offline  
Old 12-15-2008, 10:03 AM   #10
e_brown
Knows Where the Search Button Is
 
Join Date: Mar 2007
Location: PA
Model: 8830
Carrier: Sprint
Posts: 18
Default

Try SQL Management Studio if you're not real familiar with sql. Makes the whole process alot smoother.

I learned alot by using command line and like to know how, but the sql management software is just down right easy.
Offline  
Old 12-15-2008, 11:37 AM   #11
superspugg
New Member
 
Join Date: Dec 2008
Model: pearl
PIN: N/A
Carrier: O2UK - Telefonica
Posts: 7
Default

I didnt think you could use the Management Studio with the free MSDE SQL engine. Isn't that why all the instructions on the BlackBerry site are all command prompt oriented?
Offline  
Old 12-15-2008, 11:40 AM   #12
knottyrope
BlackBerry Elite
 
knottyrope's Avatar
 
Join Date: Jan 2008
Location: Massachusetts
Model: DT60
OS: 123456789
PIN: t of blood has been taken
Carrier: AT&T-US with I dee ten tee errors
Posts: 7,325
Default

I used it to connect to it and browse the tables before.
__________________
I had to fall
To lose it all
But in the end
It doesn't even matter

Rocking the Motion with out lotion.
Offline  
Old 05-21-2009, 03:02 PM   #13
artvarck
New Member
 
Join Date: May 2009
Model: 7100t
PIN: N/A
Carrier: private
Posts: 10
Default

I'd say that you have to specify the named SQL instance in the backup statement.

Just a thought.
Offline  
Old 05-21-2009, 06:31 PM   #14
TargetIT
CrackBerry Addict
 
Join Date: Jan 2008
Model: 9700
PIN: N/A
Carrier: Rogers
Posts: 709
Default

It REALLY doesn't like the fact the name of the database starts with a number - it screws up the parsing in a big way. I bet if you enclosed the database and the instance with quotes, it would take it.
Offline  
Closed Thread



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


Lot Of 4 Vintage 3x Jacobs Multi-Craft 3 Jaw Chucks & 1 x Rohm (1/16

Lot Of 4 Vintage 3x Jacobs Multi-Craft 3 Jaw Chucks & 1 x Rohm (1/16"-3/8" cap)

$19.98



Vintage MERCURY model 1100C Radio Vacuum Tube Tester With Setups picture

Vintage MERCURY model 1100C Radio Vacuum Tube Tester With Setups

$84.50



Vintage 3238 Klein Tools 1/2

Vintage 3238 Klein Tools 1/2" Drive Ratchet Construction Spud Wrench 15" Long

$39.50



Vintage ENCO 605-4070 Dial Indicator .001 0-1

Vintage ENCO 605-4070 Dial Indicator .001 0-1"" Range

$16.00



KP KOOL PRODUCTS Aftermarket Pre-Ban Chilton/Vintage Craftsman (1 YELLOW SPOUT) picture

KP KOOL PRODUCTS Aftermarket Pre-Ban Chilton/Vintage Craftsman (1 YELLOW SPOUT)

$14.99



Vintage Amico American Company coating thickness gage picture

Vintage Amico American Company coating thickness gage

$100.00







Copyright © 2004-2016 BlackBerryForums.com.
The names RIM © and BlackBerry © are registered Trademarks of BlackBerry Inc.