New To SQL - Having Difficulties Setting Up
May 24, 2008
Hello again
sorry to bother again but I am hvaing difficulty setting up the SQL server 2005. I have downloaded and installed the following
.Net Framework 2.0 Serv Pack 1
MS SQL server 2005
MS SQL server Native Client
MS SQL server Setup support
MS SQL server VSS Writer
AdventureWorksDB.msi as a sample database i believe
When I want to launch the program I point to Programs, that dispplays MS SQL Server 2005 which displays Configurations Tools which when pointed displays
1) SQL Server Configuration manager (has the icon with little hammer and folder whatever it is,
2) SQL Server Error and Usage reporting
3) SQL server surface area configuration
None of them is letting me to open a screen to see any tables and write a query.
What am i missing?
thanks
ted
View 4 Replies
ADVERTISEMENT
May 27, 2008
Hello,
I'm trying to create a report that displays different sized customers in each office.
The tables look something like this:
client(id,size,representative)
representative(id,office)
office(id,name)
I would like the report to look something like this:
_______| all | <10 | 10-100 |
office1|
-----------------------------
office2|
------------------------------
I can get list of the offices and amount of all the clients like this:
SELECT office.name, COUNT(client.id) AS all
FROM office INNER JOIN
representative ON representative.office = office.id INNER JOIN
client ON client.representative = representative.id
group by office.name
But I just can't get my head around how to get rest of the information I want. If anyone has any suggestions how to proceed from here, I would be grateful.
View 2 Replies
View Related
Aug 6, 2007
I'm using ASP pages to access a Microsoft SQL 2005 SP1 database server for information that populates dropdown menus. I ran into an interesting problem. We can query all existing data without a problem (all expected rows return and correctly populate the dropdowns).
I manually add a new row to the database table for a dropdown. I can manually query the database from the SQL2005 management tool, and the new records are included in the results.
I load the ASP page, and the newly added records never appear in the dropdown... only the old, existing data.
What could cause this? The queries from ASP are the same as the queries I make directly from the SQL server.
View 10 Replies
View Related
Jan 3, 2006
I am having some problems wit a form where i need to insert a record into a table and then get the id of the record i just inserted and use it to insert a record in another table for a many to many relationship. The code is below (I cut out as much as i could to make it more readable).
The erro message i get is this:
Error saving file ATLPIXOFC.txt Reason: System.Data.SqlClient.SqlException: Prepared statement '(@FileName varchar(13),@ i' expects parameter @FileID, which was not supplied. at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection) at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection) at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj) at System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj) at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString) at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async) at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, DbAsyncResult result) at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe) at System.Data.SqlClient.SqlCommand.ExecuteNonQuery() at Microvit_Document_Product_Document_Add_v2.insertDocumentToDB() in e:inetpubwwwrootMicrovitDocumentProduct_Document_Add_v2.aspx.vb:line 127 at Microvit_Document_Product_Document_Add_v2.btnInsert_Click(Object sender, EventArgs e) in e:inetpubwwwrootMicrovitDocumentProduct_Document_Add_v2.aspx.vb:line 37
Protected Sub insertDocumentToDB()
Dim myConnString As String = ConfigurationManager.ConnectionStrings("Master_DataConnectionString").ConnectionString
Dim myConnection As System.Data.IDbConnection = New System.Data.SqlClient.SqlConnection(myConnString)
Dim myCommand As System.Data.IDbCommand = New System.Data.SqlClient.SqlCommand
Dim myTransaction As System.Data.IDbTransaction = Nothing
myCommand.Connection = myConnection
myCommand.Parameters.Add(New SqlParameter("@FileName", SqlDbType.VarChar))
myCommand.Parameters.Add(New SqlParameter("@ProductID", SqlDbType.Int))
myCommand.Parameters.Add(New SqlParameter("@FileID", SqlDbType.Int, ParameterDirection.Output))
myCommand.Parameters("@FileName").Value = fuDocument.FileName
myCommand.Parameters("@ProductID").Value = ddlProduct.SelectedValue
Try
'****************************************************************************
' BeginTransaction() Requires Open Connection
'****************************************************************************
myConnection.Open()
myTransaction = myConnection.BeginTransaction()
'****************************************************************************
' Assign Transaction to Command
'****************************************************************************
myCommand.Transaction = myTransaction
'****************************************************************************
' Execute 1st Command
'****************************************************************************
myCommand.CommandText = "INSERT INTO [Files] ([FileName) VALUES (@FileName); SELECT @FileID = @@Identity;"
myCommand.ExecuteNonQuery()
'****************************************************************************
' Execute 2nd Command
'****************************************************************************
'myCommand.Parameters("@FileID").Value = ddlProduct.SelectedValue
myCommand.CommandText = "INSERT INTO [ProductFiles] ([ProductID], [FileID]) VALUES (@ProductID, @FileID)"
myCommand.ExecuteNonQuery()
myTransaction.Commit()
Catch
myTransaction.Rollback()
Throw
Finally
myConnection.Close()
End Try
End Sub
View 3 Replies
View Related
May 2, 2008
We would like to Share the BatchJobs functionality before going to the difficulties what we are facing in SSIS package Design and it's implementation.
BatchFile Process Steps:
1.Flat File is coming from the upstream server(DB2 main Frame Server) to the linux box in which the jobs are scheduled using crons.
2.The Flat file is validated whether having header and trailer information.The flat file name itself (eg. APPLWIC00077.dat ) will have it's sequence number ie 00077.This number will be checked against Flat file Header information Which also gives the sequence number information .If both number matches,The Loading will be initiated.Same way checking happens with Trailer.If anything goes wrong,mail will be sent and Loading will not happen.
3.The Job will process the coming flat file and Loading it into SQL Server Staging Table.
4.If loading is successful,then Some Sql server Procedure are called to validate the Staging Table Data,Filters,then move the Data from Staging table to Target table.
5.All Process or Steps are tracked,If anything goes wrong,Mail will be sent to Concerned Person.
Utilities Involved:
1. SQL Loader to Load the FlatFile Data into the SQL Server 2005 Database.
2. SQLPLUS to execute the PL/SQL procedures.
3. SENDMAIL or MAILX to send mails to externals.
Additional Information:
The SQL Loader Control File Splits the flatfile data by Position wise in order to load it into the particular column of the Staging Table.No column delimiters.Data are taken position wise (like column1 -> Sequence No , 1-3 -> column2 , 4-8 -> column2 )and checked against a condition By which the particular Staging Table is selected.
Difficulties We face in migration in regard to SSIS Package Design and it's Implementation:
1. We could Receive the flat file using FTP Task and we don't know how to open and validate the flat file data Like What we mentioned in STEP 2.
2. We could load the sample flat file which is properly delimited like {CR}{LF} ,{CR},{LF},semi -colon,comma,colon,tab,vertical bar .
If flatfile is messed up and data need to be processed by position wise (Scenario mentioned in Additional Information) ,We don't know how to implement this in SSIS package with the Limited delimiter option given.
FYI : Flat File columns are not fixed and ragged type.
3. We need logging information like howmany rows inserted, discarded,something in detail..How can we log these information using SSIS.This will help to send detailed mail to Application handler.It should be automated using SSIS.
4. How can we execute Procedures Using available SSIS tasks ( Executing many Procedures which is residing in Sql server 2005 using Single sql file as input to SSIS package)
Thanks in Advance!
Your input is priceless.
Regards,
Prabhu.M
View 4 Replies
View Related
Mar 26, 1999
Has anyone gotten clustering to work via the Cluster Wizard in SP5a?
I've got two ProLiant 5500's with the Compaq Clustering S/100 option. I've done a fresh install of NT Enterprise 4.0 SP3, then installed clustering with the Compaq S/100 drivers... everything fails over nicely, can make shares off the virtual server, etc. I then install SQL Server 6.5 EE, then apply SP5a -- so far, so good.
Now I try to run the clustering wizard. The wiz prompts me for my SA password. I enter it, and it gives me a message box that it can't start or log onto the database... but when I look in the event log it appears to have logged on successfully with a Non-trusted connection.
Thanks for the help...
View 1 Replies
View Related
Jan 7, 2007
Finding the "pieces of information" I need to successfully install the SQL Server Express edition is so complex. Uninstalls do "not" really uninstall completely, leading to failure of SQL install. Can you suggest a thorough, one-stop site for directions for the order of app uninstalls and then the order for app installs for the following...
SQL Server Express edition
Visual Studios 2005
Jet 4.0 newest upgrade
.Net Framework 2.0 (or should I use 3.0)
VS2005 Security upgrade
Anything else I need for just creating a database for my VS2005 Visual Basic project?
I was trying to use MS Access as my backend db but would like to try SQL Express
Thank you, Mark
View 7 Replies
View Related
Oct 22, 2007
In my ASP.NET app, I'm executing a stored procedure via a SQLCommand the searches a customer database. I believe the default timeout is 90 seconds. I'm curious of what happens to the SQL Server Stored Procedure after timing out from the ASP.NET application. Does it timeout at the same time or do you have to set up a value in SQL Server?
View 1 Replies
View Related
Jan 31, 2004
Hello, I am a SQL rookie. I have followed the tutorial and installed MSDN as it says. However, I am unable to create a database with WebMatrix. I keep getting an error that reads "SQL Server does not exist or access denied. ConnectionOpen (Connect())."
When I loaded the SQL, everything seemed to go well. I got all of the results that the tutorial said I should.
Please advise on my next steps. Thank you in advance.
JS
View 13 Replies
View Related
Jan 17, 2006
If you have a SQL server setup that isn’t using a SAN but just a normal raid array and you wanted to utilize a SAN now.
What are the steps, I'm guessing that you will need to start the services under a domain user correct?
Is it as easy as detaching the DB and then reattaching the DB on the SAN?
I'm assuming you need to map the data and log arrays from the server to the SAN correct?
I can’t seem to find any documentation on moving a server to a new SAN. Can someone post links if you have them?
Do you need ENT edition or is Standard OK .
Thanks for your help.
View 8 Replies
View Related
Feb 20, 2006
Hi
I'm trying to set up a new job to update a field in the table, I've managed to get the select syntax to work, but when I added an IF statement and Update syntax it didn't like it and the following error was shown:-
Server: Msg 156, Level 15, State 1, Line 9
Incorrect syntax near the keyword 'BEGIN'.
This is the syntax I'm trying to use for the job:-
USE EmployerEngagement
IF (SELECT On_Stop
FROM tblEmployer LEFT OUTER JOIN tblWP_Details
ON tblEmployer.Emp_ID = tblWP_Details.Emp_ID LEFT OUTER JOIN tblVetting
ON tblWP_Details.Record_ID = tblVetting.Record_ID
WHERE tblEmployer.On_Stop = 0
AND tblVetting.Next_Vett_Date <= GETDATE())
BEGIN
UPDATE tblEmployer
SET On_Stop = 1
END
Basically I just want to change the On_Stop value from 0 to 1 if the Next_Vett_Date is before or on todays date.
Am I using the wrong syntax for this?
Thanks
View 2 Replies
View Related
Jul 30, 2007
How do i do it? do i have to set up an ODBC?
View 20 Replies
View Related
Jul 20, 2005
Hello,I've noticed on my DTS that it is connecting to the remote SQL Servervia Named Pipes. Not sure why I've been getting the following error:[DBNETLIB][ConnectionWrite (WrapperWrite()).] but I wanted to changethe DTS from using Named Pipes to use TCP/IP. How to do it?Also, if anyone has any clues on what this error means, please let meknow!Step Error Source: Microsoft Data Transformation Services (DTS) DataPumpStep Error Description:The number of failing rows exceeds the maximumspecified. (Microsoft OLE DB Provider for SQL Server (80004005):[DBNETLIB][ConnectionWrite (WrapperWrite()).]General network error.Check your network documentation.)Step Error code: 8004206AStep Error Help File:sqldts80.hlpStep Error Help Context ID:0Tnks!
View 1 Replies
View Related
Oct 10, 2006
I am trying to connect to my database in SQL SERVER EXPRESS via dreamweaver. I am trying to create DSN connection but when i click on sql server in the optionlist it lists about 100 options of the sql server i want to connect to. How do I find out which one is the one I have my tables in and the sql server express that I use.
Cheers
View 1 Replies
View Related
Jun 20, 2006
I am unable to set the value of my SqlParameter unless it is to a string.sqlCmd.Parameters.Add('@myParameter', SqlDbType.Bit).Value := false;
Setting it to false or 0 results in error: "Incompatible types: 'Object' and 'Boolean' (or 'Integer')"
I've tried to cast them as objects and that didn't work. I don't understand why something like 'false' (as a string) will.
FYI: I'm using Delphi.NET and hating it.
View 1 Replies
View Related
Aug 27, 2006
sry im an idiotbut how do u take like "SELECTbla FROM blar WHERE blam=blfda" and make the thing it "selects" into a variable thnx
View 5 Replies
View Related
Dec 30, 2006
Hi, I have just started with ASP, and have a problem. I have created a stored procedure which looks to a specific tablename for information, based upon the users choice from a dropdown list.
The control works fine when executed from within visual web developer, and I manually enter the value that the variable expects. However I can not get the dropdown listbox value to be written to the SQL value. I have tried for days, traweled the net for answers, borrowed 3ft in height of SQL books! so either I am doing something fundamentally wrong, or I am missing something. My SP is:
ALTER Procedure GenericTableSelect
@tablename VarChar(20)
AS
Declare @SQL VarChar(1000)
SELECT @SQL = 'SELECT [base model] FROM '
SELECT @SQL = @SQL + @tablename
Exec ( @SQL)
and from the page the command to call it is:
SelectCommand=generictableselect></asp:SqlDataSource>
But this fails to compile and comes back with "@tablename not defined"
any pointers in the right direction would help.
The object of this is for two drop down boxes - the first is populated from one database of categories, the selection of which populates the second drop down list with items from within that category.
Cheers,
Richard
View 2 Replies
View Related
Jan 8, 2007
Hello all,
I've gotten approval at my work place to implement a new web server cluster. We currently have one web server running Windows 2003 and one SQL 2005 box. I've gotten approval to purchase 2 new web servers that will eventually become our primary servers.
I've browsed Microsoft's site but can't seem to find any FAQ's or How-Tos on clustering that are of any help. Is there anyone out there who has some info that could help me get started?
Thanks.
Richard M
View 4 Replies
View Related
Apr 7, 2007
I have been using MySQL as the back end of my .Net 2.0 applications for a while using a custom membership provider without any problems.Having now switched to a new webhost which supports both MySQL and MS SQL Server 2005 and also creating a new site thought I should set up the new site to use MS SQL..... I am having trouble however setting up the SQL server to act as the membership provider. Following the advice on here I tried using aspnet_regsql.exe... Firstly, when trying to get the list of databasses on the remote server I get the following error: Failed to query a list of database names from the SQL Server. Invalid object name 'Sysdatabases' If I then just type in the name of my database and go through to the end I get the following error:Exception:An error occurred during the execution of the SQL file 'InstallCommon.sql'. The SQL error number is 8152 and the SqlException message is: String or binary data would be truncated. I can connect to my MS SQL server remotely without any problem using the likes of MS SQL Server Management Studio Express. Is there any other way I can setup the databases needed for user and roles access control or is the usage of MS SQL much more complicated than what MySQL was?
View 4 Replies
View Related
Jun 11, 2007
I've received the error - Setup failed to configure the server. Refer to the server error logs and setup error logs
View 3 Replies
View Related
Jan 19, 2004
Hello
my host required to have a fix IP in order to access his SQL Server database.
I got the fix IP, but I don't know where to define the port number while creating a SQL Server connection in Enterprise Manager.
Anyone knows ?
Thanks a lot
Johann
View 1 Replies
View Related
May 23, 2005
hey guys heres my problem iam trying to install SQL server2000 but i keep on running into problems....??
here is what iam having problems with
setup SAPWD="AStrongSAPwd" SECURITYMODE=SQL
it keeps saying the instance name specified is invalid there has to be an easyer way to run the program...??
i have all ready set up an instance name and the SAPWD.
any suggestions?? please help
View 2 Replies
View Related
Feb 2, 2006
I have the following to create a new table....
CREATE TABLE dbo.test (Id varchar(20) NOT NULL PRIMARY KEY, Name varchar(256) NOT NULL, visible bit NOT NULL )
I need to set the default value of the bit visible to 1.
How can this be done using a T-SQL statement?
Thanks,
Zath
View 1 Replies
View Related
Jul 15, 2002
Hi all:
How can I change the Default value of a column in a table using sql?
for instance I have a table called Phone and I have a field called AreaCode and the default now is '123' . I would like to change it to '456'.
Thanks,
Nisha
View 1 Replies
View Related
May 2, 2000
Can someone point me in the direction of a good place to find out how to set this up properly please.
thanks
View 1 Replies
View Related
Dec 4, 1999
Hi
I am using Windows NT 4.0, SQL Server 6.5 and Exchange 5.0. I would like to setup SQL mail.
I tried to create mail login, NT expects for MS mail server name and login.
When i enter my exchange server/login name does not recoganise.
Any guide please.. Thanks in advance
Moorthy
View 2 Replies
View Related
Apr 26, 2006
I am getting the message
DESCRIPTION: Error: 1204, Severity: 19, State: 1 The SQL Server cannot obtain a LOCK resource at this time. Rerun your statement when there are fewer active users or ask the system administrator to check the SQL Server lock and memory configuration.
it is a 3rd party app I can't change with some ugly sql.
My current lock setting is
min max config run
locks 5000 2147483647 0 0
Do I need to change the min value to higher? What would be a good value to try, I have 16 gig of memory on the server
View 5 Replies
View Related
Aug 31, 1998
Hi,Patrick and VK
Thank you for your help!
the setting is follow : system account(service in control panel)
create a NT user : netbackup(privilege SA in SQL security manager)
remote server setting->
remote server login name: netbackup
mapped login name : sa
I am unclear the setting! Please tell me the detail!
best regard!
Steven/98.9.1
View 1 Replies
View Related
Jul 27, 1998
Hello, Iam new at this SQL stuff and want to setup an SQL Server at work and need to know what do i need to use this software. I have a EVAL version of 6.5 and was told you need MSACCES or Visual Basic. Is there anything else that i need to use this? Thanks!!
View 14 Replies
View Related
Jul 11, 2006
Does anyone know if it is possible to set permissions on certain fields in a way that will restrict access for reading a field but will allow a user to do a select using that field? I am looking for a way to block read access to a sensitive field but I want to be able to query other fields using the value that is in the field.
Thanks.
View 2 Replies
View Related
Jun 6, 2006
Hello, I am trying to setup a Microsoft Express SQL 2005 server to be accessed by PHP. PHP is setup just fine, the problem lies in the database (or so I believe). Quite simply, the problem is that it won't connect. I need to know if I need to have any special configuration on the database for it to connect. I am fairly positive that I have all of the login information correct, so that is not the problem.
View 3 Replies
View Related
Jul 6, 2004
Hi, I have this query basically im trying to set the @db to the current database depending on the quarter. This will be used in a package to change the database that the package will use.
DECLARE @db nVarchar(4000)
SET @db = N'TESTDB' + RIGHT(DATEPART(yy, GETDATE()), 2) + '_' + CASE WHEN DATEPART(m, GETDATE()) IN ('11', '12', '1')
THEN 'Q1' ELSE CASE WHEN DATEPART(m, GETDATE()) IN ('2', '3', '4') THEN 'Q2' ELSE CASE WHEN DATEPART(m, GETDATE()) IN ('5', '6', '7')
THEN 'Q3' ELSE CASE WHEN DATEPART(m, GETDATE()) IN ('8', '9', '10')
THEN 'Q4' END END END END
EXECUTE sp_executesql @db, N'@level tinyint', @level = 35
I get the error Incorrect Syntax near 'TESTDB04_Q3'.
View 3 Replies
View Related
Jul 16, 2004
What is the best way to set up a sql server db that will be accessed via web(asp/ado) and windows (vb/ado) environemnts. I am concerned with security and authentication.
Thanks!
View 1 Replies
View Related