SQL Server 2017 - IP address is null2019 Community Moderator ElectionAdd a column with a default value to an existing table in SQL ServerHow to return only the Date from a SQL Server DateTime datatypeHow to check if a column exists in a SQL Server table?Check if table exists in SQL ServerHow to concatenate text from multiple rows into a single text string in SQL server?LEFT JOIN vs. LEFT OUTER JOIN in SQL ServerInserting multiple rows in a single SQL query?Altering a column: null to not nullHow do I UPDATE from a SELECT in SQL Server?How to Delete using INNER JOIN with SQL Server?
RegionDifference for Cylinder and Cuboid
Be in awe of my brilliance!
Rejected in 4th interview round citing insufficient years of experience
Humanity loses the vast majority of its technology, information, and population in the year 2122. How long does it take to rebuild itself?
Possible Leak In Concrete
It's a yearly task, alright
Can elves maintain concentration in a trance?
Why did it take so long to abandon sail after steamships were demonstrated?
Theorems like the Lovász Local Lemma?
Simulating rnorm() using runif()
Should we release the security issues we found in our product as CVE or we can just update those on weekly release notes?
What does it mean to make a bootable LiveUSB?
Citation at the bottom for subfigures in beamer frame
Why is "das Weib" grammatically neuter?
How could a female member of a species produce eggs unto death?
Welcoming 2019 Pi day: How to draw the letter π?
Professor being mistaken for a grad student
Why must traveling waves have the same amplitude to form a standing wave?
Is it possible that AIC = BIC?
Employee lack of ownership
Why are the outputs of printf and std::cout different
My adviser wants to be the first author
Why using two cd commands in bash script does not execute the second command
The use of "touch" and "touch on" in context
SQL Server 2017 - IP address is null
2019 Community Moderator ElectionAdd a column with a default value to an existing table in SQL ServerHow to return only the Date from a SQL Server DateTime datatypeHow to check if a column exists in a SQL Server table?Check if table exists in SQL ServerHow to concatenate text from multiple rows into a single text string in SQL server?LEFT JOIN vs. LEFT OUTER JOIN in SQL ServerInserting multiple rows in a single SQL query?Altering a column: null to not nullHow do I UPDATE from a SELECT in SQL Server?How to Delete using INNER JOIN with SQL Server?
I am trying to connect via Android Studio to a SQL Server database using jtds. The type of instance I'm using is a standalone.
In order to establish a connection, I am using the following statement:
Connection DbConn = DriverManager.getConnection("jdbc:jtds:sqlserver://**ip_adress:port**/**my_db**", un, pass);
I have tried retrieving the value of the IP address by launching the following query:
SELECT
CONNECTIONPROPERTY('net_transport') AS net_transport,
CONNECTIONPROPERTY('protocol_type') AS protocol_type,
CONNECTIONPROPERTY('auth_scheme') AS auth_scheme,
CONNECTIONPROPERTY('local_net_address') AS local_net_address,
CONNECTIONPROPERTY('local_tcp_port') AS local_tcp_port,
CONNECTIONPROPERTY('client_net_address') AS client_net_address
However it returns null for the fields local_net_address and local_tcp_port.
My questions are:
- Is it normal to have a null value for the ip address fields?
- Is there a way to fix this? (Aside from using the server name for my connection)
Thank you in advance.
add a comment |
I am trying to connect via Android Studio to a SQL Server database using jtds. The type of instance I'm using is a standalone.
In order to establish a connection, I am using the following statement:
Connection DbConn = DriverManager.getConnection("jdbc:jtds:sqlserver://**ip_adress:port**/**my_db**", un, pass);
I have tried retrieving the value of the IP address by launching the following query:
SELECT
CONNECTIONPROPERTY('net_transport') AS net_transport,
CONNECTIONPROPERTY('protocol_type') AS protocol_type,
CONNECTIONPROPERTY('auth_scheme') AS auth_scheme,
CONNECTIONPROPERTY('local_net_address') AS local_net_address,
CONNECTIONPROPERTY('local_tcp_port') AS local_tcp_port,
CONNECTIONPROPERTY('client_net_address') AS client_net_address
However it returns null for the fields local_net_address and local_tcp_port.
My questions are:
- Is it normal to have a null value for the ip address fields?
- Is there a way to fix this? (Aside from using the server name for my connection)
Thank you in advance.
1
https://docs.microsoft.com/en-us/sql/t-sql/functions/connectionproperty-transact-sql?view=sql-server-2017Clearly says in the Remarks... "local_net_address and local_tcp_port return NULL in SQL Database." Have you tried from the command prompt:Ping SqlServerName
– WEI_DBA
Mar 6 at 19:08
Thank you. Yes I managed to establish a connection by retrieving the IP address through ping. It was as simple as that!
– Eddy Sawaya
Mar 7 at 19:20
add a comment |
I am trying to connect via Android Studio to a SQL Server database using jtds. The type of instance I'm using is a standalone.
In order to establish a connection, I am using the following statement:
Connection DbConn = DriverManager.getConnection("jdbc:jtds:sqlserver://**ip_adress:port**/**my_db**", un, pass);
I have tried retrieving the value of the IP address by launching the following query:
SELECT
CONNECTIONPROPERTY('net_transport') AS net_transport,
CONNECTIONPROPERTY('protocol_type') AS protocol_type,
CONNECTIONPROPERTY('auth_scheme') AS auth_scheme,
CONNECTIONPROPERTY('local_net_address') AS local_net_address,
CONNECTIONPROPERTY('local_tcp_port') AS local_tcp_port,
CONNECTIONPROPERTY('client_net_address') AS client_net_address
However it returns null for the fields local_net_address and local_tcp_port.
My questions are:
- Is it normal to have a null value for the ip address fields?
- Is there a way to fix this? (Aside from using the server name for my connection)
Thank you in advance.
I am trying to connect via Android Studio to a SQL Server database using jtds. The type of instance I'm using is a standalone.
In order to establish a connection, I am using the following statement:
Connection DbConn = DriverManager.getConnection("jdbc:jtds:sqlserver://**ip_adress:port**/**my_db**", un, pass);
I have tried retrieving the value of the IP address by launching the following query:
SELECT
CONNECTIONPROPERTY('net_transport') AS net_transport,
CONNECTIONPROPERTY('protocol_type') AS protocol_type,
CONNECTIONPROPERTY('auth_scheme') AS auth_scheme,
CONNECTIONPROPERTY('local_net_address') AS local_net_address,
CONNECTIONPROPERTY('local_tcp_port') AS local_tcp_port,
CONNECTIONPROPERTY('client_net_address') AS client_net_address
However it returns null for the fields local_net_address and local_tcp_port.
My questions are:
- Is it normal to have a null value for the ip address fields?
- Is there a way to fix this? (Aside from using the server name for my connection)
Thank you in advance.
edited Mar 6 at 18:57
marc_s
581k13011211268
581k13011211268
asked Mar 6 at 18:45
Eddy SawayaEddy Sawaya
61
61
1
https://docs.microsoft.com/en-us/sql/t-sql/functions/connectionproperty-transact-sql?view=sql-server-2017Clearly says in the Remarks... "local_net_address and local_tcp_port return NULL in SQL Database." Have you tried from the command prompt:Ping SqlServerName
– WEI_DBA
Mar 6 at 19:08
Thank you. Yes I managed to establish a connection by retrieving the IP address through ping. It was as simple as that!
– Eddy Sawaya
Mar 7 at 19:20
add a comment |
1
https://docs.microsoft.com/en-us/sql/t-sql/functions/connectionproperty-transact-sql?view=sql-server-2017Clearly says in the Remarks... "local_net_address and local_tcp_port return NULL in SQL Database." Have you tried from the command prompt:Ping SqlServerName
– WEI_DBA
Mar 6 at 19:08
Thank you. Yes I managed to establish a connection by retrieving the IP address through ping. It was as simple as that!
– Eddy Sawaya
Mar 7 at 19:20
1
1
https://docs.microsoft.com/en-us/sql/t-sql/functions/connectionproperty-transact-sql?view=sql-server-2017 Clearly says in the Remarks... "local_net_address and local_tcp_port return NULL in SQL Database." Have you tried from the command prompt: Ping SqlServerName– WEI_DBA
Mar 6 at 19:08
https://docs.microsoft.com/en-us/sql/t-sql/functions/connectionproperty-transact-sql?view=sql-server-2017 Clearly says in the Remarks... "local_net_address and local_tcp_port return NULL in SQL Database." Have you tried from the command prompt: Ping SqlServerName– WEI_DBA
Mar 6 at 19:08
Thank you. Yes I managed to establish a connection by retrieving the IP address through ping. It was as simple as that!
– Eddy Sawaya
Mar 7 at 19:20
Thank you. Yes I managed to establish a connection by retrieving the IP address through ping. It was as simple as that!
– Eddy Sawaya
Mar 7 at 19:20
add a comment |
0
active
oldest
votes
Your Answer
StackExchange.ifUsing("editor", function ()
StackExchange.using("externalEditor", function ()
StackExchange.using("snippets", function ()
StackExchange.snippets.init();
);
);
, "code-snippets");
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "1"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55030143%2fsql-server-2017-ip-address-is-null%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
0
active
oldest
votes
0
active
oldest
votes
active
oldest
votes
active
oldest
votes
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55030143%2fsql-server-2017-ip-address-is-null%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
1
https://docs.microsoft.com/en-us/sql/t-sql/functions/connectionproperty-transact-sql?view=sql-server-2017Clearly says in the Remarks... "local_net_address and local_tcp_port return NULL in SQL Database." Have you tried from the command prompt:Ping SqlServerName– WEI_DBA
Mar 6 at 19:08
Thank you. Yes I managed to establish a connection by retrieving the IP address through ping. It was as simple as that!
– Eddy Sawaya
Mar 7 at 19:20