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].

Filter by
Sorted by
Tagged with
2 votes
1 answer
1k views

port number of SQL Server

I am wondering what ports are used by SQL Server database engine? I need such port number to write configuration scripts to grant access to specific port of the machine installed with SQL Server to ...
George2's user avatar
  • 1,147
147 votes
9 answers
251k views

How to dump a Microsoft SQL Server database to a SQL script?

Is there any way to export a Microsoft SQL Server database to a SQL script? I'm looking for something which behaves similarly to mysqldump, taking a database name, and producing a single script which ...
Matt Sheppard's user avatar
6 votes
7 answers
35k views

How to rollback a deleted table data?

I have deleted one table accidentally how can I rollback that. Please suggest that.
Simhadri's user avatar
  • 183
2 votes
2 answers
1k views

why would adding a crossover private nic cause IP address resource fail?

2 node Win 2008 R2 quorum cluster Configured 192.168.0.0/24 "public network" Configured cluster MSDTC Installed SQL 2008 R2 cluster instance Manually failover groups - OK Reboot server w/o failing ...
AndyG DBA_ANDY's user avatar
2 votes
2 answers
3k views

SQL Server Remote Connections

I am at my wits end with trying to access a remote SQL Server 2008 R2 Express instance. Here are the following that I have tried. 1) I enabled remote connections in the instance properties. 2) I ...
Barry's user avatar
  • 185
1 vote
4 answers
1k views

Why upgrade from SQL 2005 to SQL 2008 R2?

have been tasked to write a document outlining the best reasons to use SQL 2008 R2 instead of SQL 2005 for my brand new BI project. We have a policy of only using two versions at a time and there are ...
GordyII's user avatar
  • 151
1 vote
2 answers
2k views

Memory Usage of SQL Server

SQL Server instance on my server is using almost full memory available in my Physical Server. Say if i am having 8GB of RAM than SQL Server is using 7.8 GB of RAM from system. I also have read ...
Ashish's user avatar
  • 119
1 vote
1 answer
193 views

SQL- Encryption Database

I have taken backup from the live environment and trying to use it on the local box. The database in the live is encrypted with a key. I have restored the database to localbox and cannot run any ...
Hari Gillala's user avatar
166 votes
10 answers
440k views

GRANT SELECT to all tables in postgresql

Is there a one-liner that grants the SELECT permissions to a new user postgresql? Something that would implement the following pseudo-code: GRANT SELECT ON TABLE * TO my_new_user;
Adam Matan's user avatar
  • 13.6k
32 votes
11 answers
21k views

To improve SQL performance, why not just put lots of RAM rather than having faster hard disks?

People keep telling me that in order to improve an SQL server's performance, buy the fastest hard disks possible with RAID 5, etc. So I was thinking, instead of spending all the money for RAID&...
user1034912's user avatar
  • 1,364
22 votes
6 answers
43k views

Alter charset and collation in all columns in all tables in MySQL

I need to execute these statements in all tables for all columns. alter table table_name charset=utf8; alter table table_name alter column column_name charset=utf8; Is it possible to automate this ...
The Disintegrator's user avatar
18 votes
1 answer
55k views

How do you get the minimum and maximum memory allocation of a SQL instance using T-SQL?

I'm managing about 90 SQL Server instances and need a query to determine how much memory has been allocated to each instance. Please note, I'm not asking how to set it, just to see what it's currently ...
token's user avatar
  • 295
11 votes
3 answers
31k views

mysqldump ignore table with wildcard

I need to take a dump of a database containing 50 odd tables of which I want to exclude about 15 odd that have prefix exam_ I tried mysqldump --ignore-table=dbname.exam_* and even tried --ignore-...
anup's user avatar
  • 727
8 votes
1 answer
3k views

Are vCPU the same as 1 Socket, or a single Core?

Currently I have a Hyper-v VPS with 2 (vCPU) processor. I would like to install SQL Server Express 2012 that has a limitation of 1 Socket or 4 Cores, whichever the lesser. My Question: Are vCPU's ...
TreK's user avatar
  • 257
4 votes
9 answers
3k views

How can I prevent attacks on my SQL Server installation?

In the past month I've noticed in my event viewer on a sql server a lot of failure audits. Seems like a brute force attack from an ip in china trying to log in to the sa account which i have disabled. ...
user avatar
4 votes
0 answers
180 views

What does it mean when Twitter says their entire database is in RAM?

I am wondering where to begin with database scaling/optimization strategies. After reading articles like highscalability.com's facebook architecture article, and this twitter architecture article, I ...
Lance's user avatar
  • 233
4 votes
2 answers
4k views

SQL Clustering or Hyper V Clustering

We will soon be implementing our Dynamics AX installation. Our aim is to have high availability and we are working closely with our implementers. We raised the question to them about SQL and Hyper-V ...
dqnet's user avatar
  • 305
4 votes
4 answers
7k views

A good hostname convention for few servers with many different services?

I am looking at setting up a hostname convention for our servers based on the service they provide, such as http, https, smtp, pop, dns, sql, etc. Each service is on its own virtual machines on a Xen ...
ryanklein's user avatar
4 votes
0 answers
56k views

