2005: SIMPLE QUESTION: Error Log

May 30, 2006

Hello,
When I received a message "... See the SQL Server errorlog for details
...." I opened Management / SQL Server Logs where I see:
Current - 2006-05-30 12:19:00
Archive #1 - 2006-05-30 09:49:00
Archive #2 - 2006-05-30 08:27:00
etc.
But each of these logs contains "0 Item(s)". How to see log entries?
Thank you very much
/RAM/

View 2 Replies


ADVERTISEMENT

Fatal Error Doing Simple Queries From An Sql 2000 To Sql 2005 Exported Database

Jun 8, 2006

I have been trying to export an sql2000 database to sql2005 with no luck. I continuosly get the error

Msg 0, Level 11, State 0, Line 0

A severe error occurred on the current command. The results, if any, should be discarded.

I have looked upon all support material and have installed the latest sql2005 service pack, but this has not fixed the problem. a simple query as:

select * from [transaction] ta,transactionentry tr

where tr.transactionnumber=ta.transactionnumber and

glacctid=6 and ta.[time]> '3/01/2006'

would produce this fatal error.

the current version I am using is:

Microsoft SQL Server 2005 - 9.00.1399.06 (Intel X86) Oct 14 2005 00:33:37 Copyright (c) 1988-2005 Microsoft Corporation Standard Edition on Windows NT 5.2 (Build 3790: Service Pack 1)

This problem is happening on some of the most important tables in the database.

the error log contains the following:

2006-06-06 11:43:32.59 spid54 ***Stack Dump being sent to C:Program FilesMicrosoft SQL ServerMSSQL.1MSSQLLOGSQLDump0001.txt
2006-06-06 11:43:32.59 spid54 SqlDumpExceptionHandler: Process 54 generated fatal exception c0000005 EXCEPTION_ACCESS_VIOLATION. SQL Server is terminating this process.
2006-06-06 11:43:32.59 spid54 * *******************************************************************************
2006-06-06 11:43:32.59 spid54 *
2006-06-06 11:43:32.59 spid54 * BEGIN STACK DUMP:
2006-06-06 11:43:32.59 spid54 * 06/06/06 11:43:32 spid 54
2006-06-06 11:43:32.59 spid54 *
2006-06-06 11:43:32.59 spid54 *
2006-06-06 11:43:32.59 spid54 * Exception Address = 0136B4F0 Module(sqlservr+0036B4F0)
2006-06-06 11:43:32.59 spid54 * Exception Code = c0000005 EXCEPTION_ACCESS_VIOLATION
2006-06-06 11:43:32.59 spid54 * Access Violation occurred writing address FFFFFFFC
2006-06-06 11:43:32.59 spid54 * Input Buffer 260 bytes -
2006-06-06 11:43:32.59 spid54 * select * from [transaction] tr,transactionentry te where tr.
2006-06-06 11:43:32.59 spid54 * transactionnumber = te.transactionnumber and glacctid = 6
2006-06-06 11:43:32.59 spid54 *
2006-06-06 11:43:32.59 spid54 *
2006-06-06 11:43:32.59 spid54 * MODULE BASE END SIZE
2006-06-06 11:43:32.59 spid54 * sqlservr 01000000 02BA7FFF 01ba8000
2006-06-06 11:43:32.59 spid54 * ntdll 7C800000 7C8BFFFF 000c0000
2006-06-06 11:43:32.59 spid54 * kernel32 77E40000 77F41FFF 00102000
2006-06-06 11:43:32.59 spid54 * MSVCR80 78130000 781CAFFF 0009b000
2006-06-06 11:43:32.59 spid54 * msvcrt 77BA0000 77BF9FFF 0005a000

I have followed instructions on some support issues posted but none have helped. If anyone has any solution to this problem PLEASE HELP!!!!.

Thanks.

View 7 Replies View Related

Working Since Morning, Simple Error But Unable To Resolve, ERROR : 26 , Please Help

Dec 15, 2006

