Viewing 15 posts - 4,546 through 4,560 (of 7,191 total)
i am running the above query in SQLDeveloper tool.
What happens if you run it in SSMS? Also, that error message does not look like one generated by SQL Server....
April 27, 2012 at 1:49 am
Have two ForEach loops - one for txt files, and one for Excel files.
John
April 26, 2012 at 4:00 am
I'm guessing one or more of your databases have a case-sensitive collation. The name of the INFORMATION_SCHEMA schema and the views within it are upper case.
John
April 26, 2012 at 3:37 am
What errors are you getting?
Actually, I would urge you not to split the dates into their constituent parts. Store them in the database as datetime, and perform any manipulation...
April 26, 2012 at 3:16 am
You can get the most recent backup file for each database like this:
SELECT
r.DBName
,r.type
,r.BackupStart
,s.backup_finish_date
,s.backup_size
,m.physical_device_name
FROM ( --gets most recent of each type of backup for each DB
SELECT
d.name AS DBName
,b.type
,max(b.backup_start_date) AS BackupStart
FROM master.dbo.sysdatabases...
April 25, 2012 at 8:38 am
Are you backing up with a maintenance plan? The file name contains a time and date stamp, so it will be different every time.
John
April 25, 2012 at 7:57 am
Can you temporarily comment out the INSERT part of the script to see what you are trying to insert? You could be attempting to insert more than one row...
April 24, 2012 at 7:57 am
Please will you post your INSERT statement and the error message.
Thanks
John
April 24, 2012 at 7:33 am
dwain.c (4/24/2012)
I hope you realize I wasn't really trying to poke fun at your arguments.
Of course I do. A good debate is a good debate, and if we can...
April 24, 2012 at 6:54 am
dwain.c (4/23/2012)
I wouldn't say calculating the 'of x' part of the ranking is messy at all.
All that casting from int to to varchar looks messy to me - that's all...
April 24, 2012 at 1:56 am
Are you saying you just want to add "of x" to the Rank column, where x is the row count for the city in question? Do you want to...
April 23, 2012 at 8:26 am
Backups can be set to expire - this is when the backup set can be overwritten with a new one. The maintenance cleanup task is different - it deletes...
April 23, 2012 at 7:59 am
When you say you've had no luck, do you mean you got an error message, or did you get the wrong results? What did you try? Here's a...
April 23, 2012 at 6:45 am
Try this: http://www.sommarskog.se/dynamic_sql.html
John
April 23, 2012 at 6:14 am
http://msdn.microsoft.com/en-us/library/ms188001.aspx
If you want more detailed help, post the code and post the error messages.
John
April 23, 2012 at 4:28 am
Viewing 15 posts - 4,546 through 4,560 (of 7,191 total)