2
votes
0answers
403 views

SQL Server 2008: NULL SID for WINDOWS_USER in sys.database_principals

Has anyone ever seen anything like this before? I have a WINDOWS_LOGIN AD user that has a record in sys.server_principals with a SID and can login fine. But in a few databases, they have a record in ...
3
votes
2answers
4k views

SQL Server 2008: The database [dbName] is not accessible

I got this error from another person and I've run out of ideas. I can access this database without any problems, the database is in MULTI_USER mode, the person receiving the error is a user, etc. The ...
3
votes
1answer
63 views

What does this code do?

I found one of my queries was over written with following code: SELECT cp.objtype AS ObjectType, OBJECT_NAME(st.objectid,st.dbid) AS ObjectName, cp.usecounts AS ExecutionCount, ...
4
votes
4answers
355 views

Can I reorganise index on a sql server 2005 database without performance hit on production server

I would have preferred to run online index rebuild instead but our production sql server (2005) is standard edition. Hence I think I am left with reorganising index and update statistics after that. ...
3
votes
2answers
59 views

Should I put followers_no & following_no & product_no & last_login and etc in the user table? Won't updates cause fragmentation on the table?

I have a table for users in a social networking site. I want it to be efficient from ground up. If I put mentioned fields on the table then I have to update user's table on each changes. Should I have ...
1
vote
1answer
4k views

How do I find out the “redo log file max size” in Oracle 11R2

I'm working with Oracle 11R2 and I want to see the max size of my redo log files (I didn't install Oracle so I'm not aware of the configuration). I have searched the Internet but all I have found ...
2
votes
1answer
231 views

How do I allow remote connection in SQL Server 2008 Express

I've just installed SQL Server 2008 Express. But when I try to connect to database engine via SQL Server Management Studio I get "A network-related or instance-specific error occurred while ...
1
vote
0answers
68 views

Log Shipping Monitor Stored Procedure returning Null

I have log shipping setup. When I EXEC sp_log_shipping _monitor it returns all null values even though log shipping appears to be working fine. last_restored_file NULL last_copied_file NULL
1
vote
1answer
373 views

SQL Server 2008 DB size grown huge

I am a .net developer and not a expert in database. I have a application running with SQL server 2008. Yesterday there was issue with a certain query getting executed in infinite loop and which caused ...
0
votes
1answer
185 views

SQL Server 2008 Database growth issue.

I am a .net developer and not an expert database administrator. I have an application running on SQL server 2008. Yesterday there was an issue with a certain query getting executed in an infinite ...
3
votes
1answer
2k views

PostgreSQL 9.1 vs MySQL 5.6 with InnoDB ? Which is better for scaling?

PostgreSQL 9.1 vs MySQL 5.6 with InnoDB. I do know that PostgreSQL offers better SQL features. I am currently using MySQL 5.6 lab release (the one with InnoDb full text search feature)(not in ...
3
votes
1answer
410 views

How to break out of error loop in transactional replication?

I was running some simple tests on a publisher and subscriber on the same instance: I inserted 50,000 rows into a published article and the data was correctly pushed to the subscriber. I ...
3
votes
2answers
360 views

Are these MySQL queries efficient?

It took me quite a while to learn how to deal with timestamps in MySQL and I think I accomplished my goals, but I want to double-check two things: 1) Are these doing what I expect 2) Are there ...
2
votes
4answers
241 views

Oracle hint failure

When I run the PL/SQL block after the CREATE statement, I receive the duplicate key error I would expect if I did not add the hint. Any ideas to why the hint does not work? CREATE TABLE Sandbox.Clue ...
2
votes
3answers
5k views

Questions about handling NULLs and empty strings in nvarchar and numeric fields

I understand that questions similar to these pop up often around here. I have searched before posting these but I didn't find any QA threads that completely answer my questions. In a table, I ...
2
votes
1answer
330 views

Copy database fails while trying to copy login

I'm trying to copy a database from a server that lives in a unique domain, call it AMCO. The destination server, which is on domain BCO, is running sql server agent, and as far as I can tell ...
3
votes
1answer
1k views

SQL Server 2012 is putting [brackets] around Table and Column Names

Is there anyway to turn that off? I'm unable to find anything in options, and they're really a distraction.
2
votes
2answers
2k views

How to detect compatibility errors - SQL Server 2012