dear friends,
 i started using Asp.net for developing webparts, web parts automatically connect to a database to be created and saved in the database.
i had already Sql Server 2005 Express Edition installed so my webpart page ran and automatically created the database "AspNetDb" in the "App_Data" folder.
but when i uninstalled Sql Server 2005 Express Edition and then installed the Sql Server 2005 Enterprise Edition, it gave me the following Error 26 as below :

--------------------------------------------------------- Beginning of Error Message -------------------------------------------------- 
 An error has occurred while establishing a connection to the server.  When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified)
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. SQLExpress database file auto-creation error:
The connection string specifies a local Sql Server Express instance using a database location within the applications App_Data directory. The provider attempted to automatically create the application services database because the provider determined that the database does not exist. The following configuration requirements are necessary to successfully check for existence of the application services database and automatically create the application services database:

If the applications App_Data directory does not already exist, the web server account must have read and write access to the applications directory. This is necessary because the web server account will automatically create the App_Data directory if it does not already exist.
If the applications App_Data directory already exists, the web server account only requires read and write access to the applications App_Data directory. This is necessary because the web server account will attempt to verify that the Sql Server Express database already exists within the applications App_Data directory. Revoking read access on the App_Data directory from the web server account will prevent the provider from correctly determining if the Sql Server Express database already exists. This will cause an error when the provider attempts to create a duplicate of an already existing database. Write access is required because the web server accounts credentials are used when creating the new database.
Sql Server Express must be installed on the machine.
The process identity for the web server account must have a local user profile. See the readme document for details on how to create a local user profile for both machine and domain accounts.
--------------------------------------------------------- End of Error Message -------------------------------------------------- 
then when i checked the Machine.config file, i found this....
  <connectionStrings>    <add name="LocalSqlServer" connectionString="data source=.SQLEXPRESS;Integrated Security=SSPI;AttachDBFilename=|DataDirectory|aspnetdb.mdf;User Instance=true" providerName="System.Data.SqlClient" />  </connectionStrings>
then i thought it's becoz, of the datasource thing that the Machine.Config file supports by default the default free edition of Sql Server 2005 which is the Sql Server 2005 Express Edition.
but friend in my company we use Sql Server 2005 Enterprise Edition, so can anybody pls guide me and get me out of this soup on helping me to use Sql Server 2005 Enterprise Edition by modifying either 1) Machine.Config File and/or  2) Web.Config file and/or 3) any other way, but please help i want to do this, please......
regards and thanks
Gurjit Singh 

View 2 Replies View Related

Simple Syntax Error

May 7, 2008

I'm using sql server 2005 and in sql management studio I am getting a syntax error from this simple below code:
WITH CustListTemp AS
(SELECT OrderID, Locked, OrderStatus, Resubmissions, ROW_NUMBER() OVER (ORDER BY OrderID) AS RowNumber
FROM dbo.OrderInfo
)
 
Can somebody please tell me what ther error is so I can correct it? I even had someone at work take a look at it and couldn't get it either.

View 4 Replies View Related

DTS Package Error - Something Simple?

Dec 11, 2003

I have a multi-step DTS package that I get the following error when I try to execute it:

Package Error
Error Source : microsoft ole db provider for sql server
Error Description : [DBNETLIB][ConnectionOpen (connect()).]SQL Server does not exist or access denied

Am I missing something obvious? I'm sure it is something simple but I can't seem to get it. Thank you in advance for you assistance.

View 1 Replies View Related

Simple Update Error

Jul 20, 2005

Hey all,i have a students_table which i want to do a multiple update on.Update student_tableset grant = 35000where course_id = 2There are lots of students in the student table which have course_id of2.I get this error:Subquery returned more than 1 value. This is not permitted when thesubquery follows =, !=, <, <= , >, >= or when the subquery is used as anexpression.The statement has been terminated.Does anyone know how to do a multiple update like this.It seems such asimple thing but im confused*** Sent via Developersdex http://www.developersdex.com ***Don't just participate in USENET...get rewarded for it!

