Viewing 15 posts - 7,786 through 7,800 (of 13,469 total)
can you confirm this actually returns something from your side: syntactically, it seems to work on my side:
--INSERT INTO SpatialDemo (SpatialData)
--test the select first:, then uncomment the INSERT INTO
SELECT geography::Point(Latitude,...
April 8, 2011 at 12:34 pm
looks like this page has some examples of the conversion; i haven't tried this yet:
http://www.sql-server-helper.com/sql-server-2008/convert-latitude-longitude-to-geography-point.aspx
I'm going to have to throw some time into studying this a bit;
create table x(
myLat ...
April 8, 2011 at 11:45 am
is there a question in there somewhere? all you did was paste Narayana Vyas Kondreddi's well known search function.
April 8, 2011 at 11:36 am
there's a difference between 'null'( a string literal) and the keyword NULL;
since you are not replacing more than one result, you don't need the CASE statement in this instance.
UPDATE dbo.LOCATION
SET...
April 8, 2011 at 7:37 am
you need to wrap and alias the XML like this:
Create Table #Results(
id int identity(1,1) not null primary key,
ResultsXML XML )
INSERT INTO #Results(ResultsXML)
SELECT (
...
April 8, 2011 at 7:34 am
are you taking the network data transfer into consideration?
on your local machine, the million rows go directly into memory; on the remote server, they have to travel over the network,...
April 8, 2011 at 7:27 am
a simple example:
SELECT
t1.*,
t2.*
FROM Databasename.dbo.Table t1
INNER JOIN MyLinkedServer.DbName.dbo.OtherTable t2
ON t1.ID = t2.ID
April 8, 2011 at 6:59 am
mvklingeren (4/8/2011)
First column IDENTITY,
Second column, containing the XML string
Would that be the right...
April 8, 2011 at 6:45 am
but the results is always a single column FOR XML isn't it? it doesn't matter if the XML contains multiple nodes or not.
April 8, 2011 at 6:34 am
you can also strip the time portion off of the parameter so you can compare dates to dates:
Select DateID FROM tblDates WHERE theDate = select DATEADD(dd, DATEDIFF(dd,0,@SomeDate), 0)
April 8, 2011 at 6:33 am
but you do know the names and number:
SELECT CustId AS label1, Name AS label2,Emailadres AS label3 FROM Customer
into #tmp WHERE 1=2 FOR XML RAW
April 8, 2011 at 6:29 am
for crossdatabase stuff inside a procedure , you only got two choices;
1: can you adapt the specific script to use 3 part names?
you know, SELECT * FROM Production.dbo.Invoices
or
2: switch...
April 8, 2011 at 6:14 am
i think this will do what you are asking:
UPDATE loc_test
SET assoc = CASE
WHEN assoc = '1'
...
April 8, 2011 at 5:54 am
I had that same problem; someone used some script that granted all objects to the public role via a cursor that was included as some 3rd party app; yuck. some...
April 8, 2011 at 5:46 am
here's some sample data i slapped together:
with myERPMap(Letter,Code)
AS
(
SELECT N'ü','\123' UNION ALL
SELECT N'á','\111' UNION ALL
SELECT N'é','\133'
),
MyDataToFix (ThePhrase)
AS
(
SELECT 'Personn\133l \123s\111g\133' UNION ALL
SELECT 'sp\133ci\111l ch\111r\111ct\133rs' UNION ALL
SELECT '\111lph\111n\123m\133ric cod\133'
)
so far, i've only...
April 8, 2011 at 4:57 am
Viewing 15 posts - 7,786 through 7,800 (of 13,469 total)