Questions tagged [sql]

Database language for managing data in relational database management systems (RDBMS). Note that each database implements SQL with slight variations. Please remember to tag with your specific database as well, e.g. [mysql], [postgres], [mssql], or [oracle].

An abbreviation of "Structured Query Language," SQL is a database language used to manage data in relational database management systems.

Due to many vendor implementations of SQL (such as T-SQL for SQL Server & Sybase, PL/SQL for Oracle and PostgreSQL and MySQL) it is a fractured language and syntax that works with one vendor may not work with another.

1284 questions
3
votes
2 answers

How can UTF 8 encoding in a varchar field be transfered to an nvarchar field?

The UTF-8 characters (nearly a million records) were imported into varchar(max) as western european. Is there any known method of fixing this in SQL? We have verified that the "garbage" characters that are showing up are, in fact, based on the…
3
votes
3 answers

How to set sort(1) to use a custom collation?

I have a text file containing one record per line which I'd like to sort alphabetically, except that I want '-' to sort after '[' and ']'. (The natural sort order has '-' before the square brackets.) Is there a way to modify the collation that…
uckelman
  • 183
  • 5
3
votes
3 answers

SQL Server 2008 R2 Developer Editon

I have a basic question. Is the SQL Server 2008 R2 Developer Edition same as SQL Server 2008 Developer Edition? Why does the Microsoft sites return 2008 pages while browsing when looking for R2 editions? Regards, Nandagopal
user59935
  • 31
  • 1
3
votes
3 answers

Running Windows Server 2008 Web Edition in a VM

We are planning to run an Intranet site on Windows Server 2008 Web Edition. The site will also use SQL Server 2008 Express, installed on the same virtual machine. We are using VMWare Server to host the VM. The web server will be running EPiServer…
saille
  • 327
  • 4
  • 13
3
votes
3 answers

How to simlify MS SQL server database restore?

I have to restore various SQL server databases several times a day (for development purposes). In SSMS interface it takes forever and it is even longer to type RESTORE DATABASE command with all it's paths. Ideally I would like to double-click a BAK…
Ross
  • 133
  • 3
3
votes
2 answers

SQL server 2005 attach without transaction log - urgent !

We had a crash in the sql server and the database remained in inconsistent mode. We lost the transaction log file and the last generated backup is too old. I googled this issue but mostly relevant posts I saw refer to SQL 2000 I saw this…
user51361
  • 131
  • 3
3
votes
6 answers

how do i automatically back up my sql server database every month?

i have a sql server 2005 database without around 100 tables. i need to back it up every month. is there a way to automate this process? how would i do it? i am a newbie so please explain thoroughly if it is a stored procedure please let me know what…
Alex Gordon
  • 455
  • 3
  • 14
  • 31
3
votes
2 answers

Database mail won't send emails

I am trying to setup database mail in ms sql 2005. I setup but everytime I try to send a msg through their email tester it fails and I get this msg. Date 7/7/2010 10:54:12 AM Log Database Mail (Database Mail Log) Log ID 48…
chobo2
  • 461
  • 1
  • 10
  • 18
3
votes
4 answers

Mistakenly ran an update statement on table

We have mistakenly ran an update statement on one of our Columns in a SQL table. We don't have a backup of the table nor the database. Can any one help us to retrieve the values of the Column before the update.
Dasharath Yadav
3
votes
2 answers

NetApp and SQL Server?

Do you have any good or bad experiences to share running SQL Server OLTP Systems on NetApp appliances? I have been working with a small, relatively low-volume cluster with a lower-end NetApp device, and I have found the environment to be generally…
Edinor
  • 173
  • 6
3
votes
4 answers

SQL Monitoring Overview

I currently loook after 20 odd databases in SQL server 2005 and need a tool for monitoring the performance and keep me informed if a database is running slow. Is there anything I can run within Managment studio of any other good third party tool…
Andy
  • 199
  • 1
  • 6
3
votes
4 answers

Upgrade SQLServer 2008 hardware

Forgive me if I'm not able to be totally clear here. It is not intentional, I'm a senior level developer in a very small company having to act like a manager at the moment. Anyway, the story is that we have 2 older dell servers with SQL Server 2008…
John
  • 177
  • 1
  • 7
3
votes
2 answers

Command line scripts to restore the 4 system databases of MS SQL Server 2008

can someone give me some advice on how to restore the 4 system databases (master, msdb, model, tempdb) of a sql server 2008 please? I've already done some testing myself (on restoring the master database) with the following commad line script as a…
ciscokid
  • 53
  • 3
  • 7
3
votes
4 answers

MySQL asking a user for SUPER privilege to perform a delete

When trying to do a delete operation on a table, mysql reports the following error: Error code 1227: Access denied; you need the SUPER privilege for this operation. However, my user has this privilege granted for all tables in the schema: GRANT…
scetoaux
  • 1,289
  • 2
  • 12
  • 26
3
votes
2 answers

PostgreSQL deleteing old records from log tables

I have a PostgreSQL database which stores my RADIUS connection information. What I want to do is only store a month worth of logs. How would I craft an SQL statement that I can run from cron that would go and delete and rows that where older than…
Max