Data dodania Pytanie
2017-06-19 21:06 SSIS insert recrods from Oracle to SQL and even process them »
Thanks for answering... I am new to SSIS and I have below requirement: We are getting bulk records from Oracle based on some criteria. I need to in...
(1) odpowiedzi
2017-06-19 17:06 Oracle sql MERGE INTO with a single where clause »
I have the following SQL code (this is how much I've got so far): MERGE INTO SCHEMA1.TABLE_1 table1 USING ( SELECT DISTINCT table2.colu...
(2) odpowiedzi
2017-06-19 16:06 MSReport is showing 1 day behind for expiry date, compared to CRM? »
Currently when I look at the expiry date section for insurance on my MSReport Builder it is 03/04/2017, but the expiry date section for my insurance i...
(1) odpowiedzi
2017-06-19 16:06 Ruby - Rails - SQL query - reordering words in a search term »
I'm working on a project with a search function that is set up as follows: if params[:search_term].present? && params[:search_term].length &g...
(2) odpowiedzi
2017-06-19 16:06 Oracle SQL - Get same result without using a WITH clause »
I've a query which uses a WITH clause, to be able to calculate some flags (IS_EMPLOYE, IS_AFFILIE) in the SQL result. But I need to find an equivalent...
(1) odpowiedzi
2017-06-19 15:06 SQL SUM and GROUP BY based on WHERE clause »
I'm running PostgreSQL 9.4 and have the following table structure for invoicing: id BIGINT, time UNIX_TIMESTAMP, customer TEXT, amount BIGINT, status...
(2) odpowiedzi
2017-06-19 11:06 How to convert below query from Oracle to Postgres having connect by? »
I am converting my application DB from oracle to postgres. I am stuck on a function having connect by syntax. Below is the Oracle query. PROCEDURE Ge...
(2) odpowiedzi
2017-06-19 10:06 How to write conditional query with combination of two columns as a single query in Laravel? »
I have three tables products, product_meta_keys, and product_meta_values. Product table stores product's general information like name and product_met...
(2) odpowiedzi
2017-06-18 23:06 Rails Postgres: set all fields in a table to zero, except for »
I have a number of tables in which I set all fields to zero, except for a few select ones (including foreign keys and some time values), on a weekly b...
(1) odpowiedzi
2017-06-18 21:06 SQL Joining and ordering invididual subjects by date »
So I have two SQL tables, one is a customer address book and the other is a purchase log. Customer Table Cust ID Cust Name 1 Adam 2...
(3) odpowiedzi
2017-06-18 19:06 query for ids inside JSONB using jsonb_each and LATERAL in postgres »
Imagine a super simple table such as: create table object ( id INT, data jsonb ); With some data: INSERT INTO object (id, data) VALUES (...
(2) odpowiedzi
2017-06-18 14:06 MySql select value if confition match or select first if not match »
I'm trying to select a user profile from a MySql database. I also have another table that contains user's telephone because they can have multiple pho...
(1) odpowiedzi
2017-06-18 11:06 Adding a user-defined constraint to an SQL table »
So i'm working with 2 tables: Persons and Marriage. Persons hold many attributes and his PK is person_id. Marrige is defined like that: CREATE TABLE ...
(2) odpowiedzi
2017-06-18 08:06 Remove duplicates from first column in Select (not Distinct) in Oracle »
I am new to Oracle. I have a Select as part of a larger query which returns the below result. My problem is that for the first column I only need the...
(2) odpowiedzi
2017-06-17 20:06 ORACLE 12c - "not a single-group group function" »
I have a table o employees that contains names, date of employment and some more information. I want to check which year the most employees were empl...
(4) odpowiedzi
2017-06-17 18:06 SQL query that returns a date »
My DB contains a period(month) and a year - I am trying to convert it to a date. I don't care for the actual day of the month so I have just made it "...
(2) odpowiedzi
2017-06-17 13:06 postgres jsonb array index »
I have created a model in loopback with 3 properties connected to postgres. Among the properties defined, I have one array property. My model is defin...
(0) odpowiedzi
2017-06-17 01:06 Select rows with different values on different columns »
I'm new to SQL so this took my a long time without being able to figure it out. My table looks like this: +------+------+------+ |ID |2016 | 2017...
(1) odpowiedzi
2017-06-16 18:06 Sum the results of case statement in a new column Oracle »
I have just started using an Oracle system after learning SQL, querying and RDBMS functionality in MS Access, so please bear with me. I have created a...
(2) odpowiedzi
2017-06-16 16:06 Oracle - optimising SQL query »
I have two tables - countries (id, name) and users (id, name, country_id). Each user belongs to one country. I want to select 10 random users from the...
(3) odpowiedzi
2017-06-16 15:06 PHP - Use preg_replace to change a colour of word after a specific character »
I currently have preg-replace in place to change the colours of words that display in a div. however at the moment it is simply just text matches. ...
(1) odpowiedzi
2017-06-16 10:06 Count values for the corresponding masks in SQL »
There is a table1 with values and a table2 with masks. How to calculate (count) the number of values for the corresponding masks at the base level (SQ...
(1) odpowiedzi
2017-06-16 10:06 Copying Data from Oracle Server to SQL Server »
I'm quite new to coding in general and I'm looking to copy 47 columns with c300,000 rows of data, from an Oracle to an SQL database, on a daily basis....
(1) odpowiedzi
2017-06-15 12:06 FULL OUTER JOIN to merge tables with PostgreSQL »
Following this post, I still have an issue when I apply the answer given by @Vao Tsun to a bigger dataset made this time of 4 tables instead of 2 tabl...
(3) odpowiedzi
2017-06-15 10:06 Merge tables with PostgreSQL »
The title of this question is not accurate but I didn't know how to summarize it. Please feel free to write it again if you can! Here is an extract o...
(1) odpowiedzi
2017-06-15 09:06 Sysdate in oracle virtual column »
I'm trying to create a virtual column in oracle that use a case statement but if I call the SYSDATE function it gave me this error: ORA-54002: only p...
(2) odpowiedzi
2017-06-15 09:06 SQL Query : Facing issues to get desired records from different tables »
I have two tables Calendar (Calname, CCode, PCode) Lookup (LCode, Name) Calendar table contains records like, Calname | CCode | PCode abc | O...
(2) odpowiedzi
2017-06-15 06:06 How to use LEFT OUTER JOIN to identify missing products by vendor? »
This query has been fun to figure out but I have come to place where I need some help. I have several tables and the ultimate question is: How man...
(3) odpowiedzi
2017-06-14 14:06 SQL how to do an outer join properly »
I have a table filled with the phone numbers of a company. My problem is, we have a row for every number an employee have, so if he have a main phone ...
(5) odpowiedzi
2017-06-14 13:06 How to design for higher scalability, in SQL Server databases that need set operations? »
Imagine a movie application that reommends the next movie to users based on this very simple algorithm: Movie should be new to user User has not mar...
(0) odpowiedzi
2017-06-14 12:06 Update table records - Add '00' for each 2 Numbers »
I have a table with many millions of records, in oracle. And in this table there's a field that needs to be updated. I need to add a '00' for each to ...
(1) odpowiedzi
2017-06-14 10:06 Query Performance: single column vs multiple column »
Which table structure is better among below 2? OR in first query i use LIKE operator in query. In second i use AND operator. Does first table ...
(2) odpowiedzi
2017-06-14 08:06 pg_query like with timestamp »
I get 0 results if I query the timestamp column for entries that contain 2017 (or any other year). The data in w_presse_erscheinung is a "timestamp w...
(2) odpowiedzi
2017-06-13 23:06 How to compare multiple column with multiple field array in Select query? »
I get stuck a bit at query creation at API server, I just want to respond with modified tracks data. I have tracks table with few columns like this. ...
(2) odpowiedzi
2017-06-13 22:06 How to delete entity with JOINs using JPA and Hibernate »
I have following entities: I want to delete WordSet by id and username of the user using JPA. Here is entity declarations: User @Entity @Data @T...
(2) odpowiedzi