Forum Replies Created

Viewing 15 posts - 2,476 through 2,490 (of 13,460 total)

  • RE: Script to list all tables and columns involved in Stored Procedure

    take a look at this DMV, and run this in the database you think has external references:

    i think this view is supposed to populate with values, even if the object...

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: Linked Server.

    the screenshot i provided is an example of where the only people using the linked server are explicitly defined in a list; my sa example int he first like is...

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: Cannot access default instance set up by previous owner of computer

    for non clustered instances, these two techniques are working great for me, as long as i have RDP to the machine:

    without stopping and starting the services, byusing sysinternals psexec to...

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: Nearest match, is this possible ?

    are you sure?

    based on the error, i'd think thatthe columns for

    dbo.postcodes.Latitude and dbo.postcodes.Longitude

    are being converted to match the data type for @Radians(float)

    are they possible decimals or varchars?

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: Nearest match, is this possible ?

    I have a couple of examples saved in my snippets.

    here's an example of finding points that are within 5 US Miles; you can change the constants to be in kilometers...

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: Linked Server.

    check each of your linked servers, and make sure the option for this part is "not be made" or "be made using the logins current security context" if you are...

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: Should each SQL Server service have its own domain account?

    i can't say which is a best practice, but i'll throw out what strategy we use.

    for startup services, we create a domain account mydomain\SQLMaster, and that is the user used...

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: Check dependencies before creating function

    yes you can, but you'll have to use dynamic SQL to hold the command for creating the functions/procedures.

    IF EXISTS(SELECT 1 FROM sys.columns WHERE object_Name(object_id) = 'CriticalTable' and name = 'SpecificColumn')

    ...

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: Need to automatically add a custom server role to any login created

    probably we'll need more information.

    creating server roles is available in 2012 and above, you probably mean "if i add a login, i want to add him to a server role(or...

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: trigger to audit

    the other question i'd like to see thrown into the mix is what do you REALLY need to track?

    do you really need to know that Lowell modified these x rows,...

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: Denying DML operations from another server

    SQLHeap (2/24/2014)


    SQLRNNR (2/24/2014)


    The best method for that is to have the prod database servers segmented away from the dev servers via firewall/router. Then have firewall rules preventing access between...

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: Denying DML operations from another server

    SQLHeap (2/24/2014)


    So, I have this developer that created a job on a dev server that executes a number of ssis packages that I handed over and he/she didn't change any...

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: how to run xp_cmdshell via .NET App using non SYSADMIN role

    yocki (2/23/2014)


    Dear masters,

    I have a stored procedure (SP) that contains "EXEC xp_cmdshell eror msg >>D:\logfile.txt, no_output"

    Whenever i call/run the SP, via .NET App and SSMS directly, using user that...

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: sp_defaultdb and other procs available to public?

    while a user might be able to see system procedures, they can't do anything with them due to permissions;

    it's easy to test, just create a user.

    create user ClarkKent without login

    execute...

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: Cross table like cartesian product.

    images are blocked at work, but a cross join is pretty easy

    SELECT T1. *, T2.*

    FROM myTable T1

    CROSS JOIN MyTable T2

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

Viewing 15 posts - 2,476 through 2,490 (of 13,460 total)