Viewing 15 posts - 871 through 885 (of 1,183 total)
Select ident_type_id as Form1_IDs
from form_ident_types
where b.form_id = 1
and ident_type_id NOT IN (
Select ident_type_id
from form_ident_types
where form_id = 7)
October 11, 2007 at 8:20 am
That depends. Are you doing a lot of grouping or aggregating in the report? Do as much as possible in the code as the report server isn't nearly as efficient...
October 11, 2007 at 7:18 am
Hmmmm. I guess you can't post XML here...
STEVE :exclamation: !!!!!
October 11, 2007 at 6:55 am
Place your XML within "[cod e]" and "[/cod e]" tags and remove the space from the word code.
October 11, 2007 at 6:23 am
I too would like to know how you keep your formatting!!!:D
October 11, 2007 at 6:07 am
Isn't that what DISTINCT means?
If you have a set of 1,1,1,2,3,3,3,4 are the DISTINCT numbers not 1,2,3, and 4?
October 10, 2007 at 7:58 am
Peter, forgive me here (bold is only being used for clarity, not yelling). But ...
given the table ....
CREATE TABLE #temp
(Id int,
tname varchar(10),
Email varchar(10),
Age int,
Salary int)
INSERT INTO #temp
SELECT '1','aaa','1@abc.com',20,1000
UNION
SELECT '2','aaa','1@abc.com',20,1000
UNION
SELECT '3','aaa','2@abc.com',20,1000
UNION...
October 10, 2007 at 7:46 am
No, the count(*) will give you the count of records in that group, not an incremental row number....
Run your script and you'll see... *grin* :hehe:
October 10, 2007 at 7:18 am
You want row_number() not count(*) ....
CREATE TABLE #temp
(
Id int,
tname varchar(10),
Email varchar(10),
Age int,
Salary int
)
INSERT INTO #temp
SELECT '1','aaa','1@abc.com',20,1000
UNION
SELECT '2','aaa','1@abc.com',20,1000
UNION
SELECT '3','bbb','1@abc.com',20,1000
SELECT ID, tName, Email, Age, Salary, recID
FROM( SELECT ID, tName, Email, Age, Salary,
ROW_NUMBER()...
October 10, 2007 at 6:33 am
Can you provide the DDL (definition) for your table. What fields does it contain? Which two fields are required to be "distinct" in your result set?
October 10, 2007 at 5:59 am
Thanks Steve. FYI, I didn't mean the "first" physical record, rather the first record in terms of datetime.
But anywho, thanks for the better solution Steve.
October 8, 2007 at 10:34 am
This solution is taking so many assumptions, it's not funny... but this works
with the assumptions that
1. the start date is the first entry in the table.
2. a phone number...
October 8, 2007 at 9:25 am
Viewing 15 posts - 871 through 885 (of 1,183 total)