1
vote
0answers
56 views

SQL Server 2008 sp_send_dbmail [duplicate]

I'm using SQL Server's sp_send_dbmail to distribute mail. Everything is working fine; BUT I tried to test a bad email address and it always reports success; and nothing is in the failed sent items ...
6
votes
3answers
297 views

Is using SUM() twice suboptimal?

I know I have to write SUM twice, if I wish to use it in a HAVING clause (or use a derived table otherwise): SELECT id, sum(hours) AS totalhours FROM mytable GROUP BY id HAVING sum(hours) ...
1
vote
2answers
762 views

SQL Server 2008 sp_send_dbmail

I'm using SQL Server's sp_send_dbmail to distribute mail. Everything is working fine; BUT I tried to test a bad email address and it always reports success; and nothing is in the failed sent ...
0
votes
1answer
692 views

SQL Server: subscriber as publisher and hierarchical replication

In Oracle Streams one way replication from one DB to another is a basic block for many replication topologies (N-way, hierarchical, combined and so on), and changes could be captured and applied for ...
1
vote
1answer
133 views

Access 2007 Work in a separate file using ACCDE

Have been working in an Access 2007 application for over 3 weeks and it should be ready now. Anyway, I know (and tried) that "Make ACCDE" can actually split the raw data from the application itself so ...
0
votes
1answer
654 views

Howto shrink an sql-anywhere 12 db?

is there any tool to shrink SQL Anywhere Databases? With MSSQL/MSSQL Express it was an easy task. Just do it, have a faster DB again which has a size which can be transferred over a slow internet ...
1
vote
1answer
336 views

How do I open a Progress .bup file?

I have a .bup file which is supposed to be a Progress database file. My question is, how can I open/restore it and look at the data?
0
votes
1answer
954 views

Changing primary key from varchar to int

I have a user table where I am use varchar as primary key. Now from a different place I got the performance tip that int is better than varchar for primary key. So I would like to change my primary ...
1
vote
3answers
380 views

Copy database to local from server [duplicate]

As I show , I have server database version-10.50.1600 and local database version-10.0.1600 . How can I copy database (with all tables and data(s)) from server to local which has different version ? ...
0
votes
2answers
131 views

How do you store tabular data in an RDBMS?

First: I really haven't got any idea how to google for this. If you got one, leave a comment. If I want to store arbitrarily large tables in a database, how should I set up my database tables? ...
0
votes
1answer
294 views

MySQL asynchronous multi master replication conflict resolution

I have setup Multi Master replication, following this blog thread: http://0wned.it/geek-bits/guides/mysql-multi-master-replication/ And now it synchronizes perfectly, up until the moment the ...
2
votes
1answer
92 views

How to select nodes where all children is satisfied?

I have a tree structure of light bulbs. I want to turn on all the light bulbs starting from the leafs of the tree. A light bulb cannot be turned on unless all its immediate children are turned on. ...
4
votes
3answers
140 views

Check server activity with code

I would like to see the activity on of the SQL server. So I can run a query when the server load is low. I know there is an activity monitor in SQL server but my company doesn't want me to give the ...
2
votes
0answers
78 views

os_buffer_descriptors blocking problem SQL Server 2008 R2

The following query : select (buffer_descriptors.datacache) as 'Data Cache (MB)', case when buffer_descriptors.datacache > 4096 then (((buffer_descriptors.datacache)/4096)*300) else ...
2
votes
2answers
567 views

Can I open a SQL Server 2008 R2 database in SQL Server 2008 R2 Express?

This question has probably been asked a dozen times but I couldn't find them here or at SO. Can I attach/restore a SQL Server 2008 R2 database to my local SQL 2008 R2 Express instance?
1
vote
1answer
688 views

Like with the results of a subquery (multiple values)

What I'm trying to do is the following concept: SELECT field1,field2,field3 FROM table1 where field3 like '%'+(SELECT distinct field from table2)+'%' But this is not allowed because like does not ...
2
votes
4answers
678 views

Shell: How to time a script running in SQLPlus and kill it after x amount of minutes?

I have a little tool which automatically runs a series of SQL scripts when and outputs to .XLS when an appropriate request is made. However, some SQL scripts need to be ran on a live database, and I ...
-2
votes
1answer
103 views

