|
Auto increment could be done in sql server 2000 by using identity.
You wanted in ASP.Net, could you explain in brief what exactly you are looking for?
Gautham
|
|
|
|
|
I need to connect the MySql database. Can anyone tell me what's the namespace to use for the connection and how do to connect .
Regards,
LEE
|
|
|
|
|
Create ODBC connection and create DSN for ur MySql DB.
rahul
|
|
|
|
|
Ok..! the namespace for the MySQL is Odbc: what object is used for connection
Regards,
LEE
|
|
|
|
|
Dear all,
i am using sql 2005 , asp.net and C#.
i have made reference to two table that is master and transaction.
sp that no data in transaction will be saved if its not exist in master. Now when i goes to delete the record which is there in transaction. i get refercial table error message. i would like to know how can i make sure that if data exist in transaction table. instead of sql error i pop up some error.
please guide me.
thank you
regards
imran khan
|
|
|
|
|
How can i view the size of a record in sql server express 2005? What is the query?
X
|
|
|
|
|
You can work out the average size of a record by running:
exec sp_spaceused 'MyTableName'
That gives you the number of rows, and the amount of space taken-up by the data and indexes.
|
|
|
|
|
Hai everybody,
I am new to triggers in SQL Server.
Can you please tell me can i combine the insert and update events in the SQL trigger as we do it in Oracle.
If yes, then how can i check it whether it is an inserting or updating event. (In oracle we will use INSERTING or UPDATING or DELETING.)
I am going to update a column with 1 (as it is a bit field) and then i have to perform some steps based on the value and later on again i want to reset the value to 0 in a trigger.
Can i perform this? If yes or no , how can i do it?
-- modified at 1:47 Monday 25th June, 2007
Best Regards,
M. J. Jaya Chitra
|
|
|
|
|
|
I have gone through the reference what you gave. but there is no hint for combining the insert and update events in a single trigger?
I want to combine them because i am going to perform the same operations partially.
Best Regards,
M. J. Jaya Chitra
|
|
|
|
|
CREATE TRIGGER TRIGGER_NAME
ON TABLE-NAME
FOR INSERT, UPDATE
.....
.....
.....
you can achieve your functionality by writing your logic in this trigger!
Gautham
|
|
|
|
|
Hi ,
I installed the SQL Server 2005 with all the components.actually i want to bractice the SQL Server Business Intelligence Development Studio as i study.....the thing is SQLServer BI is different, meening that new -> project template is diffent..It is same as MS Visual Studio 2005.(I have already installed that also.)
i want BI as it is in initial...
something wrong that i doing?? Is it same? i want that as it is...any setting to build..
Thanks in advance!
|
|
|
|
|
While raising an error using the RAISERROR statement is there any specific state and level no to be given, will it affect any thing. If so what nos i can specify?
Best Regards,
M. J. Jaya Chitra
|
|
|
|
|
|
RAISERROR ( { msg_id | msg_str } { , severity , state }
Error numbers for user-defined error messages should be greater than 50,000
severity the user-defined severity level associated with this message
State an arbitrary integer from 1 through 127 that represents information about the invocation state of the error. A negative value for state defaults to 1.
If U Get Errors U Will Learn
If U Don't Get Errors U Have Learnt
|
|
|
|
|
Thank you all.
Best Regards,
M. J. Jaya Chitra
|
|
|
|
|
Glad to help Always.
Regards,
Satips.
|
|
|
|
|
Hi
i have 2 questions in SQL 2005
First:
How to upload a picture in the database as i want each user to put his pic
second:
How to make the search CaseSentive
so it can diffrentiate bet
bahaa & BaHaa
Thanks a lot
|
|
|
|
|
I am currently working Asp.net with c#, inserting data from webform into sqlserver 2000 datatable.
table id column contain identity increment.It will increment id for every new recored.
I inserting 10 recoreds id 1 to 10 into table then deleted last two records (9&10) then inserting a new record
these record id having 11 insted of 9 in id column.
Plz help me .......
Thanks in adv
|
|
|
|
|
This is normal. The absolute simplest thing to do is to code your application so it does not expect or require contiguous identifiers.
The database records the next identifier for a table with an IDENTITY column in the table's metadata. It uses and increments that value when inserting a new row. You can only reset the value by truncating the table, removing all existing rows, or using the DBCC CHECKIDENT command. You have to set a special option to insert a value into the identity column.
If you really can't stand to have gaps, you'll need to manage the identifiers yourself.
|
|
|
|
|
Hello to every One,
i'm using database in my web form for login and user purpose.. due to some reasons i have to format my pc.
after that when i again re-install sql server 2000 and visual studio7 i'm unable to connecto to the database in the following line:
Protected sqlconnection1 As SqlConnection = New SqlConnection("data source=.;initial catalog=daccrop;persist security info=False;user id=dac1605;pwd=dac1605;workstation id=self;packet size=4096")
Actually i have changed the server and computer name in my new installation i.e from "DAC_147_347" to "garg" and again i don't remember how the authentication was done i.e windows or by sql server login. Following is the modified coding for connecting to database..
Protected sqlconnection1 As SqlConnection = New SqlConnection("data source=GARG;initial catalog=dac1605;integrated security=SSPI;persist security info=False;workstation id=GARG;packet size=4096")
This is still not working..
suggest me how should i know the setting done in sql server and after knowing how should i implement it.
The Error shown to me is:
"SQL server does not exist or access is denied"
Thank You..
|
|
|
|
|
Use Enterprise manager to view the Server properties and see how security is set up. If it is set up for windows authentication, then change your connection to use that. If Sql server or mixed, then use EM to view the logins, and find the login you wish to use. Reset the password, then update your connection string.
|
|
|
|
|
Hi Guys,
The database is remotely located in other place and I have no more time to go back there. How can I backup the database remotely to my local machine?
I am using MsSQL2005 for my remote web development, and I just wanted to have a copy of the database into my local machine.
I hope you can help me with this.
hifiger2004
|
|
|
|
|
If you can, back the database up to a shared drive (or ftp directory that you have access to) on the remote, then copy (ftp) the backup file to your machine.
|
|
|
|
|
Hi Rob,
That's what I am thinking before. But if there are some other ways to do it aside from ftp then i will go for it.
Anyway, since there's a lot of time wasted for finding some other ways, I rather go for ftp.
Thanks for your support Rob.
hifiger2004
|
|
|
|