Forum: MS SQL May 27th, 2009 |
| Replies: 4 Views: 1,820 http://snippets.dzone.com/posts/show/372 |
Forum: MS SQL Mar 15th, 2009 |
| Replies: 1 Views: 516 when you run the .msi, dont you see the remove-repair options? |
Forum: MS SQL Feb 6th, 2009 |
| Replies: 6 Views: 2,909 you gotta be kidding :) do you think we are so stupid to think about it in the first place :) |
Forum: MS SQL Feb 4th, 2009 |
| Replies: 6 Views: 2,909 Yes, you can do many things using server explorer from within visual studio; however, management studio is more appropriate to achieve the same things and there are many things that you can only... |
Forum: MS SQL Feb 3rd, 2009 |
| Replies: 6 Views: 2,909 How do i change the name of a table in my sql server 2005 express edition database using visual studio server explorer? |
Forum: MS SQL Mar 13th, 2008 |
| Replies: 7 Views: 16,960 You can download the management studio for express edition(free from microsoft) and do the same thing but i am not sure if the management studio for express edition has that functionality |
Forum: MS SQL Mar 12th, 2008 |
| Replies: 2 Views: 951 Yeah there is also COALESCE(columnName,'') |
Forum: MS SQL Mar 12th, 2008 |
| Replies: 3 Views: 1,765 |
Forum: MS SQL Mar 11th, 2008 |
| Replies: 3 Views: 1,765 today i came across to an sql problem from one of the threads in the database forum :
to solve the problem i created a table named "names" having these columns :
PKID | name | lastname
and i... |
Forum: MS SQL Mar 11th, 2008 |
| Replies: 0 Views: 1,597 In Turkey we use "." as thousand seperator and "," as decimal seperator. If you are working with currencies in sqlserver, and if the money columns is of type "money" then the problem occurs beause of... |
Forum: MS SQL Mar 11th, 2008 |
| Replies: 0 Views: 2,089 How to insert big html markup with white spaces(i.e. line breaks) and single and double quotation marks to sql server :
To insert that big html markup to ms sql server, i tried to copy the markup... |
Forum: MS SQL Mar 11th, 2008 |
| Replies: 2 Views: 951 select CASE WHEN FirstColumn IS NULL THEN '' ELSE FirstColumn END + ' ' +
CASE WHEN SecondColumn IS NULL THEN '' ELSE SecondColumn END as ResultColumn
from myTable |
Forum: MS SQL Mar 11th, 2008 |
| Replies: 2 Views: 1,791 select myColumn from myTable1
union
select myColumn from myTable2 |
Forum: MS SQL Mar 11th, 2008 |
| Replies: 7 Views: 16,960 Copy a table from one database to another database in another ms sql server using sql server management studio :
If your table was in the same ms sql server but in another database, you would copy... |
Forum: MS SQL Feb 13th, 2008 |
| Replies: 6 Views: 3,040 the t-sql below worked :
set statistics time on
set statistics io on
declare @Topid_in int -- The top level we want to resolve children for
select @topid_in = 1;
with Hierarchycte (id,... |
Forum: MS SQL Feb 13th, 2008 |
| Replies: 6 Views: 3,040 Thanks but this is not what i wanted, i want to see the childs recursively, i want to see the grand childs, childs of grands childs and so on. |
Forum: MS SQL Feb 11th, 2008 |
| Replies: 6 Views: 3,040 Thanks but this is not what i want. i want to pass cat.id as parameter and get all the childrows in it.
example
catid | catname | parentid
1 | 1 | null
2 |1.1 |1
3... |
Forum: MS SQL Feb 8th, 2008 |
| Replies: 6 Views: 3,040 what is the required t-sql for getting all the child categories in a parent category?
my table is like this : id | name | parentid |
Forum: MS SQL Jan 31st, 2008 |
| Replies: 1 Views: 762 *What is the difference between typed and untyped dataset?
- typed dataset is a dataset which you determine the types that are used in the columns of the datatables forming the dataset. if you... |
Forum: MS SQL Jan 31st, 2008 |
| Replies: 13 Views: 2,451 why dont you just copy paste the code i wrote for you? switch to sql view then paste the given code, then refresh your table, you will see the targeted records are gone. |
Forum: MS SQL Jan 31st, 2008 |
| Replies: 13 Views: 2,451 your final sql will be as follows :
this code below deletes only first found row of row sets having the same value for the column nvarchar1 and the value of 1 for the column int1
declare... |
Forum: MS SQL Jan 31st, 2008 |
| Replies: 13 Views: 2,451 Cursor is a reserved keyword of t-sql for the ms sql server. Cursor is a built-in structure in ms sql's sql specification. Cursors work similar to foreach statements in c#, so if you want to do... |
Forum: MS SQL Jan 31st, 2008 |
| Replies: 13 Views: 2,451 and if you want to delete only first rows of the grouped row sets, just remove the break statement from the code above as follows
begin
delete top (1) from mytable where (@varchar1=varchar1... |
Forum: MS SQL Jan 31st, 2008 |
| Replies: 13 Views: 2,451 by the way, my code erases all the rows having duplicate values in varchar1 column and value of 1 for the int1 column. if you want to delete the first row, then you have to set a break statement in... |
Forum: MS SQL Jan 31st, 2008 |
| Replies: 13 Views: 2,451 you can do such things using cursor as follows :
declare @varchar1 nvarchar(50)
declare mycursor cursor for
select varchar1,
from mytable
group by varchar1
having count(*) > 1
open... |
Forum: MS SQL Jan 31st, 2008 |
| Replies: 4 Views: 1,015 can you clearify what you ask a little bit please? |
Forum: MS SQL Jan 31st, 2008 |
| Replies: 1 Views: 2,520 after your insert query append
select @@IDENTITY statement |