View 1 Replies View Related

Simple Error Question?

Jun 29, 2006

Hello all!

Working with SQL 2000. If I create a rollback trigger for a value that can not be less 0. After it rolls back, can I throw a custom error message in my .net application from SQL?



Thanks!

View 5 Replies View Related

I Think I Found SQL 2005 Bug By Doing Simple Group BY!!!

Jul 4, 2007

I did:
select city, count(*) from classifieds_address group by city
You would think it would distiguish between "Koh Phangan" and "Koh Phangan ". No!!! It shows them as one row in SQL!!! Is this SQL bug?
Aberdeen 1bayombong 1Brooklyn 4Castle Peak Bay 1Causeway Bay 2Chiang Mai 1Hong Kong 1Hong Kong  Wan Chai 1Hong Kong Island 10Hong Kong Sheung Wan 1Karachi 1Koh Phangan 21Koh Samui 37Koh Tao 9Kowloon 13Kowloon, Tsim Sha Tsui 1Lantau Island 1Mid-Levels 3New Territories 2New York 3North Point 1Oligar 1Tsim Sha Tsui 1Wan Chai 5Yau Ma Tei 1Yau Ma Tei, Kowloon 1

View 5 Replies View Related

Simple Pivot Sql Server 2005

Feb 12, 2008

Is there a way to include multiple aggregations in one pivot statement?

For example:

select
category_cd,
[a]
from
(
select
category_cd,
status_cd,
balance
from
table
) as t
pivot
(
sum(balance) for status_cd in
(
[a]
)
) as p

will return:

category_cda
1 2399059.92
2 174310512.4
3 2211823370
4 1564431422

But I'd also like to get a count for the pivot column. Can anyone point me in the right direction. Thank you.

View 1 Replies View Related

Ridiculously Simple Syntax Error

Feb 16, 2007

in SQL query analyzer i have this skeleton test query:

DECLARE @nLen int
DECLARE @strData varchar(200)
DECLARE @strDelim varchar(50)
DECLARE @nPos int

SELECT
OwnersName1
= (IF len(OwnersName) > 0 OwnersName
-- IF dbo.InString(OwnersName,'&',1) > 0 'yes'
--if dbo.InString(OwnersName,' AND ',1) > 0 'yes'
--if dbo.InString(OwnersName,', ',2) > 0 'yes'
--ELSE OwnersName
)
,
OwnersName2 = OwnersName
--@strDelim as Delim
FROM dbo.TateWake
WHERE OwnersName>'9'

i get this error:
Server: Msg 156, Level 15, State 1, Line 8
Incorrect syntax near the keyword 'IF'.
Server: Msg 170, Level 15, State 1, Line 8
Line 8: Incorrect syntax near 'OwnersName'.

if i replace
IF len(OwnersName) > 0 OwnersName
with: len(OwnersName)
there is no error.

what the heck is going on?
thanks...

View 2 Replies View Related

Ridiculously Simple Syntax Error

Feb 16, 2007

this is my 3rd attempt at posting this. other attempts did not post for some reason. now i'm home from work and so i can't cut and paste. this is from memory.

in query analyzer, i made a ridiculously simple query which returns a syntax error that i can't resolve:

SELECT name1 =
(
IF len(name) > 0 len(name)
),
name2 = name
FROM ownertable

this gives an error something like:
syntax error near IF on line 3

when i remove the IF len(name) > 0
the expression is evaluated as expected with no error. what is going on?

I must apologize for the simplification, but my posts kept going to the ether for some reason. I have had other dba's look at it and no one knows why this is happening in my office. nor can i understand why my posts don't stick. i even got a message from the forum app that i posted a duplicate message!

View 5 Replies View Related