how to count primary key of one table inanother table? [closed]

how to count primary key of one table which is used in another table in 5 to 6 column? If table 1 has primary key srno which is used in table2 in column d1,d2,d3,d4. I want to count how many times ...
-1
votes
1answer
69 views

validate where each parent intermediary is also a parent to itself [duplicate]

I want to validate where each parent intermediary is also a parent to itself. So this query should return invalid parents in SELECT If table has any. I need to do is first of all get all parents ...
1
vote
3answers
423 views

Table clean up taking too long

I am selecting around 10 million rows which are invalid from table grid into ##grid_temp and deleting their related info from grid_info table. I am running this in a python script. It is taking more ...
0
votes
1answer
2k views

pgAdmin3 can't connect properly to Postgres 9.2

I have installed pgadmin3 version 1.10.2, however when it connects to PostgreSQL server version 9.2, it says: Warning: This version of pgAdmin has only been tested with PostgreSQL version ...
1
vote
3answers
212 views

Eliminating duplicate records in data cleansing [closed]

I have a database full of records of people with simple information like first name, last name, email, location, ... . I need to eliminate the duplicate records. As I've search the process is called ...
1
vote
0answers
92 views

Can't get rid of filesort on joined query sorting on second table

For some reason, this query: EXPLAIN SELECT * FROM biz as b INNER JOIN listings as l ON b.id = l.biz_id WHERE l.pub_id = 14 AND b.cat_id=310 ORDER BY l.level DESC, l.random DESC LIMIT 5; says it ...
1
vote
1answer
103 views

Statistical Analysis of Data that has to be done in an order?

Bear with me - that is the first time try that in SQL Server, normally I have been doing that on the front end ;) I a implementing some analysis on time coded data series. This is not super ...
0
votes
2answers
766 views

Cannot see Green Button with white arrow in object explorer; DTC config problems?

I have SQL Servers across locations setup for replication. One of the SQL Server instances that I installed, running locally I can see the green button with the white arrow in the object explorer when ...
2
votes
1answer
350 views

SQL Server Memory for Backup Buffer

In SQL Server 2012 memory for backup buffer comes from buffer pool or non buffer pool (VAS)? Is this behavior changed between SQL server 2008 R2 and SQL 2012? EDIT: Does MAX Server Memory ...
0
votes
1answer
399 views

UTF8 vs ASCII or custom binary format: high-performance optimization on very big tables

The summary of my question is whether there are advantages, even if minimal, to use ASCII, or even a smaller format designed yet created specifically for the situation, instead of UTF-8 for strings. ...
1
vote
2answers
119 views

Can I limit an index to only contain the newest relevant row?

I have a table in PostgreSQL 9.2 that records login sessions called user_login_session. This table contains a user_id, start_timestamp and end_timestamp columns, amongst others. This table has started ...
1
vote
1answer
354 views

Exadata exachk.sh

I would like to run exachk.sh on regular basis. Now I have to interact with the script and answer all kinds of password questions before the script starts to extract Exadata information. I want to ...
5
votes
1answer
673 views

Optimum configuration for 4 SSD drives

I would like to move a SQL Server database from a shared configuration with the web-server to it's own dedicated box. My current budget will allow me to put 4 disks together in an array with a single ...
2
votes
0answers
87 views

Why does GO affect my SELECT? [closed]

I am experiencing a very weird behaviour from the Management Studio GO. I am following the full-Text Search tutorial and I run the following query over adventure works SELECT ...
3
votes
3answers
303 views

Relation to original tables or to existing linking table

In my database I have a table with different settings for my app. Each setting is in relation to a guest (table guests) and an event (table events). So basically each guest has specific settings for ...
1
vote
2answers
5k views

How to restore SQL Server database with mirroring

I have SQL Server with mirroring. I am trying to restore the database using the command: USE [master] ALTER DATABASE [CentralStorage] SET SINGLE_USER WITH ROLLBACK IMMEDIATE RESTORE DATABASE ...
1
vote
1answer
57 views

Is there any way to Restore a Database from newer version to an Older Version of SQL Server? [duplicate]

