1,901 reputation
321
bio website movingsql.com
location New Jersey
age 56
visits member for 2 years, 6 months
seen yesterday
coder & programmer of many defunct languages...

Oct
24
comment Getting error creating database in SQL Server 2005
You say, "Our shop uses a trigger mechanism to create database". Please describe this in more detail. If possible, add the trigger's code to your post.
Oct
23
comment Seeing multiple CXPACKET blocks when trying to load data from a INSERT SELECT
Try setting MAXDOP to 1. That should prevent any parallelism.
Oct
6
comment How to add a default null row if no results from the dynamic pivot query
Even if there are no rows, a result set with defined columns is still returned to your application. Your application should be displaying the column headers even if there are no rows.
Oct
6
comment Defining a column as nullable in a view (but not in the referenced table)
+1: It's worth noting that there are some restrictions with this approach: 1) The changed columns are not writeable in the view, so if the OP's application tries to write to them, it would fail. And 2) the application must not try to distinguish between tables and views. Most apps do not, but annoyingly, some product applications do.
Sep
30
awarded  Explainer
Sep
18
comment Can't see some stored procedures in sys.procedures
Not sure why you posted 100+ lines of unformatted code for us to read, when it's only one four line query that's relevant.
Sep
18
comment How to monitor flat file for changes then run a SQL import job
I assume you mean from within the executing job, for which I am not sure, it's complicated. First thing is to set the Job as being owned by SA. Second thing is to test whether it works in a local folder. If it works locally, but not in the share, then it probably needs the Share/Folder/File settings changed.
Sep
18
revised How to monitor flat file for changes then run a SQL import job
added 884 characters in body
Sep
18
answered How to monitor flat file for changes then run a SQL import job
Sep
18
comment How to monitor flat file for changes then run a SQL import job
How are you going to import the file? What facility are you using for the import?
Sep
17
accepted RESTORE failing with OS error 32, file being used by another process
Sep
16
comment RESTORE failing with OS error 32, file being used by another process
@SeanGallardy Well, it appears that you are correct and I was wrong on multiple counts. First, yes, it does need to list the logical names from the DB in the BAK file. And secondly, yes, I should have checked it more closely, because it failed when I tried that, because the original logical name had been misspelled (NBCC vs NBBC) and though I stared at it, didnt catch the spelling difference. If you can post this as an answer, I will accept it.
Sep
16
comment RESTORE failing with OS error 32, file being used by another process
I know what's in the backup set. It's a backup of a DB with the same name, but different instance and different logical names on the same server. I cannot use the logical file names from the BAK, that results in the error 'NBCC_Logistics_Model2_log' is not part of the NBBC_Logistics database.. The BAK file is of the correct database that I do want to restore over the existing DB. The question is how to get SQL Server to do it.
Sep
16
comment RESTORE failing with OS error 32, file being used by another process
@ShawnMelton No, I have checked for this.
Sep
16
comment RESTORE failing with OS error 32, file being used by another process
@MaxVernon again, as indicated above I have already done that. Nothing else has the BAK file open.
Sep
16
comment RESTORE failing with OS error 32, file being used by another process
@MaxVernon as indicated in the additional notes, I have already checked this. The db files specified are open by the recieiving DB. The file reported by the error message is open by the source DB in another instance on the same server.
Sep
16
comment RESTORE failing with OS error 32, file being used by another process
@ShawnMelton Yes, from a process local to the SQL Server instance. My account has local and domain admins.
Sep
16
revised RESTORE failing with OS error 32, file being used by another process
added 221 characters in body
Sep
16
asked RESTORE failing with OS error 32, file being used by another process
Sep
11
comment Possible to optimize SELECT query involving XQuery functions selecting from elements with arbitrary number of child elements
Have you tried adding an XMLschema?