Error While Executing Simple Query :(

Dec 21, 2007

Hi,

I am using this query to execute but it didn't

declare @AccountID numeric(3,0)
set @AccountID = 101
select * from AccountTest
WHERE AccountID IN
(CASE
WHEN @AccountID = 101 THEN (100,101)
ELSE @AccountID
END)

I m getting error like

Msg 102, Level 15, State 1, Line 9
Incorrect syntax near ','.

Pls help me out

T.I.A

View 3 Replies View Related

SET RECOVERY SIMPLE Generates Error

Feb 27, 2006

I've come across several references indicating that the recovery model can be set to simple by using the following sql statement:

ALTER DATABASE dbname SET RECOVERY SIMPLE

However, all I get is the error message below. What is the correct syntax?

Msg 102, Level 15, State 1, Line 1

Incorrect syntax near '.'.

Msg 195, Level 15, State 7, Line 1

'recovery' is not a recognized SET option.

View 7 Replies View Related

Error With A Simple JOIN Query....

Apr 12, 2007

Hi!



I've a big problem by using the following query :






Code Snippet

public SqlCeResultSet selectRSQuery(String query)

{

SqlCeResultSet resultSet = initializeCommand(query).ExecuteResultSet(ResultSetOptions.Scrollable | ResultSetOptions.Updatable);

return resultSet;

}



SqlCeResultSet resultSet = sgb.selectRSQuery(

"SELECT p.pId, p.pLogin FROM Profiles p, ProfilesGroups pg, Groups g " +

"WHERE g.gId = pg.tpGroupId " +

"AND p.pId = pg.tpProfileId " +

"AND g.gProfileID = '" + app.Settings.Default.id + "'");



It return me this error :

Cannot generate an updatable cursor for the query because there is a non-standard join expression.



What can I do??



Thxx

View 9 Replies View Related

Simple Database Problem (mssql 2005)

Nov 30, 2006

Hello,
How do you copy all stored procedures into a .sql file using Microsoft SQL server management studio?I am trying to make a database installation file that should have all the tables and SP in it, can't find away to copy that information to a .sql file.
 
Patrick

View 1 Replies View Related

Simple Trigger For SQL Server Express 2005

Jun 12, 2008

I've this tableCREATE TABLE [dbo].[Attivita]( [IDAttivita] [int] IDENTITY(1,1) NOT NULL, [IDOwner] [int] NULL, [IDAttivitaStato] [varchar](1) COLLATE Latin1_General_CI_AS NULL, [IDAttivitaTipo] [varchar](2) COLLATE Latin1_General_CI_AS NULL, [IDAnagrafica] [int] NULL, [Data] [datetime] NULL CONSTRAINT [DF_Attivita_Data] DEFAULT (getdate()), [Descrizione] [varchar](max) COLLATE Latin1_General_CI_AS NULL, [Privato] [bit] NULL, [LastUpdate] [datetime] NULL CONSTRAINT [DF_Attivita_LastUpdate] DEFAULT (getdate()), CONSTRAINT [PK_Attivita] PRIMARY KEY CLUSTERED ( [IDAttivita] ASC)WITH (PAD_INDEX = OFF, IGNORE_DUP_KEY = OFF) ON [PRIMARY]) ON [PRIMARY]How Can I create a trigger for modify the IDAttività Stato field in specific situaion: if IDAttivitaTipo ==  OK or  == NOIDAttivitaStato must be set to CPlease note that I can write in the IDAttivitaStato field (during my code operation).... but I would like also automatic update if the IDAttivitaTipo is OK or NO Can you help me for create this with a trigger?Thanks 

View 2 Replies View Related

Simple Objects Transfer From 2000 Db To 2005 Db

Feb 1, 2006

creating a simple package and cant get it to run below is the error. when i check the source 2k db its there see below...

i am clue free of the issus...

SSIS error message

Error: 0xC002F325 at Transfer SQL Server Objects Task, Transfer SQL Server Objects Task: Execution failed with the following error: "ERROR : errorCode=0 description='FK_MoreBDRInformation_dbo_BatchDataReports' is not a constraint. helpFile= helpContext=0 idofInterfaceWithError={8BDFE893-E9D8-4D23-9739-DA807BCDC2AC}".

source Server DB sysobjects table record

name id xtype uid info status base_schema_ver replinfo parent_obj crdate ftcatid schema_ver stats_schema_ver type userstat sysstat indexdel refdate version deltrig instrig updtrig seltrig category cache
FK_MoreBDRInformation_dbo_BatchDataReports 1618573300 F 1 0 0 0 0 86043838 2006-01-31 12:35:41.530 0 0 0 F 0 11 0 2006-01-31 12:35:41.530 0 0 0 0 0 0 0

View 1 Replies View Related

SQL 2005 Express Timeout On Simple Queries

May 5, 2007

Hi everybody!



I have made a simple application with VB6 and SQL 2005 Express.



And after testing it in a network simulated with Virtual-Machine Workstation, the "real world" application was first getting slower and slower, and finally giving timeout errors.



It is even difficult to connect. The application times out always at 30 secs although the ado connection timeout was established longer (45)



I have checked on the machine where the server is installed, just in case the slow down was due to network problems, but it fail locally too.



Any help is wellcome







View 6 Replies View Related

What Will Happen If I Choose RecoveryModel Is Simple In SQL 2005

Aug 14, 2007

We are using SQL 2005 for maintaing the Poerplant database,for that we have to run reports to get the data from the database.We have selected "RecoveryModel" is Simple.but if we select recovery model "Simple" we cannot get the full Database backup.And if we select the Recovery Model is "Full" the size of transaction log files for historical database is growing like anyway.So what i think that if we choose recovery model as "Simple" the size of transaction log files will be in controlable size.But if select Recovery model is"Full" then the size of transaction logfiles are growing.

Plz give ur valueable suggestion.

thanks,
Amit

View 1 Replies View Related

Few Simple (silly) Questions On SQL 2005 &&amp; CLR Integration.

Mar 2, 2007

Hi all,

I need few clarifications from you experts regarding SQL server 2005 & CLR integration ( my questions might be simple and silly, please bear with me).

A web service should be invoked from the SQL Server , Is CLR stored procedure only way to do that ?
Does SQL Server uses the CLR only when the CLR support is enabled ? OR SQL Server itself runs on top of the CLR no matter it is enabled or not ?
What are the major disadvantages of using CLR stored procedures instead of T-SQL?

Thanks in advance,

DBLearner

View 3 Replies View Related

Pre-execute Error In Simple Import/export

Mar 17, 2006

I am trying to copy data from a SQL Server 2000 DB to SQL Server 2005 DB using the import/export wizard in SQL Server Management Studio. The two databases are not identical with different table names and different columns but I thought I had set up all the right mappings and had set the 'Enable identity insert' option. When I ran the wizard it errored at the Pre-execute phase. I simplified the wizard down to one table and only as couple of varchar columns and this also errored in the same way. The error report is detailed below.

For reference the SQL2000(ent. edn) DB is on a windows 2000 server and the SQL2005(dev. edn) DB and the management studio are both on my WinXPSP2 workstation.

Could somebody explain why these errors have occured and more importantly how to rectify the problem?

Many thanks,
Michael.



Operation stopped...

- Initializing Data Flow Task (Success)

- Initializing Connections (Success)

- Setting SQL Command (Success)

- Setting Source Connection (Success)

- Setting Destination Connection (Success)

- Validating (Warning)



Messages

Warning 0x80047076: Data Flow Task: The output column "DateAdd" (23) on output "OLE DB Source Output" (11) and component "Source - tccNewsArticles" (1) is not subsequently used in the Data Flow task. Removing this unused output column can increase Data Flow task performance.
(SQL Server Import and Export Wizard)


Warning 0x80047076: Data Flow Task: The output column "DateChg" (26) on output "OLE DB Source Output" (11) and component "Source - tccNewsArticles" (1) is not subsequently used in the Data Flow task. Removing this unused output column can increase Data Flow task performance.
(SQL Server Import and Export Wizard)


... NOTE: I have removed the rest of the warnings as they were the same as above (many of them).

- Pre-execute (Error)



Messages

Error 0xc0202009: Data Flow Task: An OLE DB error has occurred. Error code: 0x80040E21.
An OLE DB record is available. Source: "Microsoft SQL Native Client" Hresult: 0x80040E21 Description: "Multiple-step OLE DB operation generated errors. Check each OLE DB status value, if available. No work was done.".
(SQL Server Import and Export Wizard)


Error 0xc0202025: Data Flow Task: Cannot create an OLE DB accessor. Verify that the column metadata is valid.
(SQL Server Import and Export Wizard)


Error 0xc004701a: Data Flow Task: component "Destination - Nrs_NewsArticles" (112) failed the pre-execute phase and returned error code 0xC0202025.
(SQL Server Import and Export Wizard)


- Executing (Success)

- Copying to [NereusV2_1].[dbo].[Nrs_NewsArticles] (Stopped)

- Post-execute (Stopped)

- Cleanup (Success)



Messages

Information 0x4004300b: Data Flow Task: "component "Destination - Nrs_NewsArticles" (112)" wrote 0 rows.
(SQL Server Import and Export Wizard)




View 1 Replies View Related

Simple Expression Returns Error In Report, Why?

Apr 22, 2008

So, here is my expression that I use in a textbox on the site header. In the report it just returns error... any ides?

="Wareneingangsübersicht" + " " + today() + " / " +

iif(datepart("WeekdayName",dateadd("d",1,today()))= "Samstag", DateAdd("d",3,today()), DateAdd("d",1,today()))

View 5 Replies View Related

Real Simple Liscensing Question For Sql Server 2005.

Apr 11, 2006

Hell, I host web pages on a server(s) that I own, located in a datacenter.I am trying to figure out how to properly liscnese sql server 2005.I have called microsoft, and the people i talk to dont seem to understand my situation.  They keep asking me about the number of employess i have, which is totally irrelevant.  Let me give you a basic example.Example 1.My personal web page has a blog on it.  The blog data is stored in a SQL database.  Its a popular blog, thousands of anonymous people reading my blog every month via my webpage.  The only "thing" accessing the SQL databse is an asp.net script i write, which then turns around and presents the data via html over the www.  just like every other blog in the universe. Example 2.I sell artwork over the internet via my web page.   My web page uses a shopping cart system which makes use of an SQL database to keep track of inventory and orders etc.  No one ever tries to connect to my database, they just use the shopping cart on my web page which of course connects to the database.Now according to the MS liscensing documentation it seems that i can buy sql server w/ 5 device CAL's.  Since I only have 1 or 2 webservers accessing the database server, that should be no problem right?So my basic question is this:   is a single Device CAL enough to allow one webserver to connect to one sql server and then show dynamic content to thousands of anonymous users (whoever happens to visit my sites?).Thank you very much for any help you can provide.

View 1 Replies View Related

Simple Migration From MySQL To SQL Server Express 2005?

Mar 18, 2006

Normally I'd go and write a bunch of code for doing it manually... But instead of that, maybe there is a smarter way?

What I know is that you can get some kind of dump out of MySQL but I would be very surprised if that could be directly read into SQL Express ??

So if you have a few step guide to migrate from MySQL to SQL Express, I am all ears (and eyes)!

Thanks!

(Yes I am aware there is some DTS thingy for this but could not find it in the Express folders)

View 6 Replies View Related

Error Msg While Running Relatively Simple Query (large Result Set)

Jul 17, 2007

While running query below on SQL Server 2005 (Build 3790: Service Pack 2):



SELECT DISTINCT pkg.PrimaryBarcode

FROM dbo.Package AS pkg (NOLOCK)

JOIN dbo.PackageCycle AS pc (NOLOCK)

ON pkg.PackageKey = pc.PackageKey

WHERE (pkg.BillCycleDateKey >= 20061201) OR

(pkg.BillStatusKey = 1)



I received a partial result set followed by

An error occurred while executing batch. Error message is: Couldn't replace text



I suspect this is a memory issue, but cannot find any reference to this particular msg on the Microsoft forums or the other 3rd party forums. PrimaryBarcode is a varchar(50)



I am not sure where to go from here. I would appreciate any ideas. Thanks in advance.



Cheers,

Mike Byrd

View 2 Replies View Related

A Simple Question On The Connection String Format On Sql Server 2005!

Feb 22, 2006

Hi everyone!
I am new to visual studio 2005 and sql server 2005.
Up to now i was using visual studio 2003 and ms access.

When i wanted to create  a web application that communicates with
an access database,  i just had to take the *.mdb file and put it
into a specific folder inside my application's folder and then use
Server.MapPath on the connection string (so it can run on any pc).

Now, i want to do the same with sql server 2005 and visual studio 2005.
I use the connection string: "Server=MYSERVER;Initial
Catalog=test_db;Integrated Security=SSPI".

My problems are:
1) Can i just take the *.mdf file put it inside the App_Data folder like i did on access?
2) What should be the connection string so that my application can run on any pc (with sql server 2005)?