I am having a database backup file from SQL SERVER 2012 and i wanted to restore it on SQL SERVER 2008R2 . If we can’t restore a SQL Server 2012 database to earlier version what is the next best ...
0
votes
0answers
154 views

Data deleted from replicated table

I have two servers (one publisher and other is subscriber). The replication is succesfully running for a long time. I am using transactional replication with updateable subscription. Couple of days ...
0
votes
1answer
712 views

MySQL cannot create foreign key, errors 1005, 150

I'm trying to add a foreign key to a MySQL InnoDB table, linking a BIGINT with a table within the same database. I'm using MySQL Workbench to do this. It generates a script: ALTER TABLE ...
3
votes
1answer
760 views

MySQL error 2006 MySQL server has gone away after upgrade to 5.6.10 using homebrew on Max OS X 10.8.3

I upgraded my installation of MySQL on my Mac OS X 10.8.3 using homebrew brew install mysql Everything seemed to go smoothly, but...not really, as it turns out. I cannot add a new user (neither ...
0
votes
1answer
186 views

Multiple junction tables?

I am working on a system where you have users, and you have Fields of Study or 'fos' for short. Each user can have many fos and each fos can have many users. So we are dealing with a many to many ...
0
votes
1answer
324 views

MySql - set my.cnf location at server start

I want to have two MySql servers running on the same system (for master-slave replication tests purposes). To be able to do this I need both servers read different my.cnf files. As I see at startup ...
0
votes
2answers
218 views

How can I increase performance for select in select statement

The item table is like this id category_id name registered I have to show total number of items from the beginning. Suppose between 2013-05-01 to 20-05--05, I have to count all the items ...
1
vote
2answers
343 views

Database model: doubly linked list

I am not sure if I get this right. I'm designing a database model for use in an application, and I'm stuck at a doubly linked list (model first; there is no code yet). There's an order. An order has ...
4
votes
1answer
1k views

Stopping SQL Server Agent: Effect on runnings jobs

On a server with MS SQL Server 2008 installed, we use the SQL Server Agent to schedule a large amount of SSIS-packages, all with unique schedules throughout the day. Now and then, the server needs to ...
0
votes
0answers
77 views

Find the partition where data lives in MySQL

Is there a way to select the partition name where a specified record actually lives in? The idea is something like: SELECT <PARTITION_NAME> FROM mytable WHERE <where_condition> I found ...
0
votes
0answers
102 views

Why does mysql show Primary key constraint on a View?

As far as I know views cannot have a primary key. However the result of SELECT FROM KEY_COLUMN_USAGE says differ. PRIMARY | S_MOBILE_ITEM_VIEW | ID | ...
1
vote
0answers
637 views

Should xp_logevent and RAISERROR … WITH LOG work on LocalDB?

I need to run a script to configure a LocalDB (v11.0.3000) instance and database (from a .NET 4.5 program) and I want to record results at various stages. Someone suggested xp_logevent but it doesn't ...
0
votes
1answer
68 views

Recover PostgreSQL password with admin access to host

Good day. I have a PostgreSQL server. Once i had admin login and password, then i created a new login for web application (with low permissions like select form some tables etc). And i just lost my ...
-1
votes
1answer
105 views

I want to change ORACLE level#2 to log archiving mode instead of the current mode

I want to make that change to the archive log mode to use the redo log files to use it to make replication to database to another server. This is easy and possible when the server is single not ...
3
votes
2answers
332 views

Can stable (or immutable) functions call volatile functions?

The PostgreSQL documentation states: Any function with side-effects must be labeled VOLATILE... Consider the following function: CREATE OR REPLACE FUNCTION count_items() RETURNS integer AS ...
1
vote
1answer
190 views

How to repair Microsoft.SqlServer.Types assembly

When I run a checkdb('mydb') this is the only error message printed. Msg 8992, Level 16, State 1, Line 1 Check Catalog Msg 3857, State 1: The attribute (clr_name=NULL) is required but is missing for ...
1
vote
1answer
2k views

Unable to connect to Amazon RDS instance [closed]

I recently created an oracle instance on Amazon RDS. Unfortunately, I'm not able to connect to the instance using Oracle SQL Developer. The (relevant) information I have from Amazon; Endpoint - The ...

15 30 50 per page