I am changing a database's compatibility mode from 90 (SQL Server 2005) to 110 (SQL 2012) and I am wondering at what point would I see errors from breaking changes if there are any. I ran Upgrade ...
3
votes
1answer
1k views

Atypical problem with ORA-01445

I have problem with following query Q1: SELECT ADDRESS.STREET FROM MYSALES.MYADDRESS ADDRESS INNER JOIN MYSALES.MYCOUNTRY MCOUNTRY ON MCOUNTRY.MYCOUNTRY_ID = ADDRESS.MYCOUNTRY_ID INNER JOIN ...
4
votes
1answer
430 views

Partition Key questions in SQL Server 2008

We are planning to use table partitioning for our database based on an integer column. I have read about it on MSDN at http://msdn.microsoft.com/en-us/library/ms190787.aspx and have few queries. a) ...
1
vote
1answer
356 views

compare/sync databases from different computers

I have a server online and I have installed MySQL and database A server on it. I also have mysql installed on my local computer and have a copy of database A on it. I want to compare the contents ...
8
votes
1answer
599 views

Why are there Victimless Entries on the Deadlock Graph?

I am trying to learn how to analyze SQL Server 2008's deadlock graph, and I'm finding alot of entries with an empty <victim-list> node. I don't understand what these entries represent: if there ...
7
votes
2answers
1k views

SQL Server 'Create Database' statement. How to inherit autogrowth settings?

I am using SQL Server 2008 R2 and creating databases through continuous deployment. In our system, the default 1Mb/10% autogrowth settings in SQL Server work badly with our data. Particularly as we ...
1
vote
1answer
1k views

Why I cannot let EXPLAIN update statements?

I can imagine that it's actually more important to explain SELECT statements, but I wonder why there's no possibility to use EXPLAIN on UPDATEs/INSERTs. I may use a WHERE-statement in an UPDATE where ...
2
votes
1answer
65 views

Should Crystal Report be allowed for certain employees for production database?

I am talking about production database. There are couple of people who use crystal on daily basis for various types of reports. Some use it to just peak at the data, other generate reports of it. ...
1
vote
2answers
223 views

PostgreSQL : Is this because of locks(row level)?

I have a table with approximately 2.1 million tuples. Which has latitude and longitude columns. I am trying to convert this into a geographic type (point with SRID). The function(procedure) I have ...
2
votes
0answers
128 views

CREATE ASSEMBLY - EXCEPTION_ACCESS_VIOLATION

I am trying to create an assembly on my SQL Server 2005 server. Here is what I am using: CREATE ASSEMBLY [SQLCLRTest] AUTHORIZATION [dbo] FROM 'path\to\my\file.dll' WITH PERMISSION_SET = ...
2
votes
1answer
1k views

sp_execute expects parameter '@handle' of type 'int'

I'm trying to check in a stored procedure if a table exists in my destination database. If it does not then I will create the table useing the information_schema tables from the source database. ...
1
vote
2answers
485 views

COUNT with set DIFFERENCE and UNION

Fairly simple question that I can't seem to find an answer to - I'm working with unions and differences, and I would like to perform a COUNT on the results. Currently I'm having to pipe out to a file ...
1
vote
1answer
482 views

Merge replication - can't create snapshot – timeout

I have a SQL Server 2008 database, and I need a merge replication because I want to sync with mobile devices afterwards. So I created a replication but when it comes to start the snapshot agent, the ...
1
vote
1answer
66 views

Verify if I can use a given directory

Admin creates an Oracle directory: CREATE OR REPLACE DIRECTORY EXAMPLE AS '\\server\share\test'; GRANT READ, WRITE ON DIRECTORY EXAMPLE TO JOHN; Admin can test whether the directory exists: SELECT ...
2
votes
2answers
1k views

DB2 LOAD data into table - Interpreting the error messages

I encountered some constraint issues when loading data from file into table ** SQL3109N The utility is beginning to load data from file "xag". SQL3500W The utility is beginning the "LOAD" phase at ...
1
vote
3answers
408 views

single select vs multiple selects using limit and offset

Working on a fairly high volume site. There are some tables example - the customers table which gets hit a lot. The problem We are writing a piece of code that selects a bunch of customers and ...
8
votes
5answers
4k views

How to manage millions of users?

I am about to launch something really big. I need to prepare my server and database. I would like to group each set of 100,000 users in separate user tables but I do not know how to associate one ...
2
votes
1answer
5k views

