George, thank you for the quick response. I bet that is exactly what happened, now I know where to look.
Yes, we do store our dates as DateTime, but this is a special case where we are dealing with a feed that has dates entered as text.
I use the Convert function as follows (a little example):
SELECT CONVERT(datetime,MyDateField,101)
This has always worked. Now if I wanted the British format, I'd put a 103 in the end. That also worked in the past.
BUT the weird thing now is that the CONVERT function is expecting MyDateField...
I need to copy several million rows of data from a linked server into a database table. I am a little hesitant to just
INSERT INTO xxx (...)
SELECT (...)
FROM
Is this the best way? Are the Export/Import tools more efficient than the above simple query? What about Bulk Insert? I have never used...
I am trying to find the most efficient way to pivot the first two values for every "group by" in a recordset. For example, here is my table:
Account Form Date Score
1 A 1/8/07 89%
1 B 2/7/07 95%
1 A 8/3/07 72%
1 A 12/1/07 87%
2...
The only problem with the +'e0' is if the column does happen to contain scientific notation. The ISNUMERIC by itself would work great on a value of '1e3', but if you turned it into '1e3e0' then you've just invalidated your once-numeric value. I guess you just need to know your data. In my...
gmmastros, Wow that's great! Who would have thought to make in scientific notation first, nice idea. Thanks!
SQLDenis, I was originally thinking along the same lines, but the NOT LIKE '%[a-z]%' does not catch the case of a single dash "-". This value still cannot be converted to real (but can...
I have an nvarchar column that is sometimes used to hold numeric data and I wish to pull that data out as real and changing text values to zero. So I wrote a query something like the following:
SELECT CASE WHEN ISNUMERIC(TextField)=1 THEN CAST(TextField AS real) ELSE 0 END
FROM MyTableI am...
I have a very large table that is basically structured like this:Category Score Type
1 90 0
2 3 0
2 87 1
3 65 0Notice that the Category 2 has two records (of type 0 and 1). What I need to do is select a recordset that excludes all 0-type...
I am a software developer, and I have been given the additional task (opportunity?) of being in charge of scheduling/prioritizing projects for my team. I am temporarily using an Outlook calendar to track everyone's projects and timelines, and am looking for a more permanent solution.
I haven't...
Hello, I am new to ASP.NET and I am using a TemplateColumn in a datagrid as follows, but the width property seems to do nothing (really a pain when the image is large):<asp:TemplateColumn HeaderText="My Image">
<ItemTemplate>
<asp:HyperLink ImageUrl='<%#...
Alright, I got it to work. However, now the databinding seems to be broken on the combobox. The datasource changes as I navigate records, but the selectedvalue is remaining as the first value in the list always.
I have a combo box with databinding to a dataset, but it's datasource should change depending on another field in the dataset. So for example, if the user scrolls to a record and the "Department" field is Quality, then only applicable employees show up in an Employee drop-down. When the user...
Hmmm, I tried this and had an interesting result. I made two labels on the form outside of the datagrid, one for row number and one for column number. The CurrentCellChanged event updated these numbers as you would expect, even with "new" rows that had no data. However, if I was on a new row...
Hello, I want to capture the CurrentCell of a datagrid when the user gives focus elsewhere (using the datagrid's Leave event). This works just fine if the cursor was in a populated row, but if the cursor is in a "new" row that does not yet have data, then the CurrentCell property gives me the...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.