Forum Replies Created

Viewing 15 posts - 3,256 through 3,270 (of 13,460 total)

  • RE: Will CE 3.5 hold a few million records?

    well, who in your company has a windows handheld device, vs having an android or iphone/ipad? in my shop of 30 developers, there are no windows based portable devices.

    I would...

    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 automate report from sqlserver to be sent on email everyday.

    it depends on the "report"

    Since you said it's a query, i assume you must be running it, copying it into an excel or something, and email it?

    or formatting as HTML?

    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: Permission to run only certain SQL jobs in 2008

    here's a classic example of what J Good is talking about;

    the proc below runs under elevated priviledges, so i can grant a normal user EXECUTE ont eh procedure to allow...

    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 some help with retrieving correct Device IP Address

    i have always converted IP's to big ints so that i could do cmparison and ranges;

    something like this in your table setup can help:

    DECLARE @IPInfo TABLE

    (

    MachineId int NOT NULL,

    IPAddress varchar...

    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: Get the Foreign Key Hierarchy

    for a single table, i have this saved from Jason's website(the guy who posted before you

    --http://jasonbrimhall.info/2011/07/11/foreign-key-hierarchy-update/

    --SET XACT_ABORT ON

    --BEGIN TRAN

    DECLARE@StartParentTableVARCHAR(256)

    SELECT @StartParentTable = 'GMACT'

    ;With Hierarchy (ParentTable,ParentColumn, ChildTable,ChildColumn, FKLevel, SortCol)...

    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: Find the correct answer in the following query

    also, modify Kingstons' execellent example with this:

    INSERTsalesorder

    SELECT3 UNION

    SELECT NULL

    and the query will return nothing, because the IN() list must be all non null values, otherwise, nothing gets returned.

    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: Restore Database if Job fails

    it depends on why the job fails i guess;

    one possibility might be to have the job use SET XACT_ABORT ON, and put it in a transaction; then if an error...

    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: Why is this Query Taking a long time?

    well, the NOLOCKS bother me enormously, it is not a magic "go fast" button for SQL, it has a lot of dark ramifications like missing or duplicate data.

    as far...

    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 assistance with a query

    RPSql (6/18/2013)


    Is there a way to structure a single query to select all the unique values from field 1 of table A, and the unique values from field 2 of...

    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: Creating Table for Pivot Table

    if you know there is a maximum number of distributores, it's pretty easy; for example, this would assume a max of five distributora records:

    WITH CTE AS (

    SELECT customer#, customername,

    ...

    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 make trigger

    I don't think you've provided everything you need, anyway;

    i don't see any relationship for the table [pstatus] table to your [patient] table.

    your [patient] table should have separate fields for firstname/middle...

    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: can anyone give me tips how to use powershell with respect to sql server 2008

    wow an awfully broad subject there;

    take a look at the forum dedicated to Powershell and SQL server here

    from there, you can see there are broad categories of uses, but one...

    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: If/Then in table valued functions

    can you return a case statement instead?

    SELECT

    CASE WHEN @param1 = 1 THEN 1 ELSE THEN 3 END as column1,

    CASE WHEN @param1 = 2 THEN 2 ELSE THEN...

    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 set a value for a column

    details or ddl wasn't available, so here's my best guess.

    is the trigger setting values on the table is is set for, or a completely different table ("Audit")?

    because you...

    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 identify which user is running query and how long is it running?

    grab a copy of sp_whoisactive here:

    http://sqlblog.com/blogs/adam_machanic/archive/2012/03/22/released-who-is-active-v11-11.aspx

    from there, you need to look at the parameters, but for example running this:

    EXEC sp_whoisactive

    @show_own_spid =1,

    @show_sleeping_spids =1

    will show me a...

    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 - 3,256 through 3,270 (of 13,460 total)