Thanx in advance guys!

View 1 Replies View Related

Execution Time Gap Between Simple Tsql And Stored Procedure In SQl Server 2005

Oct 16, 2007

Hi ,

I ma using sql server 2005.I have a bunch of statements of sql and i have created a stored procedure for those. When i execute i found that there is lot's of difference between execution time of stored procedure and direct sql in query windows.

can anyone help me to optimize the execution time for stored prcedure even stored prcedure is very simple.
I have used sql server 2000 and i am new in sql server 2005.

View 1 Replies View Related

Simple Customers ~ Orders Table Handling Question SQL Express 2005

Dec 13, 2007



I want to refer in a table quotes to customers and itemes from another table.

here is my table list in database:
"Customers"
"PriceList"

I want to create another table which through it I can create qoutes for customers suing a collection of items in PriceList table.

for example I want to be able to create something like this:

Title:
my quote example
QuoteID:
46543
Items (retrieved from PriceList table):
370
474
456
belongsTo (a relation to CustomerID in Cstomers table):
6234876
Discount, Date, WrittenBy, etc.



how many tables do I have to use for it, and what queries I have to write, and do I have to create any special relationships?

regards

View 9 Replies View Related

Please Help This Should Be Simple Trying To Use Variables With A Copy DB Control Flow, Ssis Reports Following Error:

