Viewing 15 posts - 181 through 195 (of 254 total)
Try to use char(13) + char(10), here is example:
create table test
(data varchar(max))
insert into test
values ('hello ' + char(13) + char(10) + 'world ! ')
select * from test
Is this what...
April 24, 2007 at 1:59 pm
First, it depends on what your developers develop. If they are doing just front-end apps without creating the stored procedures, they obviously don't need to have a SSMS installed.
However,...
April 24, 2007 at 10:16 am
In order to answer to a question of what size is error log file is I need to know in what folder it stores error log files - I tried...
April 24, 2007 at 10:03 am
Yelena:
I don't quite understand your point. So you are saying that if I insert a string with length of for example 35000 characters into varchar(max) data type column it will...
April 16, 2007 at 3:55 pm
You can also try this in 2005:
select
session_id,
text
from sys.dm_exec_requests s1
cross apply
sys.dm_exec_sql_text(sql_handle) as s2
where session_id = <SPID NUMBER>
April 16, 2007 at 10:44 am
In such cases when I am not sure about future growth of records length, I use varchar(max). It may have performance issues since SQL Server has to create another allocation...
April 16, 2007 at 10:19 am
There are number of methods to identify a database call and its script. First that comes to my mind is to setup Profiler, then filter only application or user name that you...
April 12, 2007 at 3:34 pm
Have you tried OpenXML function ?
April 12, 2007 at 11:18 am
You can check database compatibily level by running this query:
select
name,
compatibility_level
from master.sys.databases
where name in ('FirstDb', 'SecondDb')
If any of them will have compatibility level 80 (which is 2000) I recommend...
April 11, 2007 at 2:35 pm
Do both databases have compatibility level 90 ? You can find it in database properties/ options.
April 11, 2007 at 11:33 am
select
areacode,
areaname ,
unique_id = areacode * 100 + rank() over(order by areacode, areaname)
from table1
April 6, 2007 at 11:39 am
create table empl(total decimal(5,2))
go
insert into empl
select 263.07 union
select 458.02 union
select 45.58
go
select
stuff
(
(
select ','+ cast(total as varchar(6)) from empl t1
for xml path('')
)
,1,1,''
)
go
April 5, 2007 at 11:32 am
Is this index enabled ?
You can check this:
select
object_name(object_id),
name,
is_unique,
is_disabled
from sys.indexes
where name = <your_index_name>
April 5, 2007 at 11:02 am
The first part is easy, to compare missing rows run this:
select
t1.*
from
table1 t1 left join table2 t2
on t1.col1 = t2.col1
where t2.col1 is null
For the second part, where you need to compare...
April 4, 2007 at 10:08 am
Try this:
select
convert(smalldatetime,convert(varchar(10),getdate(),101))
April 4, 2007 at 9:29 am
Viewing 15 posts - 181 through 195 (of 254 total)