SQL Server 2012 installation failure An error occurred for a dependency of the feature causing the setup process for the feature to fail

I am installing SQL Server 2012 Developer (from ISO image written on DVD), my machine has Windows 7 (Edit: Windows 7 with service pack 1) and it already has SQL Express and SQL 2008 R2 Express ...
1
vote
0answers
443 views

How can we uninstall multiple instances of SQL Server 2008 without restarting the O/S?

How can we uninstall multiple instances of SQL Server 2008 without restarting the O/S? SQL Server installer is failing with error: Server needs to restart after one instance uninstalled. It is ...
2
votes
2answers
116 views

Which option do I have to modify to see more records without press `q`

I'm connected remotly to my database server with cygwin in full screen. When I query my database with select id, name from table limit 27; I get 27 records and I can do a new query seeing the ...
2
votes
2answers
747 views

Is there any way to speed up a query with 3x UNION on the same large table?

Assuming that the following query is legitimate and executes successfully, is there any way to speed it up? SELECT foo from T1 --T1 is a huge (>5e6 rows) table with no indexes UNION SELECT bar ...
3
votes
1answer
171 views

sql server down bad things happens

Following Situation: You have a Database with very high transactions, the Database is about 4100 GBs The Recovery Modell from your Database is full Every week you make a full backup from your ...
3
votes
2answers
226 views

Access 2000 database rapid growth

We have an Access 2000 format database running in Office Access 2003. We have a problem with the size when I merge the database; the size is about 250 MB. Two days later, the size has ballooned to ...
2
votes
1answer
183 views

Oracle function based index is not used in query

I cannot figure out why the following is not working as I expect it : CREATE TABLE table1(table1_id INT NOT NULL PRIMARY KEY, col1 INT NOT NULL, val1 VARCHAR(50)); CREATE INDEX ...
1
vote
1answer
243 views

Oracle Streams Setup Error

I am running Oracle 11g on a Linux box. I am trying to run the following command to set my streams user grants and other authorizations: BEGIN DBMS_STREAMS_AUTH.GRANT_ADMIN_PRIVILEGE( grantee ...
6
votes
0answers
207 views

Msg 14027, Level 11, State 1, Procedure sp_MSrepl_addarticle [table] does not exist in the current database [closed]

Before setting up SQL Server snapshot replication, I backed up the database from ServerA and restored it to ServerB. Both servers are running SQL Server 2008 R2 SP1. In trying to setup snapshot ...
4
votes
1answer
695 views

Allow user to do anything within his own schema but not create or drop the schema itself

I have created a schema in SQL Azure and granted the following permissions to a database role: CREATE ROLE myrole AUTHORIZATION dbo; EXEC sp_addrolemember 'myrole', 'myuser'; CREATE SCHEMA myschema ...
2
votes
2answers
283 views

simulate sequence on mysql in preparation for move to oracle

I've been developing an application against MySQL while a new development server has been slowly being set up. The new dev server will use oracle, and since we're getting close to it being ready, I ...
3
votes
0answers
193 views

How unsafe is it to change the data source of repl_distributor on a publisher

I have a long story that I will condense to a few bullet points that leads up to my question Reporting Server (SQL 2008) is distributor/subscriber cluster for a SQL 2000 Transactional Publication ...
1
vote
1answer
404 views

Mysql: Tell InnoDB to keep a specific table or database out of pool/cache?

I have some tables that are used primarily to keep historical data, or that are only used once a day. I do not want any operations on these tables to disrupt the more important tables present in ...
4
votes
1answer
489 views

SQL Server 2008 R2 Service Broker Troubleshooting

I set up Service Broker between two databases on separate instances, one on a 2008 R2 Cluster the other on a separate box also 2008 R2. I have gone through the process of setting up all the objects ...
2
votes
1answer
64 views

Full Text search returns duplicate keys

I have a search like the example below. The problem is that the result returns a key muliple times if the term "beach" is in myTextColumn multiple times, for example "I went to the beach because the ...
6
votes
3answers
465 views

How do I create a user for SQL Server whose queries (any/all) are time limited?

Is there any way to create a database user in SQL Server 2005 so that none of their queries are allowed to exceed a certain time limit (for e.g 20-30 seconds) or all queries are limited to a certain ...

15 30 50 per page