Dec 26, 2007

Why isn't there some documentation on how to do this. This should be really simple and it has taken me 2 weeks and I still haven't gotten an answer. Please Help Does anyone know the answner or some place where there is some documentation!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

I get the following error when I try to substitute the strings in the databasedetails collection with variables:
Error: Object reference not set to an instance of an object. StackTrace: at Microsoft.SqlServer.Dts.Tasks.TransferObjectsTask.TransferObjectsTask.CheckLocalandDestinationStatus(Database srcDatabase, DatabaseInfo dbDetail) at Microsoft.SqlServer.Dts.Tasks.TransferObjectsTask.TransferObjectsTask.TransferDatabasesUsingSpAttachDetach()

I created the following variables:
strDestinationDB = AirCL2Exp_new3
strDestinationDBPath = C:Program FilesMicrosoft SQL ServerMSSQL.2MSSQLDATAAirCL2Exp_new3_Data.mdf
strDestinationLGPath = C:Program FilesMicrosoft SQL ServerMSSQL.2MSSQLDATAAirCL2Exp_new3_Data.ldf
strSourceDB = AirCL2Exp
strSourceDBPath = C:Program FilesMicrosoft SQL ServerMSSQL.2MSSQLDataDataNewAirCL2Exp_Data.mdf
strSourceLGPath = C:Program FilesMicrosoft SQL ServerMSSQL.2MSSQLDataDataNewAirCL2Exp_Log.ldf

