0
votes
0answers
3 views

Recursice cte addition in sql

Root ACCCODE='00001' Root ACCPARENTCODE='0' 118 records are there and 1-8 levels I need to add the total value to the parent nodes.(totaling the total value to base to top levels). Can anyone help ...
0
votes
0answers
3 views

RAM utilization

We are using SQL Server 2014 on Windows server 2008 Web edition (64 bit). Total RAM of OS is 8 GB .When we check high physical memory usage in the task manager it shows nearly 90 to 95 % full but I ...
1
vote
0answers
14 views

Can I create a trigger in mysql and update the same to oracle database?

I am trying to create a trigger in mysql and it should update in oracle database as any update/insert happens. Just want to know if any such thing is possible in mysql.
1
vote
0answers
10 views

Is there a way to determine if a postgres function depends on a user-defined type?

I am writing a Ruby script to handle functions and user-defined types in Postgres. I want to make sure, that before a function is created in the database, if it uses a user-defined type, than this ...
1
vote
1answer
20 views

Oracle - Using index on unique constraint, what the deal?

Using Druid to generate SQL script for Oracle, I have seen a difference between the version 3.10 and 3.13 and I would like to understand what going on. SQL generated by Druid 3.10 : CREATE TABLE ...
1
vote
1answer
16 views

How do I create/publish a report in SQL Server 2014?

I installed SQL Server 2014 with Reporting Services but I don't how understand how to create and publish a report so that users can run it on the report server on IIS. These are the programs that ...
0
votes
0answers
14 views

Optimization for query n increase performance

I am executing the following query: select count(inspection_result) from table where (inspection_time between "2015-06-28" and "2015-07-04") and inspection_result= 1 and part_type = "39000048" and ...
1
vote
1answer
6 views

In MDX what is the ParallelPeriod of UnknownMember?

Lets say I have a time dimension with the levels all, year, quarter, month, day. I have some sales per month and a calculated measere [sales last year] WITH MEMBER [Measures].[sales last year] AS ...
2
votes
1answer
22 views

Locking issues under transaction on Postgres

I recently got a "Out of shared memory - You might need to increase max_locks_per_transaction" error. This is a long running process where I import a bunch of CSV files after proper processing. I ...
3
votes
2answers
171 views

SQL query to find player with maximum runs

I have the following tables with me : Table 1 Title : Runs +------------+---------+ | P_ID | Runs | +------------+---------+ ...
1
vote
1answer
31 views

How can I get the last inserted id from an specific table from a given stored procedure?

I know about the existence of LAST_INSERT_ID() function... Though I am not quite sure about its behaviour... Does it take the last inserted id from the current user into account? Or uses all the ...
1
vote
1answer
26 views

How to set Persian calendar,currency,numbers,date and time and text in oracle database?

I have installed oracle database 12c on my laptop. I want to be able to store text,numbers,calendar,currency,... in my local language (Persian) in database tables and also show contents in Persian ...
2
votes
0answers
6 views

Neo4j service won't start with an imported database on Debian

I've been playing around with neo4j recently on my Debian 7.8 install. It's awesome! Today I imported around 100000 nodes and 75000 relationships using neo4j-import tool. I stopped the neo4j service ...
7
votes
1answer
494 views

What's the difference between “expression <=1.” and “expression <= 1”?

Reviewing code and a case statement has expression <= 1. as opposed to <= 1 I'm not sure what the purpose of the 1. is. Any thoughts?
-1
votes
1answer
23 views

Sending an automated email through a nightly job

