Forum Replies Created

Viewing 15 posts - 10,291 through 10,305 (of 13,460 total)

  • RE: Verboten keywords to assure SELECT only commands

    Jeff Moden (11/25/2009)


    dba_pkashyap (11/25/2009)


    How about DDL triggers at database level!!!

    I'm liking that but can't you just set the users up with "data reader" only?

    i wish (sigh)

    there is no access/no control...

    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 can user script out table in SSMS without permissions to change the schema.

    Rodney i was able to recreate the error for tables that contain a default value, you are right.

    a bandaid i found that works was to go to master and run...

    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 can user script out table in SSMS without permissions to change the schema.

    wierd Rodney; I tried to duplicate your steps,but I AM able to use the script as function in SSMS when i login as my test user. i wonder why it...

    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: Verboten keywords to assure SELECT only commands

    ok here's another idea...besides the planned filtering, what if the application started a transaction, ran the script, and then rolled back the transaction?

    if it was a valid SELECT statement, no...

    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: Verboten keywords to assure SELECT only commands

    with regex, i can use word boundaries, so UPDATE would be a match, but UPDATEDDT would not. same with EXEC/EXECUTE vs a word that contains the keyword.

    I'm going to play...

    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: Verboten keywords to assure SELECT only commands

    Thanks Gsquared, your idea would work if i had control of the database.

    imagine if i gave you an application: you download it, put in your connection info at your...

    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: Giving backup & Restore access to user having read,write permission

    we have a third party database on our server, and if an issue is found in thier application, they often need a backup of the database to diagnose.

    I simply created...

    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: Synonym for Db

    nope, sorry; synonyms are for Objects...Tables, Views, Stored procedures, functions, etc.

    you can make a synonym for a table on db1.databasename.dbo.tablename, but not the server, database nor schema.

    you could use...

    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: Return Type in Stored Procedure

    it's his variables...he declared them up at the top, then lost the @ in the rest of the script:

    @STARTUP_TIME datetime OUTPUT,

    @SHUTDOWN_TIME datetime OUTPUT

    if he replaces his STARTUP_TIME with @STARTUP_TIME ,...

    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: Return Type in Stored Procedure

    I'd suggest trying to comment your code and use indenting to help you more easily identify syntax issues like this;

    i try to put a comment after every END so I...

    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: Error handling in 2K8

    this is how i thin k it needs to be written...somewhere near the end you are calling your audit proc, but not passing the values...i think that's the issue.

    also, your...

    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: Error handling in 2K8

    pretty sure the issue is that the error is raised BEFORE the procedure is executed.

    like you identified, when the compiler tries to send 'asbc' to an integer datatype, it raises...

    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: Stock Control in SQL Products Table

    bkirk (11/22/2009)


    So if i understand this correctly...

    Are you saying that your Products table does not actually need a column for Stock Count?

    yes that is exactly correct. the Products table...

    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: Stock Control in SQL Products Table

    don't know how others do it, but I've used an updatable view. the view is basically the main products table, which is joined to a group by/subquery of the "ProductReceived"...

    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: sql query question

    this is an excellent question that trips up a lot of people.

    try both of these queries and see the results should be different:

    select * from table a

    left outer join table...

    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 - 10,291 through 10,305 (of 13,460 total)