When you call a method in SQLServer, you often encounter the. Or: two call methods, of which. is an instance call method, and: is a static call method. If you are familiar with the C # syntax, call the instance method in C #: corresponds to the static method in C.
When you call a method in SQL Server, you often encounter the. Or: two call methods, of which, the. is an instance call method, and the: is a static call method. If you are familiar with the C # syntax, call the instance method in C #: corresponds to the static method in C.
The following is an SQL Server instance. The following SQL statements run in the 2008 environment:
DECLARE @ g geography;
SET @ g = geography: Parse ('linestring (-122.360 47.656,-122.343 47.656 )');
SELECT @ g;
SELECT @ g. ToString ();
Result set:
Bytes
LINESTRING (-122.36 47.656,-122.343 47.656)
Geography is a new type of geographic information supported by SQL Server 2008. It is beyond the scope of this article and is not described here.
Let's only look at the geography: Parse method and @ g. toString () method. We can see that the Parse method supports calling through the geography type, which is equivalent to Class in C. in the StaticMethod format, ToString () is called through the instance g.
If you need to reprint, please indicate the original column from CSDN TJVictor