Viewing 6 posts - 1 through 6 (of 6 total)
You haven't provided a lot of info about your table and your actual queries (and the table names in your two queries don't match), but if I read your situation...
December 12, 2005 at 6:47 pm
Thanks, Nicolas, that is what I meant. 🙂
Luciana, from what you have shown us, you do not need to use dynamic SQL nor a cursor to do this.
Just use this...
October 26, 2005 at 2:55 pm
Luciana,
If I understand what you are up to, once you have the values in a table, could you not simply use a formulation like this:
--
create table x (x char)
go
insert x...
October 26, 2005 at 11:59 am
Simply update test2 set datefield = convert(char, intfield) should be sufficient. (pressed ENTER too soon 🙂
February 17, 2004 at 11:36 am
Since yyyymmdd is actually a valid date format (ISO), SQL server should be smart enough to know it's a date if it's simply treated as char. So, in mimorr's solution...
February 17, 2004 at 11:35 am
Is this more or less what you had in mind?
select EntryVal.*
from ( select ID_Field, max(Begindate) MaxBegin,
...
December 18, 2003 at 4:58 pm
Viewing 6 posts - 1 through 6 (of 6 total)