• SQL Server 2012: CASE statement evaluates all conditions

    Does anyone know if SQL Server 2012 CASE statement evaluates all WHEN conditions or just exits when it finds the first TRUE condition? So basically, if it goes through all of them, then does the last condition overwrite the first condition? Thank you.

    ITKE434,705 pointsBadges:
  • SQL Server: Create table to hold result of stored procedure

    With SQL Server, I usually write a query like this: create table #table_name ( column1 int, column2 varchar(200) ... ) insert into #table_name execute some_stored_procedure; But here's my issue: When creating a table to have the right syntax as the result of the stored procedure is too long of a...

    ITKE434,705 pointsBadges:
  • Create SQL script for insert statements / table having blob data

    How can I create a SQL script for insert statement / table having blob data?

    sushantmane15 pointsBadges:
  • SQL Server: List of column names in a table

    For SQL Server, can I have a list of the names of the columns in my table? Do I have to use a third party product for this? Thank you for all your help.

    ITKE434,705 pointsBadges:
  • Should I use TRUNCATE before DROP in SQL Server?

    Currently in my SQL Server system, I'm working on a ton of stored procedures / SQL scripts that are making use of temp tables. When I'm done with the tables, I usually drop them. This is what I've been using: TRUNCATE TABLE #mytemp DROP TABLE #mytemp So, I usually use DROP TABLE for my scripts but...

    ITKE434,705 pointsBadges:
  • SQL Server: Transaction log is running out of space

    In my SQL Server, my transaction log continues to grow and I'm losing space every minute. Why does it keep growing? Is there a way I can stop this from happening? Thank you very much.

    ITKE434,705 pointsBadges:
  • SQL Server: Restore backup to older version

    I'm restoring a SQL Server 2008 (Express), I keep getting this odd error: Restore failed for Server '...\SQLEXPRESS'. (Microsoft.SqlServer.SmoExtended) System.Data.SqlClient.SqlError: The database was backed up on a server running version 10.50.1600. That version is incompatible with this server,...

    ITKE434,705 pointsBadges:
  • SQL Server: Use N prefix before string

    In SQL Server, should I use the N prefix before string for my Transact SQL query? I'm working with a new database and I'm not getting any results back using this: SELECT * FROM a_table WHERE a_field LIKE '%Š°_pattern%' But, when I add the N prefix before %a_pattern%, it works. Appreciate the help.

    ITKE434,705 pointsBadges:
  • SQL Server: Do I have to create a transaction?

    In SQL Server, I'm wondering if it's not right to always create a transaction. Is it really necessary? This is mainly for when I'm doing an update too. Thank you. I apologize for the short question. Thank you.

    ITKE434,705 pointsBadges:
  • How to spool dynamic filenames from SQL script

    I need to get different file names each time I run the script. How can I do that?

    01129225 pointsBadges:
  • SQL Server: Moving database files

    I currently have a SQL Server database and I need to move several .MDF and .LDF files somewhere else. But I can't stop the SQL Server service and I can't export it to another server too. How can I do this?

    ITKE434,705 pointsBadges:
  • Should I be concerned with SQL Server in-place upgrades?

    Our team is upgrading from SQL Server 2008 to 2012 but we need to use the same hardware. But here's the thing: We're worried bout doing an in-place upgrade and we're on a time crunch. Before we continue, can anyone share any experiences with in-place upgrades?

    ITKE434,705 pointsBadges:
  • Monitor progress of SQL file

    I'm trying to import a pretty large SQL file (roughly 6 GB) to my local database. Here's what I'm using: $ mysql -h localhost -u root 'my_data' < foobar.sql $ mysql --version /usr/local/mysql/bin/mysql Ver 14.12 Distrib 5.0.96, for apple-darwin9.8.0 (i386) using readline 5.1 So, I'm wondering if...

    ITKE434,705 pointsBadges:
  • SQL Server 2012 query errors

    In SQL Server 2012, I'm running several queries but not all of them are working. The first one goes through but not the second. Also, when I try to run it without the WHERE clause, everything fails. The queries are below. Thank you. create table #temp (id int primary key) create table #temp2 (id...

    ITKE434,705 pointsBadges:
  • SQL Server: Document databases

    Over the course of the past month, my department has noticed that several of our clients are not documenting their SQL Server databases and that's making us worried. First off, should we be worried? If so, then what should we do? Thanks!

    ITKE434,705 pointsBadges:
  • SQL Server: Query is filling up TEMPDB database

    I'm using SQL Server and my partner and I need to figure out how we can identify which query / stored procedure continues to fill up our trans log in our TEMPDB database. It's really starting to become an issue. Thank you.

    ITKE434,705 pointsBadges:
  • SQL Server: Insert number of rows into a table

    I have a SQL Server database where I currently upload files into a staging table. On the table, I have 2 JOINs that corrects foreign keys. That's followed by putting these rows into one final table. Right now, there's roughly over 3 billion rows of data. Now here's my question: What's the best (or...

    ITKE434,705 pointsBadges:
  • Restore SQL Server .BAK file and shrink log size at the same time

    I currently have a .BAK file that was sent to us by one of our clients and this was because of an issue the file is having. Our backup is 25 GB and the database is roughly the same size but it actually needs 100 GB to be restored. We think that the database has a 75 GB transaction log size. Can we...

    ITKE434,705 pointsBadges:
  • We have a virtual environment build up recently and we have started facing IO issues and disk perf. issue

    Virtual servers build recently have 4 cores and 16 GB memory on them need to know what is the best baseline for SQL servers as we have started facing IO issues and disk performance issues. Min CPU requirement Min Memory requirement Disk provisioningĀ  - what is recommended thick or thin

    SQLDBA215 pointsBadges:
  • Is cloud just a hype and still not ready to replace on-premise Windows Application and SQL Database Small Server?

    Is Cloud just an 'EARLY BIRD' Hype where Cloud and Internet 4G Technology still not ready to replace "On-premise Windows Application and SQL Database Small Server" in terms of Network Bandwidth Speed and Infrastructure Cost - just to fund IT Giant's R&D and Cloud Marketing activities - when...

    VijithaIvor10 pointsBadges:

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

Thanks! We'll email you when relevant content is added and updated.

Following