|
database
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
SQL Server database programmingmicrosoft.public.sqlserver.programming
Updating Database with Windows Installer Setup
Paul Smith -
6 Aug 2005 9:28 PM - 2 messages
Hi, is there an best practice how to update an existing database with a setup program? Thanks for any hint Paul ...
clustered index on IDENTITY column
Eugene -
6 Aug 2005 6:59 PM - 19 messages
Hi, what opinion do you people have with clustered index on IDENTITY column? Is there more advantage or disadvantage? Wouldn't it causes all insertion to be added to the same page. Is this 'hot page' a big issue? Can it helps to prevent fragmentation? How is it so? ...
Conncurrent access to the same stored procedure
Eugene -
6 Aug 2005 6:50 PM - 4 messages
Hi all DB guys, I am curious of the performance of the database system on concurrent access to a single stored procedure. What I mean is, when I have a stored procedure that is access by multiple connections/clients, what is the ...
URDU LANGUAGE
Urdu -
6 Aug 2005 6:34 PM - 2 messages
How can i use the urdu language in sql server 2000? How does SQL Server 2000 enable support for a language like URDU? ...
SQL: Removing all spaces?
Ottar Holstad -
6 Aug 2005 1:58 PM - 3 messages
Hi, is there a built-in function (that I didn't notice when I looked in the helpfile) for removing all spaces, or a given character, from a string-value (most likely varchar)? It must work on MSSQL7 and newer, and if I have to ...
ORDER BY clause
simon -
6 Aug 2005 1:32 PM - 2 messages
I would like to order my select statement depends on column3 value, something like this: SELECT * from table ORDER BY column1,column2,case when column3=1 then column4,column5 else column5,column4 end Any idea? Regards,S ...
Max. No. of Columns in a Table
Moorthy -
6 Aug 2005 1:24 PM - 5 messages
How many columns can be created in a table in SQL Server 2000? Is it affect performance? ...
ROUND function
Microsoft -
6 Aug 2005 9:37 AM - 3 messages
ROUND(12.5, 0) return 12 How implement in T-SQL (SQL Server 2000) to return 13? ...
How to insert an image into a table??..is it possible to insert??
saroja -
6 Aug 2005 7:04 AM - 2 messages
I have a created a table pub_info with two fields 1.pub_id string 2.logo image ...now i want to insert images into logo column and i want to retreive that into my c#.net program...How can i do that??..please help ...
How to insert an image into a table??..is it possible to insert??
saroja -
6 Aug 2005 6:56 AM - 2 messages
I have a created a table pub_info with two fields 1.pub_id string 2.logo image ...now i want to insert images into logo column and i want to retreive that into my c#.net program...How can i do that??..please help ...
Split
Yahya -
6 Aug 2005 6:07 AM - 18 messages
Dear Sirs, Is there an sql function that would help me split a field I have with "," delimiter like "one, two, three". When I select that field I want to retrieve 3 columns separately with each result alone. ...
Nested Transaction!
Arpan -
6 Aug 2005 5:39 AM - 9 messages
The following example is given in BOL under the topic 'Nested Transaction': ---------------------------------------- CREATE PROCEDURE TransProc @PriKey INT, @CharCol CHAR(3) AS BEGIN TRANSACTION InProc INSERT INTO TestTrans VALUES (@PriKey, @CharCol) INSERT INTO TestTrans VALUES (@PriKey + 1, @CharCol) COMMIT TRANSACTION InProc ...
Transaction!
Arpan -
6 Aug 2005 1:50 AM - 4 messages
If I am not mistaken, a Transaction is similar to a batch which encompasses a group of SQL statements & queries. Suppose I want to populate a table with records & I want to do this using a stored procedure. This can be done simply by creating a stored procedure like ...
SP parameter length
Just D. -
6 Aug 2005 1:24 AM - 3 messages
All, Is there any limitation for the length of the SP Parameter like 8 Kbytes or whatever? I know that if I store Image as a binary array the limit is 2 Gigs, what about other types? Just D. ...
Foreign Key Error?
Karolus -
6 Aug 2005 1:15 AM - 5 messages
I'm a newbie to SQL Server. I've created tables and am entering the following: alter table t_AssessmentData add constraint fk_AssessmentData_WritingSampleID_WritingSample foreign key (WritingSampleID) references t_WritingSample (WritingSampleID) go The message I get is as follows: ...
Run-time Error Vs. Compile Error!
Arpan -
6 Aug 2005 12:23 AM - 5 messages
How to understand whether an error is a run-time error or a compile error? Thanks, Arpan ...
Stored Procedures
tshad -
5 Aug 2005 11:13 PM - 3 messages
Is there a good program or method for documenting your Stored procedures similar to JavaDocs? I am trying to find a good way to keep up with our Documentation and make it easier for our developers to keep track of what we have available as well as ...
Bigint vs int
tshad -
5 Aug 2005 11:01 PM - 13 messages
I had set up my tables using BigInts for my Surrogate keys (identity) to make sure I could never run out of numbers. I am thinking maybe that was overkill and my slow my system down (I know it takes up more space, but that is not really an issue). ...
Troubles pulling binary data into VBScript
maximillianx -
5 Aug 2005 9:15 PM - 14 messages
I'm a normal resident of the vbscript/wsh/server scripting forums, as I'm more of a scripter, and don't know word one about SQL...so here I am - :) I'm attempting to query a MS WSUS database stored on our SQL server (SQL ...
Parent and grand parent and great grand parent etc.
Sehboo -
5 Aug 2005 8:19 PM - 8 messages
Hi, I have a table with id, parent-id. I want to know how to write a stored procedure which returns the ids of parent, grand-parent, great-grand-parent etc. So, if the structure is like this id Parent-id ...
Transaction Log Backups
jjbutera -
5 Aug 2005 8:00 PM - 2 messages
Hello all, I'm a novice when it comes to administrating SQL Server. Basically, I want to create a manual script that sort of recreates what log shipping does. Could someone help get me started with a script that performs the following: ...
in vs. exists
Jeffrey K. Ericson -
5 Aug 2005 7:28 PM - 13 messages
What is the difference between in and exists performance wise? I have tuned(aatempted to tune) queries where a subselect was introduced with an in. I have replaced th in with an exists and found the performance and plan to ...
ALTER COLUMN
TS -
5 Aug 2005 7:15 PM - 8 messages
I have an access database that I'm splitting its back-end to be located in SQL server. One column in one of the access tables was autonumber. For maitenance purposes, some of the rows in this column have been deleted. When ...
What happens if...
Mike Labosh -
5 Aug 2005 7:09 PM - 15 messages
A coworker has some huge adhoc update that ran for like 17 hours, gooped itself up and rolled back. The rollback has been in-progress all day long and has not completed, and now they want to reboot the server. ...
Transforming string Rows to Column - How the function works?
carlos.rodrigues -
5 Aug 2005 7:07 PM - 4 messages
Hello, For example, if I have this information on the database. ID Sequence Description 1 1 aaaa 1 2 bbbb ...
Text vs VarChar(8000)
tshad -
5 Aug 2005 6:42 PM - 7 messages
Other than unlimited characters for Text, is there a drawback to using one over the other? I have all my text boxes in asp.net page (that are multilines) set to varChar(8000). Most of the time, I don't care expect more than a few ...
Connection to Paradox
Yunus's Group -
5 Aug 2005 6:21 PM - 3 messages
Hello, I am trying to connect to paradox database for the purpose of updating the record(s) in DTS ActiveX Script Task. I used the following connection string. But I get an error while connection. I have "UMTest.db" and "UMTest.px" files in the ...
ADODB Streams
Brian -
5 Aug 2005 6:05 PM - 6 messages
Does anyone have an example of how to use an ADODB Stream object in a Stored Procedure to retrieve an image column. ...
convert
TS -
5 Aug 2005 5:53 PM - 7 messages
Hi, I need to change the format of a date column in one of the tables to reflect a date that looks like mm/dd/yyyy. I used the following syntax that I know it's wrong -it works in a select statement-: ...
Arbitrary assignment in join
Jami Bradley -
5 Aug 2005 5:41 PM - 5 messages
Hi folks - I'm hoping that this is an issue that has a reasonably easy answer :-) I am migrating data that has some grouping, but I there is not a unque join to get a 1-1 match for my data. What I need to to simply pick any *one* row and put it in any *one* row in my destination ...
Problem with totaling
Kenneth -
5 Aug 2005 5:06 PM - 2 messages
I have a [transaction] table which stores [account no], [date], [amount] with lots of transactions (say, 300,000 records). Old transactions will be modified and new transactions will be added from time to time. Assume my program needs the amount sub-totals of different [account no] and ...
update rows with set-based GUID values?
jason -
5 Aug 2005 5:01 PM - 3 messages
given a hypothetical table: create table sample ( oldid int identity not null, name varchar(50) not null, constraint pk1 primary key nonclustered (oldid), constraint ak1 unique nonclustered ) i want to add a guid column like so: ...
OPENXML
JMNUSS -
5 Aug 2005 4:47 PM - 3 messages
I have written an OPENXML proc (this is my first one, so be gentle).... alter PROCEDURE sp_Insert_billing_Openxml @strXML ntext AS DECLARE @iDoc int EXECUTE sp_xml_preparedocument @iDoc OUTPUT, @strXML INSERT INTO billing ( ...
Continue INSERT after key violation?
len -
5 Aug 2005 4:39 PM - 3 messages
Hi there. I have a simple table with a UNIQUE constraint on one field. I wish to populate this table using a stored procedure that returns the equivalent results set like so: INSERT INTO MyTable EXECUTE p_GetMyResultsSet My stored proc returns unique, distinct results each time it's called ...
Porfermance between temporary table and cursor
wdwedw -
5 Aug 2005 4:12 PM - 21 messages
What's the porfermance different between temporary table and cursor? ...
Combining two seperate tables into one
Marcin Zmyslowski -
5 Aug 2005 4:05 PM - 5 messages
Hello! I don`t know how to do some query. I have two tables which looks like it: First table: MRPC 200504 200505 200506 C01 1 2 3 ...
Data type of temporary table
wdwedw -
5 Aug 2005 4:01 PM - 5 messages
I create a temporary table like this: select legalname into #tempname from company How do I know what's the data type of legalname in #tempname? ...
NESTED TRANSACTIONS!
Arpan -
5 Aug 2005 3:42 PM - 3 messages
In case of nested transactions, will the @@TRANCOUNT value be always 0 if the entire transaction is rolled back at the very end? Thanks, Arpan ...
soundex + phonetic encoder
tw -
5 Aug 2005 3:37 PM - 3 messages
Hi, In SQL Server is the languague for soundex english. Is that possible to change the languague, for example swedish? Help. Thnx TW ...
More Than 1 ROLLBACK Statement!
Arpan -
5 Aug 2005 3:36 PM - 4 messages
Consider the following code snippet: -------------------------------------------- BEGIN TRANSACTION OuterTran /* Do Something..... */ BEGIN TRANSACTION InnerTran /* Do Something More..... */ ROLLBACK TRANSACTION InnerTran /* Do something More.....*/ ROLLBACK TRANSACTION OuterTran /* Do something More.....*/ -------------------------------------------- The above, when executed in QA, generates an error saying "Cannot roll ...
Using 'GO' In Transaction!
Arpan -
5 Aug 2005 3:34 PM - 4 messages
BOL, under the title '@@TRANCOUNT (T-SQL)', says that -------------------------------------------- The BEGIN TRANSACTION statement increments @@TRANCOUNT by 1. -------------------------------------------- The following Transaction first creates a table with 3 columns wherein I want the 3rd column to store the @@TRANCOUNT value corresponding to ...
Should I COUNT or use TOP?
C-W -
5 Aug 2005 3:18 PM - 4 messages
I need to determine whether a row exists zero, one or more than one time in a table. At the moment I am doing... SELECT @PostCodeCount = COUNT(PostCode) FROM [dbo].[Clients] WHERE PostCode = @PostCode AND ClientSerialNo <> @ClientSerialNo ...
ISNULL Function doesn't work
Ross Culver -
5 Aug 2005 2:21 PM - 11 messages
I have a most peculiar problem. On one of my customer's SQL servers, the ISNULL function doesn't work. No matter what datatype, the ISNULL returns a blank value instead of the designated value. (ex. ISNULL(field1, 10.00) ...
sometimes you gotta laugh
Payson -
5 Aug 2005 2:12 PM - 6 messages
I was making some mods this morning and ran across the following fragment - the names have been changed to protect my job :) It's typical code. For some reason, it struck me funny. if exists( SELECT top 1 * FROM xxx where col1 = 1 ) ...
Return test result as column value
danny.dion -
5 Aug 2005 2:12 PM - 3 messages
Hi all. I'm writing a stored procedure that has to include a special flag for each row. I need to do something like this : SELECT t_client.client_id, t_activity.activity_id, t_activity.activity_dttm, ...
Insert, updates not woring until SQL server restart.
sam -
5 Aug 2005 2:02 PM - 3 messages
Hi all, I hope this is the right place to post my question/problem. I have this problem with SQL server. All of a sudden the insert, updates does not work on SQL server based application written in ASP. The select commands ...
Extended Stored Procedure
ReTF -
5 Aug 2005 1:59 PM - 3 messages
Hi All, What is Extended Stored Procedure? Thanks ...
large updatestatement
Jason -
5 Aug 2005 1:37 PM - 6 messages
Hi, Is there a way to update a table without specifying the columns to be updated? I have a backup of the table which i join on a id. All columns are the same, but there are more than 100. So if i can create a statement like ...
Multi-column query (pairwise query)
j -
5 Aug 2005 1:31 PM - 4 messages
Hello, My SQL knowledge originates from the world of Oracle, so bare with me. In Oracle you are able to query a table and filter results based on 2 columns in the WHERE clause (called pairwise query). Ex: SELECT col1, col2, col3, col4 FROM tablename1 WHERE (col1, col2) in (select ...
Find second character in a string
Christian Perthen -
5 Aug 2005 1:19 PM - 9 messages
Hi, I have a string such as .75.34.100. How do I find the position of the second comma from the right. I been trying to use PATINDEX DECLARE @string varchar(30) SET @string = '.75.34.100.' SELECT PATINDEX('%.', LEFT(@string, LEN(@string)-1)) ...
Conversion of procedure making crosstab to function
Rafal Ba -
5 Aug 2005 12:46 PM - 3 messages
Hello Everybody, I have the following problem. I found procedure alolowing me to create dynamic crosstab and it works fine, but I cannot save the results as a table. Is there any way to do this? Maybe someone is in possesion of ...
Internal SQL Server Error on a query that used to work
J. M. De Moor -
5 Aug 2005 12:03 PM - 4 messages
In porting an application from MSSQL 7.0 to MSSQL 2000 SP4, the following no longer works. CREATE TABLE Patients ( patient_id INT NOT NULL PRIMARY KEY ,activity CHAR(1) NOT NULL CHECK (activity IN ('M', 'N', 'P', 'I', 'A')) ...
Display stored procedure results in a view
Craig HB -
5 Aug 2005 11:16 AM - 4 messages
If a stored procedure returns a table, is it possible to return that as a view. Something like this (although I know that this SQL doesn't work)... CREATE VIEW vw_Equipment AS EXEC proc_Equipment_List Thanks, Craig ...
services up or down
Enric -
5 Aug 2005 11:12 AM - 3 messages
Dear fellows, I would like to know if using T-SQL or VB code is posible figure out when a specific service from a Sql Server is up or down (either of them). Is it affordable? For example, I've got a front-end app in vb which retrieves information of ...
Merging duplicate data into one row
Chris Asaipillai -
5 Aug 2005 10:53 AM - 2 messages
I have a set of customer data which is duplicated. The reason is that each customer has differrent [Failure Code]s applying to them. So i want to merge the data, the only tricky thing is that i would like to ...
Debug Stored Procedure
jsfromynr -
5 Aug 2005 10:32 AM - 3 messages
Hi All, I wish to debug the stored procedure in SQL Server, but I am not able to do so. Is there any sort of Configuration required on the Server Side? When I try to debug the procedure it shows a warning that ...
How to call a Store proc inside a view
Cynthia -
5 Aug 2005 10:31 AM - 10 messages
Can anyone tell me how to call a sp inside a view. ...
Doubt on unique non clustered Index
Pradeep Kutty -
5 Aug 2005 10:26 AM - 4 messages
Hi All, I have a table with data: CREATE TABLE [dbo].[Relation] ( [ID] [uniqueid] IDENTITY (1, 1) NOT NULL , [PersonID] [uniqueid] NOT NULL , [CurrentID] [uniqueid] NOT NULL , [RelativeName] [varchar] (50) NOT NULL , ) Here there are duplicate records for a combination of PersonID, CurrentID ...
SQL equivalent of MySQL SET Type
Andy Hayes -
5 Aug 2005 9:58 AM - 4 messages
Hi I am trying to convert a table structure from MySQL into MS SQL Server. One of the datatypes I need to find an equivalent for is SET. Does anyone know what the equivalent is in MS SQL if it exists ? ...
reverse only the text parts of the field
Sam -
5 Aug 2005 9:56 AM - 9 messages
i have to import addresses from an text file. the text is reversed but numbers are not reversed "abcd 12 def" comes as "dcba 12 fed" if i use the reverse function it reveses also the number and the it becomes "abcd 21 def" ...
help with this
Chris -
5 Aug 2005 9:51 AM - 4 messages
Hi, I have a mail queue system in sql server that dispatches mail based on data in the queue table but now I want to group the mails so that instead of sending individual mails every 5 mins it will wait until the end of the day ...
HowTo DECLARE CURSOR with parameters
Ottoman -
5 Aug 2005 9:40 AM - 6 messages
Hi All, i would like to nest 2 cursors and I would like to include in the declaration of the inner cursor a value which was fetched by the outer cursor. (i.e. a thing similar to correlated queries) So my question is: ...
Left Outer Join Problem not returning required result
Ghulam Farid -
5 Aug 2005 8:12 AM - 2 messages
Hi all i have two tables Daily_Report_Station and Main_yesno, in first table we r collecting daily reports and other table is for reporting day. in daily_report Station_tables i have list of centers which send us daily report. i m using the following query for the data to return on a ...
Notify events?
tshad -
5 Aug 2005 5:27 AM - 4 messages
Is there anyway with Sql Server 2000 to notify me of a record being written to a table? For example, I would like to know when a record is written to a table to let me know that some status has changed and that I would need to do something ...
SQL statement question
Ricky L via SQLMonster.com -
5 Aug 2005 5:15 AM - 9 messages
Hi All, I have a questoin of writing SQL statement. Sample data A/C Code, Stock Code, Qty On hand, Unit Price AC00001 S00001 5 100.00 ...
Stored Procedures Disappear
Carl Tribble -
5 Aug 2005 4:21 AM - 3 messages
I have a SQL Server 2000 database I built and am using .NET windows client and the .NET SQLClient object to access it. I have done a fair amount of work with it successfully including exeucting many stored procedures without ...
Text datatype in SQL Server 2000
Rach513 -
5 Aug 2005 2:05 AM - 6 messages
I have a text column in my table. Based on what I heard from my DBA, it should take any length of text data. But this is not the case. I am inputting some large amount of text into the database. But when I try to see what is ...
SET IDENTITY_INSERT LOCKS TABLE
jp -
5 Aug 2005 12:59 AM - 5 messages
Hi. I have the following procedure: .... BEGIN TRANSACTION SET IDENTITY_INSERT REGISTROS_TMP ON INSERT INTO REGISTROS_TMP (..., ..., ID, ....) values (..., ..., @Id, ...) SET IDENTITY_INSERT REGISTROS_TMP OFF COMMIT TRANSACTION This locks this table, and a couple more, I think. I tried with SET TRANSACTION ISOLATION LEVEL SERIALIZABLE and it seems ...
How to write BLOBs
ruvini -
5 Aug 2005 12:39 AM - 3 messages
I am doing a resurch on ODBMS and need to show that ODBMSs are better than RDBMs. To show that Object data bases(ORACLE9i) can store large objects(eg:Images) easily compared to Relational data bases(SQL server) i need to write a BLOB to store a image in a SQL database. ...
Parsing a comma-delimited text column
Mike Austin -
4 Aug 2005 9:51 PM - 10 messages
I have a legacy database that was originally in mySQL. It contains many columns that contain comma-delimited lists of foreign keys. So the column may contain "802,1404,25,124" etc. All the numbers in the list point to lookup ...
Help doing a SUM for Fiscal Year data
Jason -
4 Aug 2005 9:41 PM - 5 messages
I have a problem that at first sounded easy (perhaps it still is), but as I get into it I'm getting more and more confused. Here is the problem. I have a table holding transctions (we'll call the table Trx for ease of use), ...
Counting Orders in Sub-Select Query?
Dan -
4 Aug 2005 9:32 PM - 2 messages
Hi, I am summarizing data like this SELECT dbo_Order_Line_Invoice.Cono, dbo_Order_Line_Invoice.CustId, Year([Invoicedate]) & '/' & Format(Month([Invoicedate]),'00') AS [Year-Month], dbo_Order_Line_Invoice.VendId, Sum(dbo_Order_Line_Invoice.Sales) AS Sales_Total, Sum([Sales]-[Cost]) AS GM_Total, Count(dbo_Order_Line_Invoice.LineNum) AS Line_Count ...
Erreur_:_Les_donn=E9es_cha=EEne_ou_binaires_seront_tronqu=E9es._L'instruction_a_=E9t=E9_arr=EAt=E9e.
fchiausa -
4 Aug 2005 9:09 PM - 3 messages
Bonjour, j'obtiens une erreur lors de l'insertion d'un enregistrement dans une de mes tables. je ne comprend pas porquoi j'ai cette erreur ni meme ce qu'elle veut dire. l'erreur est la suivante : "Les données chaîne ou binaires seront tronquées. L'instruction a ...
Update Question!.............
tom d -
4 Aug 2005 9:09 PM - 7 messages
Hi, I have a table like this: Name Count(int) Tony NULL ...
Syntax error or just too complex
BBM -
4 Aug 2005 8:40 PM - 6 messages
Hi everyone, I'm trying to do a nested join query and not having any luck. The Query Analyzer gives me a "Syntax Error near 'Left'" on this query... Select PeriodId, Quantity, Balance, ResType, Label FROM ((SELECT DayDate, PeriodId, Label, ResourceType FROM ATSWeeks CROSS JOIN ...
Code to verify date as Valid
Earnie -
4 Aug 2005 8:38 PM - 4 messages
Is there code to establish if a date is valid so that I can send an error message if i get the 31st of February for instance im thinking of something like the following but don't know the code ...
Stumper of a Syntax Error
David Snyder -
4 Aug 2005 8:21 PM - 3 messages
I'm trying to write a script to alter a view, and I'm having difficulty getting Query Analyzer to successfully parse the script. Here's the script... IF Exists ( SELECT * FROM dbo.sysobjects ...
Alter Table
Plantador R via SQLMonster.com -
4 Aug 2005 7:59 PM - 4 messages
Hi, i think that my question is stupid, but i will ask anyway .. I want to allow a user to create stored procedure, alter stored procedure, and drop procedure, but the same user cant alter any table, can i do that ??? ...
DADIFF expressed as float
Mark Hoffy -
4 Aug 2005 7:55 PM - 4 messages
Hello, I am trying to calculate an age in terms of years and express the result as a float, such as 3.75 years or 5.33333 years etc. I have tried things like... CONVERT(float, DATEDIFF(d, MyStartDate, getdate()) ) /365 as YearsOld ...
DateDiff years as a float
Mark Hoffy -
4 Aug 2005 7:52 PM - 2 messages
Hello, I would like to calculate the diferrence between two dates and express the result as a float of the number of years - such as 3.75 or 5.33333. I am trying... CONVERT(float, DATEDIFF(d, MyStartDate, getdate() ) ) /365 as YearsOld ...
Database maintenance and Database Administration?
angela.solorzano -
4 Aug 2005 7:07 PM - 3 messages
I need some help.... Can someone please, in point blank form tell me the difference between Database maintenance and Database Administration? This might seem obvious, however apparently I am not certain. thx ...
UPDATE SQL
MS User -
4 Aug 2005 6:30 PM - 4 messages
Table A with columns (id, Adate, AType, No) Table B with columns (id, BDate,BType,No) Sample Data Table A 100, NULL, NULL, 1 Table B 100, 01/01/2005, AA, 1 ...
Write conflict in subforms
TLD -
4 Aug 2005 6:07 PM - 3 messages
Using Access 2000 as an .adp front end, a form reads records from a very wide table. A subform allows views of different sets of fields from the same record. There are three sets, each of which resides on a different subform ...
transaction log question
pmcguire -
4 Aug 2005 5:46 PM - 5 messages
I have a fairly small database that is only being used by 2 people (it will be used by many more in the future). I am replicating this database to another database that is currently being used by only a few people. My ...
Report of every user for every database on server
Joshua Campbell -
4 Aug 2005 5:17 PM - 7 messages
For auditing purposes, I create a list of all the users who have access to my databases. I do this by issuing this: exec sp_MSForEachDB sp_helpuser However, this doesn't include the name of the database that the list of ...
how i can skip error messeges within Procedures
Sam -
4 Aug 2005 5:05 PM - 4 messages
how i can skip error messeges within Procedures such as can't insert to duplicate keys thanks sam ...
"Completing" a time phased table
BBM -
4 Aug 2005 4:53 PM - 6 messages
Hi everyone, I Need to display summarized, time phased (lets say weekly), data in a datagrid. Pretty straightforward except that my summarized data may or may not be "complete". That is if I do a simple summarization query on my base ...
Security: Accessing data in another db
Craig HB -
4 Aug 2005 4:18 PM - 6 messages
For all our ASP.Net applications we use a user called 'AppUser' to connect to the database, which only has execute permissions on the stored procedures. This makes sure that client apps only connect to the server via stored procedures. ...
Tracking Row Changes
Chuck P -
4 Aug 2005 4:01 PM - 10 messages
I would like to track who made a change and when a change was made to a row. In Oracle we did this a with a "Before Insert or Update", "Row Level" trigger that would grab the connected users Name and System date and then put ...
assistance with rounding
Chris -
4 Aug 2005 3:50 PM - 8 messages
Hi, I have the foll round((convert(decimal(4,0),d.new - d.old)/d.old)*100,0) The result I get is -54.00000000000 How can I change it to only display -54 Thanks ...
Nightly Data Structure Refresh
Steve R -
4 Aug 2005 3:21 PM - 11 messages
We are receiving a reporting database from a vendor nightly. We want to upload this data and structures to SQL Server nightly. We want it to be as flexible as possible - if the vendor adds/deletes a table/column, the import ...
Enforce unique on non-NULL values with Trigger?
Dave -
4 Aug 2005 3:15 PM - 4 messages
According to the docs, SQL treats NULL as a value so you can't put a unique index on a column that allows nulls for such things as optional values. For an example, an employee table, the cell phone column is optional and can ...
Problem with deadocks
Tinchos -
4 Aug 2005 2:49 PM - 4 messages
Hi list, iam very new to SQL. i have a developer that is making a very complex query over a SQL2000 + SP3 database, with a lots of union queries. He recieves this error: Transaction (Process ID 97) was deadlocked on lock | communication buffer ...
Hierarchy - Finding loops in the data
carmaboy -
4 Aug 2005 2:49 PM - 10 messages
I've spent hours trying to find the answer to this with no luck. One of our systems tracks connections between objects. If a user enters an object that is connected to to another object that is connect to its ...
Dynamic crosstab query in MS SQL Server 2000
Marcin Zmyslowski -
4 Aug 2005 2:46 PM - 3 messages
Hello all! I have a problem with creating crosstab query in MS SQL Server 2000. I spent 8 hours on searching internet to achieve my succes but without result. I would like to transform such data: MRPController WK Value ...
SQL rollup/update question
Johnny -
4 Aug 2005 2:35 PM - 3 messages
Hello. I have data in a table, like so: Sample data: claim claimline denied 1000 1 500 ...
skip error messeges within the pass-through query
Sam -
4 Aug 2005 2:16 PM - 2 messages
in MS Access i use vba code to run pass-through queries to run sql server Procedures now errors like can't insert to duplicate keys stop's the code with error how i can skip the error messeges within the pass-through query ...
i know this is a dead horse (natural vs. artificial keys)
jason -
4 Aug 2005 2:14 PM - 23 messages
if you're sick of this topic, feel free to skip this post. i've read about half a dozen threads focused specifically on this topic, but every comment gave me questions. and the threads were all too old to comment on, so i want to make sure my young opinion is an ...
2005 - Common Table Expressions Question
Amos J. Soma -
4 Aug 2005 1:51 PM - 4 messages
I am excited about this new feature in SQL Server 2005. However, it seems to me there is a rather severe limitation to CTE's. That is the fact that any queries that call the CTE must call them right after the CTE definition. For ...
Using Count Dynamically
TroyS -
4 Aug 2005 1:49 PM - 7 messages
I'm trying to get a sum of employee certification by certification name without having to hard-code the certification name into the query. The list of certifications may change as new ones are added via an application .......... In the examples i've found, typically the query hard codes the name_value of ...
|
|||||||||||||||||||||||