I'm having a problem returning a value with IDENT_CURRENT:
When I run it through the Analyzer it's OK, when I run it through my ASP
code, I get a casting error on my web application. (Depending on the sql
transaction method I use, I sometimes get a -1 value (when using
ExecuteNon query) instead of the casting error(when using execute
Scalar))
here's the code:
CREATE PROCEDURE spSelectOrderID
AS SELECT IDENT_CURRENT('tbOrder') + 1
GO
*** Sent via Developersdex http://www.examnotes.net ***
Don't just participate in USENET...get rewarded for it!"Patrick Delifer" <deliferp@.videotron.ca> wrote in message
news:e5fCqMDJFHA.2396@.TK2MSFTNGP12.phx.gbl...
> I'm having a problem returning a value with IDENT_CURRENT:
> When I run it through the Analyzer it's OK, when I run it through my ASP
> code, I get a casting error on my web application. (Depending on the sql
> transaction method I use, I sometimes get a -1 value (when using
> ExecuteNon query) instead of the casting error(when using execute
> Scalar))
> here's the code:
> CREATE PROCEDURE spSelectOrderID
> AS SELECT IDENT_CURRENT('tbOrder') + 1
> GO
>
Back up. You appear to be under the impression that this is a viable method
to prefetch an IDENTITY value for an upcoming insert into tbOrder. It's
not.
David
Showing posts with label analyzer. Show all posts
Showing posts with label analyzer. Show all posts
Wednesday, March 21, 2012
Problem with IDENT_CURRENT
Monday, March 12, 2012
Problem with Enterprise Manager 2000
Hi,
After installing XP SP2 security patches on my box, I can not open
Enterprise Manager. It crashes when I click on icon to bring the analyzer up.
I get two error in event log,
========================
1. Event Type:Error
Event Source:Application Error
Event Category:None
Event ID:1000
Date:1/18/2005
Time:3:30:09 PM
User:N/A
Computer:WXPP-LT_AMINH
Description:
Faulting application mmc.exe, version 5.1.2600.0, faulting module mmc.exe,
version 5.1.2600.0, fault address 0x0000bb5b.
For more information, see Help and Support Center at
http://go.microsoft.com/fwlink/events.asp.
Data:
0000: 41 70 70 6c 69 63 61 74 Applicat
0008: 69 6f 6e 20 46 61 69 6c ion Fail
0010: 75 72 65 20 20 6d 6d 63 ure mmc
0018: 2e 65 78 65 20 35 2e 31 .exe 5.1
0020: 2e 32 36 30 30 2e 30 20 .2600.0
0028: 69 6e 20 6d 6d 63 2e 65 in mmc.e
0030: 78 65 20 35 2e 31 2e 32 xe 5.1.2
0038: 36 30 30 2e 30 20 61 74 600.0 at
0040: 20 6f 66 66 73 65 74 20 offset
0048: 30 30 30 30 62 62 35 62 0000bb5b
0050: 0d 0a ..
2.
Event Type:Error
Event Source:Application Error
Event Category:None
Event ID:1001
Date:1/18/2005
Time:3:30:22 PM
User:N/A
Computer:WXPP-LT_AMINH
Description:
Fault bucket 02874011.
For more information, see Help and Support Center at
http://go.microsoft.com/fwlink/events.asp.
Data:
0000: 42 75 63 6b 65 74 3a 20 Bucket:
0008: 30 32 38 37 34 30 31 31 02874011
0010: 0d 0a ..
=======================
I removed the patches using reollback option of XP, but after removal even
explorer crashes. I re-installed SQL client tools, but result is same...
Any one has idea how to resolve this?
Thanks,
Hiten
Maybe the snap-in has become corrupt or damaged.
Try renaming the existing SQL Server Enterprise Manager.MSC
file.
Then copy the SQL Server Enterprise Manager.MSC file from
the your SQL Server CD to the same location.
-Sue
On Tue, 18 Jan 2005 12:39:11 -0800, "Hiten"
<Hiten@.discussions.microsoft.com> wrote:
>Hi,
>After installing XP SP2 security patches on my box, I can not open
>Enterprise Manager. It crashes when I click on icon to bring the analyzer up.
>I get two error in event log,
>========================
>1. Event Type:Error
>Event Source:Application Error
>Event Category:None
>Event ID:1000
>Date:1/18/2005
>Time:3:30:09 PM
>User:N/A
>Computer:WXPP-LT_AMINH
>Description:
>Faulting application mmc.exe, version 5.1.2600.0, faulting module mmc.exe,
>version 5.1.2600.0, fault address 0x0000bb5b.
>For more information, see Help and Support Center at
>http://go.microsoft.com/fwlink/events.asp.
>Data:
>0000: 41 70 70 6c 69 63 61 74 Applicat
>0008: 69 6f 6e 20 46 61 69 6c ion Fail
>0010: 75 72 65 20 20 6d 6d 63 ure mmc
>0018: 2e 65 78 65 20 35 2e 31 .exe 5.1
>0020: 2e 32 36 30 30 2e 30 20 .2600.0
>0028: 69 6e 20 6d 6d 63 2e 65 in mmc.e
>0030: 78 65 20 35 2e 31 2e 32 xe 5.1.2
>0038: 36 30 30 2e 30 20 61 74 600.0 at
>0040: 20 6f 66 66 73 65 74 20 offset
>0048: 30 30 30 30 62 62 35 62 0000bb5b
>0050: 0d 0a ..
>2.
>Event Type:Error
>Event Source:Application Error
>Event Category:None
>Event ID:1001
>Date:1/18/2005
>Time:3:30:22 PM
>User:N/A
>Computer:WXPP-LT_AMINH
>Description:
>Fault bucket 02874011.
>For more information, see Help and Support Center at
>http://go.microsoft.com/fwlink/events.asp.
>Data:
>0000: 42 75 63 6b 65 74 3a 20 Bucket:
>0008: 30 32 38 37 34 30 31 31 02874011
>0010: 0d 0a ..
>=======================
>I removed the patches using reollback option of XP, but after removal even
>explorer crashes. I re-installed SQL client tools, but result is same...
>Any one has idea how to resolve this?
>Thanks,
>Hiten
|||Someone with the same problem before SP2 found this to be a workaround:
http://groups-beta.google.com/group/...e66a3e81c65f5e
[I opened] mmc.exe in the Windows/system32 folder and add[ed]
the Enterprise Manager snap-in. Now I can just run enterprise
manager that way! It's not ideal, but it works :-)
Steve Kass
Drew University
Hiten wrote:
>Hi,
>After installing XP SP2 security patches on my box, I can not open
>Enterprise Manager. It crashes when I click on icon to bring the analyzer up.
>I get two error in event log,
>========================
>1. Event Type:Error
>Event Source:Application Error
>Event Category:None
>Event ID:1000
>Date:1/18/2005
>Time:3:30:09 PM
>User:N/A
>Computer:WXPP-LT_AMINH
>Description:
>Faulting application mmc.exe, version 5.1.2600.0, faulting module mmc.exe,
>version 5.1.2600.0, fault address 0x0000bb5b.
>For more information, see Help and Support Center at
>http://go.microsoft.com/fwlink/events.asp.
>Data:
>0000: 41 70 70 6c 69 63 61 74 Applicat
>0008: 69 6f 6e 20 46 61 69 6c ion Fail
>0010: 75 72 65 20 20 6d 6d 63 ure mmc
>0018: 2e 65 78 65 20 35 2e 31 .exe 5.1
>0020: 2e 32 36 30 30 2e 30 20 .2600.0
>0028: 69 6e 20 6d 6d 63 2e 65 in mmc.e
>0030: 78 65 20 35 2e 31 2e 32 xe 5.1.2
>0038: 36 30 30 2e 30 20 61 74 600.0 at
>0040: 20 6f 66 66 73 65 74 20 offset
>0048: 30 30 30 30 62 62 35 62 0000bb5b
>0050: 0d 0a ..
>2.
>Event Type:Error
>Event Source:Application Error
>Event Category:None
>Event ID:1001
>Date:1/18/2005
>Time:3:30:22 PM
>User:N/A
>Computer:WXPP-LT_AMINH
>Description:
>Fault bucket 02874011.
>For more information, see Help and Support Center at
>http://go.microsoft.com/fwlink/events.asp.
>Data:
>0000: 42 75 63 6b 65 74 3a 20 Bucket:
>0008: 30 32 38 37 34 30 31 31 02874011
>0010: 0d 0a ..
>=======================
>I removed the patches using reollback option of XP, but after removal even
>explorer crashes. I re-installed SQL client tools, but result is same...
>Any one has idea how to resolve this?
>Thanks,
>Hiten
>
After installing XP SP2 security patches on my box, I can not open
Enterprise Manager. It crashes when I click on icon to bring the analyzer up.
I get two error in event log,
========================
1. Event Type:Error
Event Source:Application Error
Event Category:None
Event ID:1000
Date:1/18/2005
Time:3:30:09 PM
User:N/A
Computer:WXPP-LT_AMINH
Description:
Faulting application mmc.exe, version 5.1.2600.0, faulting module mmc.exe,
version 5.1.2600.0, fault address 0x0000bb5b.
For more information, see Help and Support Center at
http://go.microsoft.com/fwlink/events.asp.
Data:
0000: 41 70 70 6c 69 63 61 74 Applicat
0008: 69 6f 6e 20 46 61 69 6c ion Fail
0010: 75 72 65 20 20 6d 6d 63 ure mmc
0018: 2e 65 78 65 20 35 2e 31 .exe 5.1
0020: 2e 32 36 30 30 2e 30 20 .2600.0
0028: 69 6e 20 6d 6d 63 2e 65 in mmc.e
0030: 78 65 20 35 2e 31 2e 32 xe 5.1.2
0038: 36 30 30 2e 30 20 61 74 600.0 at
0040: 20 6f 66 66 73 65 74 20 offset
0048: 30 30 30 30 62 62 35 62 0000bb5b
0050: 0d 0a ..
2.
Event Type:Error
Event Source:Application Error
Event Category:None
Event ID:1001
Date:1/18/2005
Time:3:30:22 PM
User:N/A
Computer:WXPP-LT_AMINH
Description:
Fault bucket 02874011.
For more information, see Help and Support Center at
http://go.microsoft.com/fwlink/events.asp.
Data:
0000: 42 75 63 6b 65 74 3a 20 Bucket:
0008: 30 32 38 37 34 30 31 31 02874011
0010: 0d 0a ..
=======================
I removed the patches using reollback option of XP, but after removal even
explorer crashes. I re-installed SQL client tools, but result is same...
Any one has idea how to resolve this?
Thanks,
Hiten
Maybe the snap-in has become corrupt or damaged.
Try renaming the existing SQL Server Enterprise Manager.MSC
file.
Then copy the SQL Server Enterprise Manager.MSC file from
the your SQL Server CD to the same location.
-Sue
On Tue, 18 Jan 2005 12:39:11 -0800, "Hiten"
<Hiten@.discussions.microsoft.com> wrote:
>Hi,
>After installing XP SP2 security patches on my box, I can not open
>Enterprise Manager. It crashes when I click on icon to bring the analyzer up.
>I get two error in event log,
>========================
>1. Event Type:Error
>Event Source:Application Error
>Event Category:None
>Event ID:1000
>Date:1/18/2005
>Time:3:30:09 PM
>User:N/A
>Computer:WXPP-LT_AMINH
>Description:
>Faulting application mmc.exe, version 5.1.2600.0, faulting module mmc.exe,
>version 5.1.2600.0, fault address 0x0000bb5b.
>For more information, see Help and Support Center at
>http://go.microsoft.com/fwlink/events.asp.
>Data:
>0000: 41 70 70 6c 69 63 61 74 Applicat
>0008: 69 6f 6e 20 46 61 69 6c ion Fail
>0010: 75 72 65 20 20 6d 6d 63 ure mmc
>0018: 2e 65 78 65 20 35 2e 31 .exe 5.1
>0020: 2e 32 36 30 30 2e 30 20 .2600.0
>0028: 69 6e 20 6d 6d 63 2e 65 in mmc.e
>0030: 78 65 20 35 2e 31 2e 32 xe 5.1.2
>0038: 36 30 30 2e 30 20 61 74 600.0 at
>0040: 20 6f 66 66 73 65 74 20 offset
>0048: 30 30 30 30 62 62 35 62 0000bb5b
>0050: 0d 0a ..
>2.
>Event Type:Error
>Event Source:Application Error
>Event Category:None
>Event ID:1001
>Date:1/18/2005
>Time:3:30:22 PM
>User:N/A
>Computer:WXPP-LT_AMINH
>Description:
>Fault bucket 02874011.
>For more information, see Help and Support Center at
>http://go.microsoft.com/fwlink/events.asp.
>Data:
>0000: 42 75 63 6b 65 74 3a 20 Bucket:
>0008: 30 32 38 37 34 30 31 31 02874011
>0010: 0d 0a ..
>=======================
>I removed the patches using reollback option of XP, but after removal even
>explorer crashes. I re-installed SQL client tools, but result is same...
>Any one has idea how to resolve this?
>Thanks,
>Hiten
|||Someone with the same problem before SP2 found this to be a workaround:
http://groups-beta.google.com/group/...e66a3e81c65f5e
[I opened] mmc.exe in the Windows/system32 folder and add[ed]
the Enterprise Manager snap-in. Now I can just run enterprise
manager that way! It's not ideal, but it works :-)
Steve Kass
Drew University
Hiten wrote:
>Hi,
>After installing XP SP2 security patches on my box, I can not open
>Enterprise Manager. It crashes when I click on icon to bring the analyzer up.
>I get two error in event log,
>========================
>1. Event Type:Error
>Event Source:Application Error
>Event Category:None
>Event ID:1000
>Date:1/18/2005
>Time:3:30:09 PM
>User:N/A
>Computer:WXPP-LT_AMINH
>Description:
>Faulting application mmc.exe, version 5.1.2600.0, faulting module mmc.exe,
>version 5.1.2600.0, fault address 0x0000bb5b.
>For more information, see Help and Support Center at
>http://go.microsoft.com/fwlink/events.asp.
>Data:
>0000: 41 70 70 6c 69 63 61 74 Applicat
>0008: 69 6f 6e 20 46 61 69 6c ion Fail
>0010: 75 72 65 20 20 6d 6d 63 ure mmc
>0018: 2e 65 78 65 20 35 2e 31 .exe 5.1
>0020: 2e 32 36 30 30 2e 30 20 .2600.0
>0028: 69 6e 20 6d 6d 63 2e 65 in mmc.e
>0030: 78 65 20 35 2e 31 2e 32 xe 5.1.2
>0038: 36 30 30 2e 30 20 61 74 600.0 at
>0040: 20 6f 66 66 73 65 74 20 offset
>0048: 30 30 30 30 62 62 35 62 0000bb5b
>0050: 0d 0a ..
>2.
>Event Type:Error
>Event Source:Application Error
>Event Category:None
>Event ID:1001
>Date:1/18/2005
>Time:3:30:22 PM
>User:N/A
>Computer:WXPP-LT_AMINH
>Description:
>Fault bucket 02874011.
>For more information, see Help and Support Center at
>http://go.microsoft.com/fwlink/events.asp.
>Data:
>0000: 42 75 63 6b 65 74 3a 20 Bucket:
>0008: 30 32 38 37 34 30 31 31 02874011
>0010: 0d 0a ..
>=======================
>I removed the patches using reollback option of XP, but after removal even
>explorer crashes. I re-installed SQL client tools, but result is same...
>Any one has idea how to resolve this?
>Thanks,
>Hiten
>
Subscribe to:
Posts (Atom)