Cannot telnet to SQL Server on port 1433

I've been working solidly on this issue for the past three weeks. I cannot seem to find where the actual issue is. I just recently found this article on how to troubleshoot the connection. I made it ...
Otacon's user avatar
  • 41
3 votes
2 answers
5k views

Performance azure disks, high average queue length

I'm having a classic developer-system admin battle where I am stating that there is an IO problem on the disk of the shared sql server while the system admin tells me that the capacity hasn't been ...
MichaelD's user avatar
  • 565
3 votes
3 answers
13k views

Can I change a live SQL Database from Autogrow safely?

I have a live SQL 2005 database, and am in the very unfortunate position of being the involuntary DBA. The database has an MDF file that is 1.4 GB, and an LDF with 2.2 GB. The Autogrowth is set to ...
aSkywalker's user avatar
2 votes
3 answers
14k views

Add the current admin user to SQL Server Express 2008

I have managed (in 'eksperiments') to remove both my Windows users from my SQL Express instance. I am now logged in as windows admin, and have re-created the corresponding SQL login, but I cannot ...
ProfK's user avatar
  • 493
1 vote
3 answers
479 views

How do I change the system wide collation setting in SQL Server 2005

I've got a recently upgraded SQL Server which I'm getting ready to put live, we've gone from SQL Server 2000 to SQL Server 2005. The collation setting on the 2005 box is different though (I didn't do ...
Robin's user avatar
  • 827
1 vote
1 answer
573 views

Failed to check share space via recorded path form sql database by powershell

Could anybody tell me why I failed on these code? 1, I connect to database 2, I query useful information from database (get path) 3, I checked the free space under queried path Here are my codes: #...
pansal's user avatar
  • 269
1 vote
2 answers
194 views

Many huge files in Sharepoint... Any "stubbing" or "shortcutting" software exist?

I'm in an industry that uses a lot of scanned documents and large attachments (100MB), and I see our Sharepoint database growing quickly. What options do I have for managing this rapid growth? Can ...
makerofthings7's user avatar
1 vote
5 answers
4k views

Move MySQL DB to another server

I have server with very big mysql database (160GB). How easy way to move this DB to another server?
ghkaren's user avatar
  • 123
1 vote
3 answers
2k views

Sql Server management studio 2005 cant connect to localhost using windows authentication

I am trying to localhost using windows authentication with SQL Server management studio and I am getting a message that "Login failed for user..." (Error 18456). I made sure that all the services are ...
Derek's user avatar
  • 191
1 vote
2 answers
4k views

SQL Server variable size and increase it

It is not clear to me how a varchar(max) is declared or used in an SQL Server e.g. 2005 Is a variable declared as varchar(300000) for example considered as a varchar(max)? E.g. I am seeing in a DB in ...
user76678's user avatar
  • 349
0 votes
1 answer
449 views

SSMS 2008 - Can't Add Maintenance Plans

Trying to save a new Maintenance Plan using SSMS 2008 and receiving error: Apply to target server failed for Job 'DB Backup.createDBBackup' The connection has been verified. Is [dbo].[...
Alex's user avatar
  • 103
0 votes
2 answers
291 views

The Transactional Log is Full

I am getting below error. The transaction log for database 'CRM_QA_V6' is full. To find out why space in the log cannot be reused, see the log_reuse_wait_desc column in sys.databases likely ...
user avatar
0 votes
1 answer
253 views

SQL authentication not authenticating in MS SQL Server 2008

When I try to connect to the SQL Server running on localhost using Windows Authentication in SQL Server Management Studio, I am able to connect but when I try to connect using SQL authentication, it ...
Arunabh Das's user avatar
0 votes
1 answer
408 views

Remote mysql server?

I'm trying to make a remote mysql server on my computer. I know this isn't a wise thing to do, but I'm trying it out anyway. I'm not sure of the steps to complete here, but maybe someone can fill them ...
user avatar
0 votes
1 answer
8k views

what is the difference between SQL and ANSI SQL?

what is the difference between SQL and ANSI SQL?
user48642's user avatar
  • 289
0 votes
5 answers
774 views

Is blocking all traffic to MySql port, EXCEPT from own server IP, a good security measure?

As the title says, would this help? Imagine a classifieds website, where users simply login, logout, post classifieds, delete classifieds etc... All with PHP and mysql. I have my own server, with ...
Anonymous12345's user avatar
0 votes
2 answers
985 views

How To Find Reasons of Why Site Goes Online/Offline

Seems today a website I manage has been going online and offline throughout the entire day. I have no idea what is causing the issue so I am seeking guidance on where to start. It is a Wordpress based ...
Zach Smith's user avatar
0 votes
1 answer
2k views

Are there simple command line tools to decode a SQL Injection request string? [closed]

My web server periodically comes under attack, and I get a bunch of requests that look like /my.page?union+all+select+0x31303235343830303536%2C0x31303235343830303536%2C0x31303235343830303536-- Are ...
chris's user avatar
  • 4,003