I had the following SQL query: select substring(PostOfficeBox,1,4) as 'Postcode' , COUNT(CASE WHEN New_accounttype = 1 THEN New_AccountType ELSE NULL END) as 'New Connections' , COUNT(CASE WHEN ...
1
vote
1answer
15 views

table structure for events

Got a bit stuck, need a hand. I need to store events at the database, and events may happen at different location multiple locations at the same time so these are my tables CREATE TABLE ...
2
votes
1answer
12 views

Searching SSIS packages for the use of specific tables

I have a number of SSIS packages, how can I search them to find the use of specific tables? I need to make tables changes and I am trying to assess the impact of these.
1
vote
3answers
57 views

Multi-table optimal database design

I'm a bit new to the database design. Thus this question to people who may have more experience. I need to design a database that needs to store statistical data for many systems. The data is ...
0
votes
0answers
4 views

Adding postgis geometry with rake task

I have a postgres table test with a geometry column: Column | Type | Modifiers ...
1
vote
2answers
15 views

Select data where column value exists in seperate rows for same reference id

This is on a MySQL database. Locations have services. What I want is to get all results where service_id is 2 AND 3, not OR so using IN is out I believe. Database ---------------------------- | ...
0
votes
1answer
17 views

Copying CSV file to temp table with dynamic number of columns?

I am wondering if there is a way to copy a csv file into a temp table where the number of columns is unknown in the csv file. The DB software I'm using is PgAdmin III. I figured out that if I do know ...
0
votes
2answers
20 views

How do I determine the appropriate size for my tablespace when importing a .dmp file?

I have a 14g DMP file. How large should I size my tablespace to import it into an Oracle 11g database?
1
vote
0answers
11 views

Whitespace Trimming on Before Trigger in PL/SQL [on hold]

I'm looking to create a simple trigger that trims the whitespace on a piece of data prior to it writing to the table. I'm using PL/SQL with Oracle 11g. I am receiving the following error: ...
0
votes
1answer
23 views

Is possible do an online snapshot backup , without archive logs at Oracle Database?

Using Oracle Database Standard Edition 11r2 . I'm looking a way to backup the database with zero downtime , using a snapshot of datafiles (LVM snapshots) and without need backup de archive logs. ...
3
votes
1answer
36 views

Any reason not to add 'rowversion' column?

The TechNet article, "Optimizing Microsoft Office Access Applications Linked to SQL Server", recommends adding a rowversion column to SQL Server tables linked from MS Access. From the Supporting ...
0
votes
0answers
22 views

Why is my PL/SQL procedure so slow?

I have this sub-procedure in a fairly large program, and it is taking hundreds of times longer than comparable sub-procedures. Is there any way I could improve efficiency here? None of this ...
-4
votes
0answers
25 views

How to filter a column of type DATE THE MAXIMUM RECORD DATE IN OBIEE [on hold]

How to filter a column of type DATE THE MAXIMUM RECORD DATE
-5
votes
0answers
31 views

Why isn't my query returning the correct results? [on hold]

I am trying to get information from several tables that I need in order to produce a report of all the stopped services on our critical servers. This query for some reason works if you switch the ...
0
votes
1answer
24 views

How to test mysql for changes

I'm OCD person, I think I accidentally dropped something in my mysql. Problem is I've around 50 databases, and I cannot manually check everything :( Is there a way to check for these kind of ...
1
vote
1answer
26 views

Variable Substitution

I am working in TOAD for Oracle and am trying to use variable substitution in my coding. I have been able to get variable substitution to work in the code body pressing F5: Define Value = '1.5' ...
-4
votes
0answers
17 views

SQLPLUS QUERY HELP

Please help to create what might be a simple query for you; very tricky for me. Maybe a nested query?... or maybe a "For Loop". Thank you! Table name: WO_OPERATION Relevant Columns: ...
4
votes
1answer
94 views

Find rows where data resets

So I have a table tbl where I'm trying to pull data that increments at a variable rate. I need to identify when the data resets so I can make a cumulative value. Here's an example table: ID VAL ...
0
votes
2answers
19 views

Error: This version of MariaDB doesn't yet support 'multiple triggers with the same action time and event for one table

I'm trying to run this query in mysql Ver 15.1 Distrib 5.5.44-MariaDB, for Linux (x86_64) using readline 5.1 but got this error all the time: CREATE TRIGGER trig_companies_table_insert BEFORE INSERT ...
4
votes
2answers
118 views

Reseed identity column in all empty tables [duplicate]

I need to write a query that resets the identity on all tables that have an identity column and are empty.
1
vote
0answers
32 views

Why are SELECT queries in sleeping status holding open transactions

Using sp_WhoIsActive, I see that I have a lot of processes in a "sleeping" status, several for hours. I am not sure of the cause and am still troubleshooting (timeout? bad code with uncommitted ...
0
votes
0answers
6 views

Why are some of my migrated tables showing “The given key was not present in the dictionary” in WebMatrix's interface?

I'm having an issue while using the SQL Server Migration tool to convert Access accdbs into SQL Server 2014 Express. I am converting the tables using SQL Server Migration Tool and I have a connection ...
0
votes
0answers
4 views

Oracle Drivers Install Error - Missing and Unknown files

I'm trying to run a VBScript on a machine that doesn't have Oracle installed; though I just needed the driver to use a connection string that does not use a TSNames.ora file (connecting to a remote ...
0
votes
0answers
17 views

Getting milliseconds elapsed during a stored PL/SQL procedure

I've been using sysdate to time procedures, but a lot of my procedures are very small procedures that get called thousands of times. Is there a way to get milliseconds elapsed instead of seconds? I ...
0
votes
0answers
20 views

vtiger: can't login with newly created user [on hold]

When I create a new user in the 'Manage users' users section, and after trying to login with his details I get the following in log: Tue Jun 30 16:05:04 2015,666 [8555] INFO VT - PearDatabase ...
2
votes
1answer
32 views

Dump all Views of multiple databases in MS SQL

I need to export the views from multiple databases of an older server. (Essentially, to generate a list of views using a particular piece of SQL. ) The fastest way I've found thus far is to manually ...
-1
votes
0answers
28 views

Stored procedure - list of strings as an out variable. How do I do this?

I have a pl/sql procedure that will be called from a web application. It needs to return a list of Strings. How would I do this? Oracle Database 11g Release 11.1.0.6.0 - Production PL/SQL Release ...
0
votes
2answers
37 views

Cannot Decrypt the encrypted columns from the database backup on local machine

I've a SQL server 2014 running on one of our server. We're in the process of implementing security steps for our databases. I've encrypted a column in one of the table in the database on the server. ...
-7
votes
1answer
40 views

Store Procedure which INSERT, UPDATE, DELETE any table(for any table) where table name and its values are passed as parameter [on hold]

Stored procedure which performed operations like inserting data to table,updating data,and deleting data of table where table name is passed by parameter Parameters of stored procedure : table name ...
2
votes
0answers
16 views

Transaction log bloat when writing to table on replicated database with parameterized filter

We are observing abnormally large log writes whenever we update a table that is used for parameterized filter in a merge replication. There are a number of join filters as well. When executing a ...
4
votes
2answers
127 views

Postgres is a performing a sequential scan instead of index scan

I have a table with about 10 million rows in it and an index on a date field. When I try and extract the unique values of the indexed field Postgres runs a sequential scan even though the result set ...
1
vote
1answer
31 views

Why does MySQLTuner only see 4Gb of RAM?

I ran MySQLTuner to verify the configuration of a MySQL database, and it reported this problem: [!!] Maximum possible memory usage: 40.9G (1022% of installed RAM) These figures come from computing ...
2
votes
0answers
24 views

Postgres 9.4+: JSONB instead of EAV

I'm figuring out a way to structure a new postgresql database, and I'm curious if I could use a JSONB column instead of the EAV model for storing properties of an entity. This seens like a flexible ...
0
votes
1answer
34 views

A good dataset to experiment NoSQL databases [on hold]

I need to do some experiments in HBase and Cassandra and to do that I need an adequate dataset. The dataset I'm looking for has to be large enough (i.e. more than 2GB) and the data in it has to be ...
4
votes
2answers
611 views

Index performance on ON versus WHERE

I have two tables @T1 TABLE ( Id INT, Date DATETIME ) @T2 TABLE ( Id INT, Date DATETIME ) These tables have a non-clustered index on (Id, Date) And I join these tables SELECT * ...
0
votes
1answer
19 views

Oracle selective redo log shipping

We are planing to setup an Oracle 12c RAC with a Logical standby in the DR site. Since data consistency is extremely important, we our planning to setup redo log shipping to be in SYNC mode. Our ...

15 30 50 per page