|
database
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
SQL Server database programmingmicrosoft.public.sqlserver.programming
EXECUTE AS in SQL 2005 - does it always work?
Dweller -
1 Oct 2005 11:23 PM - 3 messages
Hi, Looks like "EXECUTE AS" is not always works as expected after reading help. Lets try next steps for demonstration: 1. Create SQL login ( lets say "MASTER" ) with "processadmin" Server Role and use it to connect to any database (with 'dbo'). ...
SQL code passed with a parameter
Howard -
1 Oct 2005 9:46 PM - 2 messages
Hi everybody My application calls a stored procedure that runs a select statement. The procedure accepts an input parameter (varchar) named @OrderBy. User chooses a sort order from a combo-box and the application supplies the order by clause to the stored procedure with the @OrderBy parameter. ...
Windows Server 2003
Sandy -
1 Oct 2005 4:56 PM - 2 messages
Hello - I know this isn't the proper forum for these questions, but I couldn't find the appropriate group. (Can anyone point me to the Server 2003 group?) I purchased Windows Server 2003. I had been using a trial version on one of ...
Giive me examples
Bpk. Adi Wira Kusuma -
1 Oct 2005 4:11 PM - 3 messages
I use Ms. Access 2000. Can you give me examples, how to export 123 to Access use DTS? I ...
design help
rodchar -
1 Oct 2005 3:29 PM - 3 messages
hey all, you know in an invoice sometimes you have past due amounts and credited amounts. are these items normally stored or are they calculated on the fly? thanks, rodchar ...
Column size
Michel -
1 Oct 2005 2:57 PM - 5 messages
Hello World, If Len (Expression) return the length of Expression What will return the size of column ? Thank's in advance. ML ...
Adding Column to table
Stephen K. Miyasato -
1 Oct 2005 1:24 PM - 2 messages
I'm writing a procedure to add column to the database but need to check if the column already exist. How does one check to see if it exist. The reason is that if I have multiple statements adding columns then it seem that the procedure will error out ...
Beta testers wanted
activefrog.com -
1 Oct 2005 11:06 AM - 1 message
Hi all, we are still looking for enthousiastic testers that are willing to check out our new Fast SQL Editor. This editor has some cool and powerfull features like: - intellisense - favorites - code snippits - real time database object info - drag and drop ...
Get value of parameters passed in stored procedure in a trigger
manK -
1 Oct 2005 11:00 AM - 2 messages
In updating my tables (insert/update), i use stored procedures. Some of the values passed as parameters to the stored procedures are only necessary for audit trail only and not for updating the tables. How can i get hold of these parameter values while inside a trigger? ...
Large TempDB
rikesh patel -
1 Oct 2005 10:37 AM - 2 messages
Hi I have many reports running from a SQL Server DB, from Crystal Enterprise reporting system. However I have noticed some performance degradation, and I noticed that my TempDB had ballooned in size. Is there a way to reset ...
dtproperties system table changed to user table in sysobjects?
Paul B -
1 Oct 2005 9:04 AM - 5 messages
Hi Gurus, I occasionally use some T-SQL to add a column or trigger to all usertables tables within a database. It has always worked before but on one database I am having a problem because the "dtproperties" system table appears to have been changed to a user table in the "sysobjects" table and is being returned in along with all the usertables by: ...
OpenRowset - Excel copies only 255 characters
Madhivanan -
1 Oct 2005 6:35 AM - 1 message
When I use OpenRowset method to export data to Excel file, only 255 characters of columns are copied. How do I make it to copy all characters? insert into OPENROWSET('Microsoft.Jet.OLEDB.4.0', 'Excel 8.0;Database=D:\test.xls;', ...
Totally OT: 'Celko' Pronounciation
Frankie -
1 Oct 2005 6:13 AM - 4 messages
How is the name Celko correctly pronounced? Is the 'Cel' part of 'Celko' pronounced like "sell" as in "Let's sell it"??? or is it pronounced like the musical instrument - cello?? "CHELLO"? -Just curious. ...
Question
Bpk. Adi Wira Kusuma -
1 Oct 2005 5:12 AM - 3 messages
Sorry, If I'am wrong in posting my question at here. I ask, If I export data to text, so I can write like this: INSERT INTO T1 IN 'C:\'[Text;] FROM T2 Now, How to export data (LOTUS 123) with Sql in Ms. Access? ...
Database/Application Documentation
Chad -
1 Oct 2005 3:47 AM - 3 messages
Just general thoughts... It seems to me that there is a lack of compile time binding between a .NET application and the a SQL server database. Can someone suggest the best way to do things like -identify stored procedures that are no longer being used by an application ...
Need advice on ETL architecture...
sqlster -
1 Oct 2005 12:06 AM - 3 messages
I am about to design (I think it could be considered as) ETL system and here are my thoughts on how it should work at a very high level. My intention in this post is to find out if there is a better way to design ...
Cursor question
ninel -
1 Oct 2005 12:05 AM - 4 messages
I have a table that contains employees punchin and punchout times.
An employee can punchin and out multiple times during
day(Lunch/Breaks). Sometimes they forget to punch out, but punch in
again. So I can have records that look like this:
EmpId Project PunchIn PunchOut
1 A 09:00:00 10:30:00
1 B 10:32:00 NULL
1 C 11:35:00 13:00:00
2 B 11:04:00 12:00:00
2 A 12:30:00 NULL
3 A 09:30:00 12:30:00
I need to loop through these records, figure out if the PunchOut is
NULL and if it is, update the PunchOut with the next records PunchIn
time. So EmpId 1 who worked on project B should have a PunchOut time
of 11:35:00.
I can't figure out how to get the next records Punchin time to update
the NULL value.
Can anyone please help me?
Thanks,
Ninel ...
Need help with how to get a count of unique values in a table
kevin -
30 Sep 2005 10:13 PM - 5 messages
Topics sounds confusing, right? Welcome to my world! Here's an example. I have a database of phone numbers, such as this: table: members field: phone_number values: 123-456-xxxx 123-234-xxxx 324-667-xxxx 555-767-xxxx 555-876-xxxx ...
Subqueries in Case statement
Terri -
30 Sep 2005 9:59 PM - 5 messages
Can I use a subquery in a case statement. Current code. CASE SECURITY.SEC_TYP_CD WHEN 'MUNI' THEN do action A here WHEN 'CB' THEN do action A here WHEN 'CONB' THEN do action A here ELSE do action B here ...
delete records
Dion -
30 Sep 2005 9:45 PM - 5 messages
I am having trouble trying to figure out how to delete some records. I have the following query: select * from p join ppt on p.PatNo=ppt.PatNo where p.DayTime>=ppt.Discharge this returns 1,000 records. These are the records I want to delete from p. ...
Surrogate Keys
Frankie -
30 Sep 2005 9:33 PM - 16 messages
What is an accurate definition of a "surrogate key" and what would be a straight-forward example of when it would be a good idea (if ever) to use one? I ask because I think "surrogate key" is sometimes misused and/or is not the ...
Cursor question
ninel g via SQLMonster.com -
30 Sep 2005 9:21 PM - 2 messages
I have a table that contains employees punchin and punchout times. An employee can punchin and out multiple times during day(Lunch/Breaks). Sometimes they forget to punch out, but punch in again. So I can have records that look like this: ...
Help! Need assistance!
nashak -
30 Sep 2005 9:15 PM - 8 messages
I have a table with following columns: Tutorial Number Lesson Number Order Number where each tutorial has many lessons and there is a order number for each lesson within that tutorial. In the UI, once the user re-sorts the lessons in any manner which they ...
Dynamic Execute in Function?
xenophon -
30 Sep 2005 8:54 PM - 4 messages
Is it possible to dynamically execute SQL in a Function? Set @selectit = ' Select Startdate from [dbo].[' + @tablename + '] Where testcol=113' Exec (@selectit ) Is what I want to do but Query Analyzer won't let me do it. ...
Is this a bug, CURSOR_STATUS() always return -3 ?
S.M -
30 Sep 2005 8:35 PM - 2 messages
Hi, With this simple test, CURSOR_STATUS() function always return -3 use Northwind go if object_id('dbo.TestCursor') is not null drop proc dbo.TestCursor go create proc dbo.TestCursor as declare @ContactName varchar(50) declare My_Curs cursor fast_forward for ...
SQL Server and case sensitive instance
Alain -
30 Sep 2005 7:07 PM - 3 messages
Hi, I was under assumption that case sensitivity in SQL Server will be apply to both object data as well as identifiers (object names). I've istalled the new case sensitivity instance and I'm able to create 02 databases with same name (in different case), but it does not work for ...
Partitioning - Execution Plan
Christian Hamel -
30 Sep 2005 6:43 PM - 5 messages
Hello group, I'm considering creating a Partitioned view on a Sales table that contains up to 20 Millions records. I'm doing some test and have a result I'm questionning when looking at the Execution Plan generated. ...
Distributed Transactions fail
JP -
30 Sep 2005 6:26 PM - 2 messages
We are trying to create SPs that are using linked servers. I have been able to create the linked server and see the views and tables. The issue is that after creating a SP the uses the 4 part naming convention all atempt to ...
select only first row
mcnewsxp -
30 Sep 2005 5:20 PM - 14 messages
i need to get only the first row from one of the joins in a multiple join query. i am join several tables to the main table. all but one of the joins are simply replacing key values with text. ...
QA Reserved/Keyword 'HELP'
mlh -
30 Sep 2005 5:10 PM - 2 messages
Does anyone know what the 'HELP' keyword does in QA? It shows up in blue but I can't find any documentation for it. ...
Trigger on Insert for existing data
Stephen Russell -
30 Sep 2005 4:46 PM - 3 messages
Got a new biz rule that fits a trigger implementation. Table = Orders. It already has 2 triggers in place on insert so adding a third. NewRule is to update columns from a metadata rules for this particular client. The rules will come via a cursor, 1-5 rules (chage data input to ...
Inline Queries Definition
Sudhakara.T.P. -
30 Sep 2005 4:45 PM - 5 messages
hi, Can anyone let me know the exact definition of "What do you mean by Inline Queries in SQL Server?. I have heard lot of people talking about Inline Queries but when asked about the definition of that, I am not getting the exact answer for that. ...
scramble password
Rich -
30 Sep 2005 4:40 PM - 8 messages
Hello group, I have a fairly simple question (hopefully simple anyway). I have a table that has basic application user data: name, address, city, email, password. I now have a requirement to in bulk take the password and encrypt them. They ...
UPDLOCK problem with Stack
Tom -
30 Sep 2005 4:22 PM - 8 messages
Hi all i have a table, which is my stack. from this table i want to select row by row the records. after selection i set a currentuser flag, so no other user will get this record. following procedure does this things ...
converting a column from varchar to int
et -
30 Sep 2005 4:08 PM - 8 messages
I need to copy the data from varchar column into an integer column, obviously only copying integer values. How can I do this? I am not even sure how to select data from a column so that the results are only the ...
IsNumeric Function Question?
Uday -
30 Sep 2005 3:51 PM - 8 messages
Hi all, Please take a look the queries below: select isNumeric('0000E000110') as IsNum IsNum ----------- 1 (1 row(s) affected) select isNumeric('0000D000110') as IsNum IsNum ----------- 1 (1 row(s) affected) ...
Incorrect syntax near 'COLLATE'
SteveInBeloit -
30 Sep 2005 3:41 PM - 4 messages
Hi, I have an ACCESS ADP project that hooks to an SQL database. I have been working on in may weeks and it is ready to go. While testing yesterday, I found that when I know try to open a table from ACCESS, I get the above error ...
Percent Range for a list of numbers
luvgreen -
30 Sep 2005 3:19 PM - 4 messages
Hello experts. I need to give a percentile rank for a list of numbers, is there a SQL server built-in function doing this? Thanks much Example below: Data Rank 13 100.00% ...
Can we specify timeout for a SQL server job?
Pushkar -
30 Sep 2005 2:58 PM - 5 messages
Hi, I have created a SQL Server job. I want to know that wether I can specify a timeout value for the job, ie after running for some days that job should finish off. Thanks in advance. Pushkar ...
viewing index info in query analyzer
AHIhelp -
30 Sep 2005 2:57 PM - 5 messages
Does anyone know of a way to get index info on a table within query analyzer? In the same way that you can run sp_pkeys, sp_columns, sp_tables etc.... ...
Group By OR ?
Mij -
30 Sep 2005 2:45 PM - 2 messages
I have a query that produces the following result set: Effect. Date Expir. Date Cert. Type 7/23/2002 7/22/2005 O ...
Problem with SQL Server and odbc, please help me!
Tonio Tanzi -
30 Sep 2005 2:41 PM - 4 messages
I have Visual Studio Dot.Net on Win XP and use the MSDE to access to Sql Server. This morning I've attempt to create a new ODBC DSN for Sql Server so I've executed the wizard for a new System DSN by the ODBC administrator ...
Group By OR ?
Mij -
30 Sep 2005 2:23 PM - 2 messages
I have a query that produces the following result set: Effect. Date Expir. Date Cert. Type 7/23/2002 7/22/2005 O ...
More not in issue
qjlee -
30 Sep 2005 2:16 PM - 3 messages
Hi, I have three tables, one is the client information table (T1) contain an uniqueid for the client, the other is client address table (T2), which contains different type of address for the client (e.g. business address, home address) and the different type of address is identified by addtype_c, ...
Access 97 / VBA Users...
Mike Labosh -
30 Sep 2005 2:08 PM - 7 messages
....should NEVER be allowed to touch EM, no matter how much T-SQL they know. She sent 7800 records into an external "black-box" system -- records whose status wee need to track. And then she deleted them from SQL Server. Now she's talking to one of our ...
SQL Select Last Receipt Statement
Joe Williams -
30 Sep 2005 1:49 PM - 5 messages
I have a transaction table that has PartNumber, TransactionType, Date, and Quantity as fields. Obviously each PartNumber will have many transaction records with many different types of transactions (shipments, receipts, inventory moves, etc. ) The transaction type for receipts is "POR" ...
User Roles and Permission
Tony -
30 Sep 2005 1:26 PM - 2 messages
How do I change user role/permission for a user/s on time in different databases if possible pls assist thanks to Uri Dimant and R.D for my other post , it made a difference ...
Error in GroupBy
Wayne Wengert -
30 Sep 2005 11:52 AM - 5 messages
I have the query shown below which throws an error that "JudgeName" is an invalid column name? Is using an alias not allowed here? Wayne ================= code ============== SELECT (Names.LastName + ', ' + Names.FirstName) As JudgeName FROM JudgeEvals Inner Join Judges On Judges.JudgeID = JudgeEvals.JudgeID ...
Table Manipulation Issue
thomson -
30 Sep 2005 9:48 AM - 3 messages
Hi all, i do have 3 tables with me FIRST TABLE fid code description 12 asc newfor ...
Count with Group By
kiran -
30 Sep 2005 9:01 AM - 5 messages
Hi, I am using GROUP BY on two columns. SELECT ID,T_ID FROM EMPLOYEES GROUP BY ID,T_ID Result: 154 1 154 2 154 3 154 6 154 7 ...
datediff comparison to previous row in select statement
robz8701 -
30 Sep 2005 8:48 AM - 2 messages
In a table I have information of a vehicle's status with an appropriate date, what I am trying to achieve is to display the number of days between two dates of two different statuses. Problem is that the same ...
problem with xp_sendmail
Hans -
30 Sep 2005 7:52 AM - 2 messages
Hello, I have the following problem. I use the xp_sendmail often in the SQL query analyser with the folowing script: @recipients = 'hans.de.ko***@verder.nl', @subject = 'Test mail', @message = 'Testmail1' ...
file backup
Joe -
30 Sep 2005 7:19 AM - 3 messages
Since i backup a database with file backup option, then i delete the database , then i use the file to restore, it can't, why ...
no recovery option
Joe -
30 Sep 2005 7:17 AM - 3 messages
what is the meaning for no recovery option ...
Upgrading our system
Enric -
30 Sep 2005 7:01 AM - 2 messages
Dear folks, Nowadays, we have got an Active-Active cluster for to attend our business as usual. Each node own the following main features: -8 processors xeon 700 Mhz -8 Gb RAM -RAID 5 (up to 400 gb ) 12 disks approx. ...
Count Attempts!
Adam Knight -
30 Sep 2005 6:20 AM - 3 messages
Hi all, I want to SELECT the most recent ATTEMPT_ID (in this case attempt_id=3) and determine how many attempts (using COUNT) have IDENTICAL QUESTION LISTS based on the ATTEMPT_RESULTS table? IE: Attempt 2 has an IDENTICAL QUESTION LIST (to 3) in the ATTEMPT_RESULTS ...
TOP Operator - Variable?
Adam Knight -
30 Sep 2005 4:09 AM - 10 messages
Hi all, I am wanting to select a particular number of rows using the TOP operator. The number of rows in particular are provided by a varable if possible. SELECT TOP @oqs NEWID() AS ID,asmt_v2_question_id, qtext, qindex, qtype, answer_url ...
SQL 2000 UserID & Password Question
Hugh O -
30 Sep 2005 2:29 AM - 3 messages
Hi, I have the following error that I have gotten when I try to use Crystal Reports within Visual Studio.Net 2003 and within a VB ASP.Net app that accesses a SQL Server 2000 Database CrystalDecisions.CrystalReports.Engine.LogOnException: Logon failed. ...
design help
ari -
30 Sep 2005 2:02 AM - 3 messages
hey all, can someone please help me design the following: 9/29/05 Cut Lawn $20 Date of Service Service Type Price Payment Due Trans Type Payment ...
Non-deterministic UDF's?
Arthur Dent -
30 Sep 2005 1:40 AM - 7 messages
Hello all, i want to make a non-deterministic UDF... is this possible? Heres what i have... its an online catalog. The site has an option DAYS_LIST_AS_NEW, where the owner can specify a number of days for which a product is listed as new, so if the user puts a value of ...
book recommendations: ETL
sqlster -
29 Sep 2005 10:46 PM - 3 messages
Could any one please recommend some good books on sql server 2000 ETL best practices ?? I am trying to learn some best practices regarding this subject so any white papers, articles, web sites, books would be greatly appreciated. TIA... ...
How Do I Fix This Proc?
Hal Heinrich -
29 Sep 2005 10:29 PM - 5 messages
In a multi-user environment, this proc is expected to return distinct values for concurrent users - but it doesn't, some duplicates are returned. I thought that the 'BEGIN TRAN/COMMIT' would provide the required locking - I'm guessing that's where I went wrong. How do I fix this proc? The DDL for the ...
SQL Statement
helpplease -
29 Sep 2005 10:20 PM - 5 messages
Hi, I'm having a tough time writing a sql stmt. Any kind of help is very much appreciated. The info is as follows: SalesOrder sono so-suffix solineno qtyord netamt ...
copy tuples from table tsql?
pnp -
29 Sep 2005 10:01 PM - 2 messages
Hi all, I'm trying to write a TSQL procedure that takes as an argument a tablename in a database and then it copies the first 100 tuples of the given table in the same table (it actually duplicates them). The table ...
Unknown Columns!
Arpan -
29 Sep 2005 8:32 PM - 9 messages
My application retrieves records from a SQL Server 7.0 DB table for which I am using a stored procedure but while coding, I am not aware of the no. of columns existing in that DB table. Neither am I aware of the ...
Extracting image column to the file
Gene -
29 Sep 2005 8:25 PM - 2 messages
Hello all, how can I extract image strored in DB in to file? Will something like this work? DECLARE @cmd VARCHAR(2048) SET @cmd = 'bcp select history_image from recipient where recipient_id = 1 queryout c:\test\625954.jpg ' EXEC master..xp_cmdshell @cmd, NO_OUTPUT ...
Linking SQL Server to a DBF file
Zachary Hartnett -
29 Sep 2005 8:23 PM - 3 messages
I believe I should be able to link to a .dbf file as a Linked Server through SQL Server. For instance, in C# code, we can connect with a DBF file using either ODBC... --------------------------------------------------------- System.Data.Odbc.OdbcConnection odbcConnection = ...
order by
gv -
29 Sep 2005 7:55 PM - 7 messages
Hi all, I Apologize if I'm not clear, I'm going to try and explain what I need. This query works fine: On the table "k" there is a display_order column that I would like the k.sentence_name ordered by. ...
INSERT INTO query exception
bruce lawson -
29 Sep 2005 7:51 PM - 4 messages
Hi, I'm fairly new at SQL query language and am running an example program from a text in VisualBasic where I want to just insert a new row in an existing table, but I keep getting a syntax error in the INSERT INTO ...
Linked Server Question
Mike Labosh -
29 Sep 2005 7:41 PM - 5 messages
We have a dev server, HORSQL01 and a production server, HORSQL02 Each one is listed under the EM Linked Servers node of the other. But I am confused. When I open up the Linked Servers\HorSql01 node, I don't see a ...
Can someone explain why this is not an error?
DWalker -
29 Sep 2005 6:48 PM - 8 messages
I accidentally did something similar to this, and I can't figure out why it doesn't give an error. Use Pubs Select * From Authors Where Au_LName In (Select Au_LName From Publishers) Of course, "Select Au_LName From Publishers" by itself gives an error ...
Bulk Loading: TempFilePath security question
isbat1 -
29 Sep 2005 6:06 PM - 2 messages
I've got a program written that runs on one computer and performs bulk updates to a SQL Server 2000 table on a different computer. I also need transactional behavior, so I have to specify a value for TempFilePath on my SQLXMLBulkLoad3Class object. ...
Simple query?
Tom Gaughan -
29 Sep 2005 6:02 PM - 11 messages
This seems like it should be simple... I have a simpel select query that is selecting customer records. SELECT CustomerNumber as [Cust #], ItemNumber as [Item #] WHERE CustomerNumber IN ('1', '2', '3') Sample result: Cust # Item# ...
server registeration problem...
=== Steve L === -
29 Sep 2005 5:15 PM - 5 messages
Background: sql2k on windows 2k3 servers. I'm managing an remote offsite sql server for a company. I recently installed a second instance of sql server (server\dev) on the same box, but haven't been able to register the 2nd instance ...
Select statement on multiple values
Antonio Budano -
29 Sep 2005 5:13 PM - 5 messages
Hi there, I have a table as defined below that contains some configuraton values. ConfigurationID CharacteristicID CharacteristicValue --------------- ---------------- ------------------- 1234567890 Lenght 2300 ...
Cursor variable not declared issue
SJM -
29 Sep 2005 5:09 PM - 3 messages
Ok, I missed the boat somewhere. I prepared the query below to go though all the columns and tables in the database and return the count of distinct values for each column and label them with the table and column names ...
Scale not correct in query
larzeb -
29 Sep 2005 5:00 PM - 10 messages
The 2 queries below return different values for b.cost. I don't understand why. The 2nd query returns 575.112, the correct value, where the first returns 580.00. declare @BeginDate Datetime declare @EndDate Datetime ...
Column to Search in DB
KD -
29 Sep 2005 4:34 PM - 4 messages
Hi, Can anyone help me by telling the sql statement through which I should be able to locate the table which contains that ColumnName.... Thanks in Advance KD ...
return results of lastest date
gv -
29 Sep 2005 4:34 PM - 3 messages
Hi all, The following query returns the following results. SELECT docCategories.docCat, docNames.docName, docVersions.docVersionDate FROM docCategories, docNames, docVersions WHERE docNames.deletedFlag = 0 AND docNames.docCatID=docCategories.docCatID AND ...
Database size entry?
Dave H -
29 Sep 2005 4:14 PM - 4 messages
Which system table is the currently defined size (hopefully the total size) of the data and log devices found? I'm assuming in master somewhere? sysobjects? I just can't find it... thanks ...
Permission confusion
DazedAndConfused -
29 Sep 2005 4:09 PM - 5 messages
It seems by default the public role is granted very generous permissions. When I tried DENY ALL TO public is didn't seem to have any affect. I know it will work by listing the objects or going into enterprise manager and ...
Help with subquery
CD -
29 Sep 2005 3:57 PM - 10 messages
O.k. the following query works, unless there is more that one value a column. It tells me, "Subquery returned mor than 1 value. This is not permitted when the subquery follows =, or when the subquery is used as an expression". ...
adding 140,000 records requires index rebuild. make sense?
John Mott -
29 Sep 2005 3:47 PM - 9 messages
hello all, i have a table thats getting about 140,000 new records a day from a program reading data from a socket (about 300 every 3 minutes). in addition to the primary key it has an 8 byte date/time field thats indexed. there are also ...
How to select all values for stock, which match certain condition
John -
29 Sep 2005 3:46 PM - 4 messages
Hi, I need to make a query on a single table containing historical stock data, something like: ID, StockID, Date, Open, Close, Volume, ... The problem is that I need to get All records for the stock, for which at least one record matches some condition. ...
xp_cmdshell to open/close file
sqlster -
29 Sep 2005 3:46 PM - 5 messages
Hi all, Does any one know tsql syntax to open and close a file on network drive? Of course this command should execute in proper security context. TIA.. ...
VPN and EM timeout problem
PJ6 -
29 Sep 2005 3:19 PM - 3 messages
For some reason I cannot connect to a SQL server with EM over a VPN connection, I keep getting a timeout error. What bugs me is that this "timeout" happens within a second or two - normally network timeouts are like 30 seconds. I've never had this problem connecting to other SQL servers ...
Need advice with a query
News -
29 Sep 2005 3:09 PM - 15 messages
Hi, I need an advice. I have a new project where I have to store employee salary values in order to keep historical representation of all changes done to the employee record. Below is the approximate model how I am going to proceed. ...
EXEC or EXECUTE, SET or SELECT
SureshBeniwal -
29 Sep 2005 2:21 PM - 5 messages
Hi pls find time to throw some light on whether and where to use EXE/EXECUTE and SET/SELECT? What are the differences? Another thing..if we start a trigger and within the transaction statements we first truncate any table and then ...
executing sp_changeownerdb
Jason -
29 Sep 2005 2:21 PM - 3 messages
Hi, I've a problem executing sp_changedbowner in my stored procedure which is saved in the master's stored procedures. The code fails after executing @proc1. The errors says that i could not find proc2. Here's the code: CREATE PROC usp_RestoreDB( ...
convert adDBtimeStamp to datetime
Lucian Baltes -
29 Sep 2005 1:59 PM - 4 messages
Hello, I use a SQL Server with ODBC driver and >NET C#. I want to convert a date field with adDBtimeStamp format to a DATETIME format, but no solution could be found till now. My query is as follows: ...
SP returning multiple resultsets
Henrik Skak Pedersen -
29 Sep 2005 1:45 PM - 4 messages
Hello, I have a stored procedure which is traversing a tree. The table looks like this: Organization (OrganizationId, ParentOrganizationId, ect....). The stored procedure is looking like this: ALTER PROCEDURE dbo.ShowHierarchy ( @Root varchar(10) = NULL ) AS BEGIN SET NOCOUNT ON ...
Inner join in an update
Arne -
29 Sep 2005 1:40 PM - 5 messages
How do I translate this statement from Access SQL to MS SQL: UPDATE Market INNER JOIN MarketSys ON Market.MarketID = MarketSys.CurrentmarketID ...
Index Tuning Wizard
Wes -
29 Sep 2005 1:02 PM - 9 messages
I am running the index tuning wizard to evaluate a query for optimization. I am applying additional non clustered indexes were I feel it should benefit the query. After running the Index Tuning Wizard - the recommendation is to ...
Trapping fatal error
Karthik -
29 Sep 2005 12:30 PM - 3 messages
Hi, I work as part of a testing team that does a lot of stress testing of database. At times we run SP's that goes into a loop millions of times and inserts test data. Once in a while these SP's terminate abruptly because of ...
Get Value of IDENTITY
ReTF -
29 Sep 2005 11:37 AM - 5 messages
Hi, I need get value of IDENTITY column after a insert (of the inserted item), hava way to do this automatic, or same function that do this? Thanks ...
"Net Send" from SQL2000 on Windows 2003.
Geir Holme -
29 Sep 2005 11:03 AM - 4 messages
Hi all. The following command don't work on ours SQL server anymore. Not sure why, but could it be that the command "Net Send" is removed for NT 2000? Any ideas. Thanks Geir DECLARE @Message varchar(255) Set @Message = 'net send USER Message to OLNY from SAM : . TEST, TEST, Price ...
WHILE Loop with parameters from a varchar parameter
Xavier -
29 Sep 2005 10:51 AM - 5 messages
hello, i need to read the value of a parameters for the loop from a local varchar variable example for the variable: '1,4,8,9,22' or '3,5' or '44,5,8,9' How can i get the information ...
Stored procedures, permissions, table names
Jure Bogataj -
29 Sep 2005 10:48 AM - 6 messages
Hello all! I'm having problems regarding executing stored procedures under differents users or different database. I have, let's say 100 tables with the same name, but different owners. Picture this scenario: User: dbo (login: sa) Table: MYTEST (FullName: ...
|
|||||||||||||||||||||||