The string-aggregation tag has no wiki summary.
0
votes
3answers
44 views
Why does the wm_concat not work here?
I have this query :
(SELECT OBJECT_ID from cr_object_group_entries_vw where object_group_id IN
(SELECT ITEM FROM TABLE(CR_FN_SPLIT_STRING('28,56',','))))
that returns :
But when I do :
...
1
vote
1answer
48 views
Oracle SQL group by queries, Kind of PIVOT [duplicate]
Till now i haven't got a need to post a query, almost everything is available. This is my first question.
I have a different requirement, I have the below table name say alarmdb
...
2
votes
1answer
42 views
Concatenating fields when BREAK ON command is used
I have built a command that uses the BREAK ON command to stop the output of duplicate field names. For example:
f.name | f.value
f.name | f.value
f.name | f.value
becomes:
f.name | f.value
...
-1
votes
3answers
77 views
Concat the second column value if the first column value is same
I have a query like below and listed output of it:
SELECT DISTINCT TRACKING_NUM,TITLE_OF_DOC_SEC
FROM some_table
WHERE TRACKING_NUM IS NOT NULL;
o/p:
TRACKING_NUM TITLE_OF_DOC_SEC
007 ...
2
votes
3answers
78 views
How to get the grouping output in PLSQL
I am having two tables:
table1 : test1
desc test1
empcode number(6)
qualification_code number(2)
table2 :test2
desc test2
qualification_code number(2)
qualification_name varchar2(10)
select * ...
1
vote
2answers
244 views
How to find count and names of distinct characters in string in PL/SQL [duplicate]
I'm quite new to PL/SQL and I need to get the names and count of the distinct characters in a string. E.g. if I have a string str="helloexample", I need to get output of distinct characters in str, ...
0
votes
1answer
269 views
show data from multi column to single row
in my oracle database contained the following data
http://i1207.photobucket.com/albums/bb476/daniwarrior/data-awal.jpg
I want to display the data as shown below
...
3
votes
4answers
570 views
Oracle concatenation of columns with comma [duplicate]
Possible Duplicate:
How can I combine multiple rows into a comma-delimited list in Oracle?
Could some one please tell me how to achieve the following?
Table:
efforts_id cycle_name ...
1
vote
2answers
157 views
Join multiple rows into a string
I have 2 tables in Oracle: table1 and table2 (we have a very unimaginative DBA!)
table1 has column id (and a few others).
table2 has columns id, table1id and code. table1id is a foreign key to ...
-2
votes
2answers
2k views
Merging Query Result into single row - Oracle
Can I do like this in oracle,.? I have some data like this:
No | Data |
===========
1 | A |
1 | B |
1 | C |
1 | D |
Is there any query that can produce a result like this,.?
No | ...
0
votes
2answers
88 views
Need help in grouping rows [duplicate]
Possible Duplicate:
How can I combine multiple rows into a comma-delimited list in Oracle?
I have a table that stores data in the following manner-
60333,120102,20120502,010000,1,2
...
0
votes
3answers
945 views
Oracle/SQL - Multiple Records Into One [string aggregation]
I realize this is a ridiculous request, but what I'm trying to do is pull multiple records back into a single column along with some literal text.
So given a table like this
REGION CITY SID
...
0
votes
4answers
813 views
SELECT returning multiple rows as string
I have a table:
Contracts:
contractid | contract name
"1" | "MAG:001"
"2" | "MAG:002"
-- and --
Devices:
devid | serialnum | fk_contractid
10 | 1234 | 1
11 | 5678 | 1
12 | 4321 | 2
13 | 8765 | 2
...
0
votes
1answer
151 views
Aggregate columns but distinct terms should be inserted
I have two table and I want to merge them
TERMS_TABLE
ID | TERMS
309 | 'hardware'
309 | 'software'
309 | 'computer'
TFIDF_TABLE
ID | TERMS
309 |'computer,phone,mp3....'
Now I want to ...
2
votes
2answers
122 views
How to do this in SQL query?
Table: A Table: B Table: C
------------ ---------------- -------------
P_id | G_id P_id | Name G_id | Title
------------ ...