Quantcast
Channel: Transact-SQL forum
Browsing all 23857 articles
Browse latest View live

Msg 213, level 16, state 1, line 35

Hi, can you please help me with tha databaze ? I don´t know what the problem could be. Thanks.  CREATE  TABLE Cviceni  (    id_cviceni             INTEGER NOT NULL ,    nazev_cviceni          VARCHAR...

View Article


Image may be NSFW.
Clik here to view.

Lock request timeout period exceeded error when expand table list in SSMS...

Hi All,I know this question has been asked several times, but nothing fixed my issue. I have been facing the error "Lock request timeout period exceeded. Error 1222 when I try to expand the tables list...

View Article


Image may be NSFW.
Clik here to view.

SQL Query with a little bit more complicated WHERE clause performance issue

Hello, I have some performance issue in this case:Very simplified query:SELECT COUNT(*) FROM Items WHERE ConditionA OR ConditionB OR ConditionC OR ...Simply I have to determine how many Items the user...

View Article

Newguid vs newsequencialid and detail

hi,Q1)Is the following is true for NEWGUID  also.Each GUID generated by using NEWSEQUENTIALID() is unique on that computer. GUIDs generated by using NEWSEQUENTIALID() are unique acrossmultiple...

View Article

An error occurred while executing batch. Error message is: There is not...

Hello all,I execute a T-SQL query, which will retrieve large amount of data, however, I get an error message after a few seconde.The error message is :An error occurred while executing batch. Error...

View Article


How to concatenate the string and Parameter passed to stored procedure

Hi All, I am trying to bind the variable inside the stored procedure with some default string and passed parameter to SP but it giving error at + sign whenever i am going to concatenate it for...

View Article

Help with query

Hi,AM trying to develop a report that audits sql server AD Groups. I am trying to retrieve the list of all the members in the AD groups on SQL server that starts with a common prefix, Say 'XYZ_' SO far...

View Article

Transaction Isolation Level to Read UnCommited in Non OLTP Database

HI,We are having a database which for NOT OLTP process. That is OLAP DB. Operation on that DB is only Select and (Incremental Insert - FOR DWH ) not Update/Delete and we are performing ROLAP operations...

View Article


Auto Relationship

Hi Team,I would like to create a auto relationship between tables.Currently i am using Northwind DB with tables (Orders, OrderDetails, Customers)Orders ( OrderId,...

View Article


Deadlock while inserting data into a table.

I have a table X. And a trigger has been created on that table FOR Insert and update. From that trigger a stored procedure got called which insert data into another table.Here is the insert statement...

View Article

Alias column with variable value in SQL Script

Hi All, How to alise a column Name to a variable value..  Declare @test as Varchar(20) Select Column_A From Table_A In above query i want to alise for column_A as @test variable value

View Article

Problem reading sharepoint 2010 lists using TSQL openrowset from SQL2008r2

I have several different SQL servers reading sharepoint lists. However, I'm trying to configure another SQL server and I just can't get it to work. Here is the error message:Msg 7399, Level 16, State...

View Article

select Query where multiple column in multiple values (cant use in clause)

I can use (in clause) with on column like this:Select code from table where code in(1,2,3)-------------------------------My case:-------------------------------------------------I’ve 4 columns PK of...

View Article


Comparing T1 to T2

Hello,please, could somebody help me to customize this query:SELECT LastName, ParentsName, FirstName, DateOfBirth FROM T1 WHERE (LastName and ParentsName and FirstName and  DateOfBirth) NOT IN...

View Article

For each ID, I want to look at the [Index Key] and copy over the [Index...

I’m struggling a bit to get this working. I’ve got data loaded into a staging table (bulk insert) and then I’m trying to transform 3 unique IDs into a final table:...

View Article


error supquery returned more than 1 value

UPDATErs_current_runtimeSETprocessed_date =NULLWHERECORP_PRFT_CTR IN(SELECT LOC_NUMFROM RET_LOC_INFOWHERE LIVE_IN_PRICEBOOK='Y')GOWHILE (SELECTCOUNT(*)FROM rs_current_runtime       WHERE...

View Article

CLR TVF performs slower when used via cross apply than when used in direct...

The code I am using    create table largecsv (val nchar(1000))    insert into largecsv(val) values ('aaa,bbb,ccc,ddd,eee,aaa,bbb,ccc,ddd,eee,aaa,bbb,ccc,ddd,eee')               select * from...

View Article


Help with simple sql statement usiing Rank function..

Hello I have very important question..this is how i have a dataset...This is the Log Table And the actual Table holds the current value.   12345Current Table 12345   575 232 4567Log Table...

View Article

Hierarical query

Hi Gurus,I have a employee table which contains empno, ename, supervisor number, supervisor name. Can you please assist me with the query like the data should be displayed in a tree structure. For Eg,...

View Article

avoiding using a temp table in a stored procedure

Can I write a stored procedure that does INSERTs into the resultset of the stored procedure instead of having to use a temp table and then doing a SELECT of the records in that temp table ?...

View Article
Browsing all 23857 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>