Showing posts with label device. Show all posts
Showing posts with label device. Show all posts

Sunday, March 25, 2012

@@ERROR

Hi Folks,
I try to save the error number when a restore fails. In case a device error
I'd like to save the error number into a table. Let's say I have a RESTORE
as below
RESTORE LOG xxxxx
FROM DISK='xxxxxxxxxxx.bak'
PRINT @.@.ERROR
Server: Msg 3201, Level 16, State 2, Line 3
Cannot open backup device 'xxxxxxxxx'. Device error or device off-line. See
the SQL Server error log for more details.
Server: Msg 3013, Level 16, State 1, Line 3
RESTORE LOG is terminating abnormally.
If a device errors I want to get the error number 3201, which is more
specific about the cause of failure. However @.@.ERROR is always 3013 which
doesn't help much. How do I get it right as expected?
Thank you.Hmm, this may be tricky.
@.@.ERROR, as I understand it, always has the last immediate error that
occured. So, if you're printing @.@.error after the backup fails, it's always
going to be the last error, which is 3013 in this case.
I don't really see a way to just grab the error directly, other than logging
it to an output file in the job or writing to the event log. It seems to me
the event log is a more approprate place to put the entire message. You
could then import the event log into a table and do a search on that
specific error number.
"Flicker" <hthan@.superioraccess.com> wrote in message
news:ePQlImsUDHA.1276@.TK2MSFTNGP09.phx.gbl...
> Hi Folks,
> I try to save the error number when a restore fails. In case a device
error
> I'd like to save the error number into a table. Let's say I have a
RESTORE
> as below
> RESTORE LOG xxxxx
> FROM DISK='xxxxxxxxxxx.bak'
> PRINT @.@.ERROR
>
> Server: Msg 3201, Level 16, State 2, Line 3
> Cannot open backup device 'xxxxxxxxx'. Device error or device off-line.
See
> the SQL Server error log for more details.
> Server: Msg 3013, Level 16, State 1, Line 3
> RESTORE LOG is terminating abnormally.
> If a device errors I want to get the error number 3201, which is more
> specific about the cause of failure. However @.@.ERROR is always 3013 which
> doesn't help much. How do I get it right as expected?
> Thank you.
>

Monday, March 19, 2012

.sdf deployment problem VS2005

I have .sdf and .xds objects in my project for a PocketPC 2003 device. When I debug all of the CF2.0, SQL, and .SDF files are downloaded to the device. However, when I install via the application.cab file, the .sdf, .xds, and CF files do not show up on the device.

What am I missing here?

First ensure that your SDF has Build Action set to 'Content' and Copy to Output Directory = True in your project. When you then create a Smart Device Setup Project in VS2005 to create the CAB file for deployment, you need to include the project output AND the content files from your project in the setup project.

Darren

|||

After installing the CF, SQL and application cabs the .sdf file is in the correct folder. However, I am unable to open the .sdf via the application or SQLce Query Analyzer. I get the following message:

Error:0x80004005 E_FAIL

Native Error: (25039)

Description : Access to the database file is not allowe, {,,,File name,,]

Interface defining error: IID_IDBInitialize

Param. 0:0

Param. 1:0

Param. 2:0

Param. 3 \Program Files\Myapplication folder\myapplication.sdf

Param. 4:

Param.

I am still missing something. What?

|||I think I found the problem(s). A) On the device I removed SQLClient2.0. B) In VS I rebuilt .sdf and .xsd. Now it works. I think the .sdf that I replace in VS was based on CF1.0|||

cool. thanks for posting your solution.

-Darren

Friday, February 24, 2012

.BAK files do not show

When attempting to restore a database, I choose "From Device" and browse to
the directory where my .bak files are nothing shows. However, if I rename
the files in windows without changing the file extension, the files show.
Once this occurs, Enterprise Manager stops responding with the following
error in the event log:
Hanging application mmc.exe, version 5.2.3790.0, hang module ntdll.dll,
version 5.2.3790.0, hang address 0x0000f67d.
Any help would be appreciated tremendously.
Hi Tony,
Try to choose "From Disk"
Regards,
Daniel
"Tony" <Tony@.discussions.microsoft.com> wrote in message
news:484BEC53-8F12-4114-8D09-77913CCCC42A@.microsoft.com...
> When attempting to restore a database, I choose "From Device" and browse
to
> the directory where my .bak files are nothing shows. However, if I rename
> the files in windows without changing the file extension, the files show.
> Once this occurs, Enterprise Manager stops responding with the following
> error in the event log:
> Hanging application mmc.exe, version 5.2.3790.0, hang module ntdll.dll,
> version 5.2.3790.0, hang address 0x0000f67d.
> Any help would be appreciated tremendously.

.BAK files do not show

When attempting to restore a database, I choose "From Device" and browse to
the directory where my .bak files are nothing shows. However, if I rename
the files in windows without changing the file extension, the files show.
Once this occurs, Enterprise Manager stops responding with the following
error in the event log:
Hanging application mmc.exe, version 5.2.3790.0, hang module ntdll.dll,
version 5.2.3790.0, hang address 0x0000f67d.
Any help would be appreciated tremendously.Hi Tony,
Try to choose "From Disk"
Regards,
Daniel
"Tony" <Tony@.discussions.microsoft.com> wrote in message
news:484BEC53-8F12-4114-8D09-77913CCCC42A@.microsoft.com...
> When attempting to restore a database, I choose "From Device" and browse
to
> the directory where my .bak files are nothing shows. However, if I rename
> the files in windows without changing the file extension, the files show.
> Once this occurs, Enterprise Manager stops responding with the following
> error in the event log:
> Hanging application mmc.exe, version 5.2.3790.0, hang module ntdll.dll,
> version 5.2.3790.0, hang address 0x0000f67d.
> Any help would be appreciated tremendously.

.BAK files do not show

When attempting to restore a database, I choose "From Device" and browse to
the directory where my .bak files are nothing shows. However, if I rename
the files in windows without changing the file extension, the files show.
Once this occurs, Enterprise Manager stops responding with the following
error in the event log:
Hanging application mmc.exe, version 5.2.3790.0, hang module ntdll.dll,
version 5.2.3790.0, hang address 0x0000f67d.
Any help would be appreciated tremendously.Hi Tony,
Try to choose "From Disk"
Regards,
Daniel
"Tony" <Tony@.discussions.microsoft.com> wrote in message
news:484BEC53-8F12-4114-8D09-77913CCCC42A@.microsoft.com...
> When attempting to restore a database, I choose "From Device" and browse
to
> the directory where my .bak files are nothing shows. However, if I rename
> the files in windows without changing the file extension, the files show.
> Once this occurs, Enterprise Manager stops responding with the following
> error in the event log:
> Hanging application mmc.exe, version 5.2.3790.0, hang module ntdll.dll,
> version 5.2.3790.0, hang address 0x0000f67d.
> Any help would be appreciated tremendously.