I then assigned those variable to DatabaseDetails Collection:

DatabaseName = @strSourceDB
DestinationDatabaseName = @strDestinationDB

Inaddtion I also assigned the following to the two DatabaseFiles Collection:
for 0:
DatabaseFileSize = 0
DestinationFilePath = @strDestinationDBPath
FileType = DatabaseFile
SourceFilePath = @strSourceDBPath
SourceSharePath = @strSourceDBPath

for 1:
DatabaseFileSize = 0
DestinationFilePath = @strDestinationLGPath
FileType = LogFile
SourceFilePath = @strSourceLGPath
SourceSharePath = @strSourceLGPath

View 13 Replies View Related

Simple DB Operations Are Throwing Native Exception Error - 0xc0000005 - Intermittently

Dec 4, 2006

Hi All,

We have written a multithreaded application in which we are maintaining separate Database connections for each thread. these connections are opened and closed at the start and exit of the thread.

We have observed that even if there is only one thread running ( application thread), execution of simple Select queries some times throws Native exception(Error - 0xc0000005 ).

This error comes intermittently. Execution of same query doesn't throw exception.

Further investigation by breaking the debug at the time of native exception and then looking into the stack trace shows that native exception has occured at one of the Native API (CompileQueryPlan() ) which is being called implicitly by the SQL Mobile.

Each time when we see native exception stack trace shows failure at CompileQueryPlan() call.

Let me know if this is a known defect in SQL Mobile 2005 or there is something else that is causing native exception.

Thanks,

Nikhil











View 11 Replies View Related

Simple Simple Linking Tables & Perform Calculation

Mar 22, 2007

found it

View 3 Replies View Related

Error: Button Click Is Undefined - Simple If Statement With Sql Command Wont Work (c#)

Feb 2, 2008

hello it seems lack of c# skills is getting the better of me here...iv been trying to get this to work for hours now without success. I have just started working in c# so i am a beginner :)
all i want to do it query the database, check to see if a title exists, if yes then populate textbox saying 'title in use' but if the title doesnt exists then continue executing rest of code to add the title.
You'll notice iv tried to use string variables and sqlDataAdapter but i cant get these to work either...please help
so far i have this that keeps giving me the error that my button click is undefined: protected void bookButton_Click(object sender, EventArgs e){
//string title;try{SqlConnection conn1 = new SqlConnection();
conn1.ConnectionString =
"Data Source=Gemma-PC\SQLEXPRESS;" +"Initial Catalog=SoSym;" +
"Integrated Security=SSPI;";SqlCommand findTitle = new SqlCommand("SELECT title FROM Publication WHERE title='" + titleTextBox.Text + "';", conn1);
 
conn1.Open();
findTitle.ExecuteNonQuery();
 /*
DataSet myDataSetTitle = new DataSet("PublicationTitle");
myDataSetTitle.Clear();
myDataAdapterTitle.Fill(myDataSetTitle);//myDataSet contains results from above SELECT statement
title = myDataSetTitle.Tables[0].Rows[0]["title"].ToString();*/
}catch(Exception ex)
{TitleInvalidMessage.Text = "Title Not Accepted: This title is already in use by another publication" +ex.Message;
}
//title does not exist in table so continue and add to database
//rest of code here

View 5 Replies View Related

Simple Question (Hope Simple Answer Too)

May 26, 2004

Hey,

I have MS SQL database.
I have procedure:



code:--------------------------------------------------------------------------------
CREATE PROCEDURE dbo.Reg_DropTable
@ModuleId varchar(10)
AS
declare @TableName varchar, @kiek numeric
set @TableName = 'reg_'+@ModuleId

begin
DROP TABLE @TableName <- HERE I GOT ERROR
end
GO
--------------------------------------------------------------------------------


I got error when using variable with tables names.
How to do this?

Ps. Number is send to this function and it must drop table with name Reg_[That number]

View 1 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved