Need to display my table rows as columns (have tried lots, still no luck)
My data is as follows:
attribute_name attribute_value
VisitType Housing
Priority 1
I need it to come out in this format:
VisitType Priority
Housing 1
It's set up this way to make some of the fields user definable. Therefore, VisitType is defined by the user and isn't set in stone.
I don't like this model but I'm stuck with it. Have tried a few things but nothing works!!
please help.
may be this could help.
Create table Att_tab (
Attribute_name varchar2(30),
Attribute_type varchar2(30))
Insert into Att_tab
Select 'VisitType', 'Housing' from dual
union all
Select 'Priority', '1' from dual;
Select * from Att_tab;
SELECT srno,
LTRIM(MAX(SYS_CONNECT_BY_PATH(Attribute_name,',')) KEEP (DENSE_RANK LAST ORDER BY curr),',') AS Attribute_name,
LTRIM(MAX(SYS_CONNECT_BY_PATH(Attribute_type,',')) KEEP (DENSE_RANK LAST ORDER BY curr),',') AS Attribute_type
FROM (SELECT 1 srno,
Attribute_type,
ATTRIBUTE_NAME,
ROW_NUMBER() OVER (PARTITION BY 1 ORDER BY Attribute_type) AS curr,
ROW_NUMBER() OVER (PARTITION BY 1 ORDER BY Attribute_type) -1 AS prev
FROM Att_tab)
GROUP BY srno
CONNECT BY prev = PRIOR curr AND srno = PRIOR srno
START WITH curr = 1;
Similar Messages
-
Display of table rows and columns in OAF
Hi All,
I am developing a custom page which has one table.
This page table should display the fields and it's corresponding values side by side.
for eg:
Header1 Header2
Lable1(field prompt) value1
Lable2(field prompt) value2
Lable3(field prompt) value3
Lable4(field prompt) value4
Lable5(field prompt) value5
Here:
Header1 is the prompt name of the header for Lables
Header2 is the prompt name of Values
Lables are the field names and values are its corresponding values.
Is there any special region/options to achieve this on OAF page.
Please help me
Thanks,
SrinivasHi Srinivas,
A table or advanced table can accomplish your requirements. Advanced tables have added features that can be included declaratively vs programatically. The dev guide has detailed examples on the various options.
Regards,
LC -
Internal table rows to columns
hi
i have an internal table with foll strcuture
customer jan feb mar apr jun july aug sep oct nov dec
a 1 2 3 4 5 6 7 8 9 10 11
b
c
n
i need to form another internal table whose ouput will be
month custA cust B custc cust d
jan 1
feb 2
mar 3
so depending upon the no of records of first internal table, columns need to be created in the new table with corresponding cusomters data.
how to proceed ?Check the links -
converting columns to rows
Convert Internal table Rows into columns of another internal table
Re: Moving columns of an internal table to rows of an another internal table.
Regards,
Amit
Reward all helpful replies. -
How to display number of rows as columns in a select statement? This is on
How to display number of rows as columns in a select statement? This is on 10g R2.
Thanks,
RFor the current (ie. row 1 of 100)
row_number over (order by -pick_a_column_set) as rnfor the total number of columns returned in your query
count(*) over() as total_count -
Negative number cannot be displayed in table if the column is too narrow
Hi, All
When a number is formatted as a certain formatting(not locale formmatting),Negative number cannot be displayed in table if the column is narrower than the negative number, just minus is displayed.
Can you help me? Thanks.
Version: EHP1 for netweaver 7.0 SP3
Best regards,
Jiande DingHi,
I think this has nothing to do with positive and negative numbers, By default the alignment of the text is Left, if you dont want to see '-' sign initially then you can change the alignment of the text to center or right in the display tab of properties for that column.
As you as saying that at runtime the numbers are visible if manually adjusted. to icrease the width of that column permanently goto Layout tab of the story board and increase the size of the table and then increase the width of the column.
the Fit Contents in the Layout should be set to "Actual Size".
Regards,
Rk. -
Like the title says...
I can't upload or import videos from my iphoto library, into final cut pro x. When i click, IMPORT MEDIA in FCP, It lists 'iPhoto Library' as GRAY, and will not let me select it. I need the videos out of there. I have tried every way I can think of.
I have also tried from the iphoto side, to export the videos or share them to final cut. I have had no luck.
I have tried to drag and drop indidual video clips from iphoto to fcp, and the programs simply do not respond to each other
I can see in the OLDER version of final cut pro x, where it has IMPORT FILES as an option, it was possible. I see this on forums and youtube videos of the older versions.
However, the newer version that i have, does not have IMPORT 'FILES' as an option, it is simply all lumped together as IMPORT 'MEDIA'
Thank You for the Helpat the end, you say "import preferences", which program are you describing?
So im safer using footage that is remotely being pulled from iphoto...
vs
using footage that is imported into FCP from imovie?
Is there anything i can do in fcp to make this footage more reliable or safer or more stable as i pull remotely from iphoto?
All the footage, and all the libraries to all programs, or on a new pegasus 12tb raid 5 setup fyi. -
My iphone App Store indicates that I need to update my Backup Assistant. I have tried about 30 times to log into my Apple account using every login I can think of and it continually tells me it is invalid or incorrect. I have changed my password/ID at least 20 times. What can I do?
Use the correct login/password that the app was purchased with.
-
Need to color a Table row based on a Column value
Dear Alll
I have a requirement to color the rows of a table based on a column value in it. I have tried and surfed many useful materials over the net. but none of them solves my purpose. Please help me, I know that i can used OADataBoundValueViewObject and create a custom css file and apply color to a particular column of a table using a decode in the select statement of that VO.
But all i need is to color a particular row with a particular color. Need your help with this ........
Please do reply
Best Regards
Edited by: Antony Jayaraj on Mar 27, 2012 8:54 PMThese posts might help you.
How to change the row color based on Condition
Can we colour the rows in the column of a table
Regards,
Peddi. -
Need to display Internal table records on screen without using table contro
Hi Experts,
I have a requirement to display internal table on screen which is having three columns (Material no, Serial No and quantity).
But I can't use table control as it is not supported by hand held devices.
They are going to use this transaction on hand held devices.
Thanks In advance.
GauravYou should be able to use the good old STEP LOOP processing for this... create your three fields in the row then convert them to a STEP-LOOP.
You can look up in the help how to work with STEP-LOOPs if you are not familiar with it. It was the way to manage table-like information before the age of table controls -
Pivot Table Row and Column extension OBIEE 11g
Hi,
I have pivot view report, I have 3 columns,
1) User Name
2) Date
3) Login Count
User Name will be row(Vertical)
Date will be Column heading (Horizontal)
Login Count Measures
So I will get login Count of user wrt date.
Now When I give Wide range of filter i.e, from 1st Jan 2010 to 31st Dec 2010.
There is increase in row also column, when it reaches certain extent it gives error as *'Exceeded configured maximum number of allowed input records.'*
How to change the limit? or there is any fix?
Thanks,
SatheeshHi,
I have also faced the same issue, i have solved by changing DefaultRowsDisplayed count in instance config file.
<Views>
<pivot table>
<DefaultRowsDisplayed>75</DefaultRowsDisplayed>
<pivot table>
</Views>
Paste that code (which i mentioned in my last post) in instanceconfig.xml before these tags
</ServerInstance>
</WebConfig>
But remember you need to restart the presentation service once this is done....
Thanks
Deva -
Need to know base table and base column name for Oracle view columns
I am trying to load metadata for some views and that requires me to know what the final table and column name would be corresponding to the view column.
For example, if I have a view x_v that is select a,b from x_v2; and x_v2 is a view that is select a,b,c from x;
I need to get the following information.
View View Col Base Table Base Col
X_V A X A
X_V B X B
and so on.
Is it possible to get this programmatically using any SYS schema tables or Dependency tables?
I tried an indirect approach wherein I lock tables using LOCK TABLE or FOR UPDATE OF. But I'm not too sure if I can go down to the level of individual view columns.
Can you help me with this?Thanks. I was looking at some indirect approaches.
I came up with this script that does it faster than dependencies but thats just for tables and not column mapping.
declare
cursor bt(cp_sid number) is
select u.name uname, o.name oname
from sys.obj$ o, sys.user$ u
where o.obj# in (select id1
from v$lock
where sid=cp_sid)
and u.user# =o.owner#;
cursor c_sid is
select sid
from v$session
where audsid =userenv('sessionid');
l_sid number;
l_view varchar2(100):= 'PER_PEOPLE_V';
l_schema varchar2(10):= 'APPS';
begin
open c_sid;
fetch c_sid into l_sid;
close c_sid;
dbms_output.put_line('SID: '||l_sid);
execute immediate 'lock table '||l_schema||'.'||l_view||' in row share mode nowait';
for i in bt(l_sid) loop
dbms_output.put_line(i.uname||'.'||i.oname);
execute immediate 'alter table '||i.uname||'.'||i.oname||' disable table lock';
execute immediate 'alter table '||i.uname||'.'||i.oname||' enable table lock';
end loop;
end;
It basically uses locks on views to verify locks on the base tables.
Just wondering, can we use FOR UPDATE OF statements to get to the columns? -
InDesign Tables: Row and Column Strokes
Using InDesign Tables: How do you get row and column strokes in a table to appear perfectly joined? When I choose "Column Strokes in Front" (Under Table Setup) i still see a tiny row stroke, and vice versus.. it's really visible in the PDF almost can't see it in InDesign though you can a little...any advice?
http://lawrence.ecorp.net/inet/samples/dhtml-rollover-tble-cols-rows.shtml
-
Need help in solving conversion row to columns issue
Hi friends
I came across a strange situation/ problem. The problem is in one table say source_metadata
I have 4 attribute
matching_Table matching_columns source_table source_col
OTREDW.PARTY_ALT_ID Src_key rcw Source_key
OTREDW.PARTY_ALT_ID party_id rcw party_id_org
otredw.individual SRC_KEY
otredw.individual name rcw name_org
otredw.individual name rcw name_mod
otredw.wage_fact src_key
otredw.wage_fact wages_tips rcw wage_tips_org
otredw.wage_fact wages_tips rcw wage_tips_mod
The matching tables and source table can be matched on src_key/source_key
I need to fetch the values from the respective tables / columns in one query. I have just faint idea to the solution is use of PIVOT feature.
The desired OUTPUT is
PARTY_ID PARTY_ID_ORG Name name_org name_mod wages_tips wages_tips_org wages_tips_mod
1111111 1111111 James James JamesR 1000 1000 2000
I hope I have explained what I need. I will appreciate If anyone will be able to show me the way how to resolve this issue.
Thanks
RajeshThanks everone for sending me the answer but I think I am unable to explain my issue.
The main issue is I am storing the name of the table and name of the corresponding column of the table under different columns of the table. How to fetch the data using a sql from these columns.
EXAMPLE
METADATA_TABLE
table_name Column_name
OTREDW.PARTY_ALT_ID PARTY_ID
OTREDW.INDIVIDUAL NAME
OTREDW.WAGE_FACT WAGES_TIPS
How to write query to fetch the table_name and column_name from metadata_table and fetch the data from the respective tables mentioned in the table columns?
I hope I was able to explain the question now.
Thanks
Rajesh -
Spry tables: row and column rollover
I have created some tables with spry and they are very nice.
I got the nice rollover effect to work on the rows, but the table
has enough rows and columns that if the the row AND column where
highlighted that would be even better. Is there a way to get the
row and column to highlight at the same time (Essentially
highlighting or intersecting at particular cell or data point)?
Thanks.http://lawrence.ecorp.net/inet/samples/dhtml-rollover-tble-cols-rows.shtml
-
Need to display 2 dates in one column in Report
Hi All,
I have two date chars, 'Begin date' (4/1/2007 ) & 'End date' (10/1/2011 ) in two different coulums & I need to display them in one column like 4/1/2007 - 10/1/2011, which would specify period i.e 'Begin date' to 'End date'. Can anyone please let me know how I could do this in Query designer?
Thanks!!as per ur issue it seems u want tod isplay the date start and end in the header area
this can be acheived using Text variables.
u can create 2 text variables whose value is either user entry and whose reference char is Calday
lets say ur user enters 2 date ,one as start date and another as end date.
so u can create a variable A & B whose reference characteristics is 0calday
now in query designer u select in column description where u wish to display date.
then in description side u will see a icon
if u click it u will be able to include text variabel in description
now here create 2 variables x & y
variable x
replacement path variable
reference char---0calday
replacement path tab....
variable is replaced by variable
now select ur variable A.
similarly create variable y
theni n description u can include variable and put like this...
variablex----variable y
this should solve ur issue
Maybe you are looking for
-
How can i compare two excel files with different no. of records.
Hi I am on to a small project that involves us to compare two excel files. i am able to do it but am struck up at a point. When i compare 2 different .csv files with different no. of lines i am only able to compare upto a point till when the number o
-
ALSO, used itunes to reinstall ios. Same issue.
-
Apple Monitor doubles as a space heater
Hi, Just got a 23" apple monitor and you could use it as a space heater. Had it on for about 2 hours and the thing gets hot, Real hot.... Is this normal.... Seems to work fine but it does get hot... Thanks Dave
-
CS4 eye dropper values disappear after grouping mask layer with next layer
Have an adjustment/curve with a mask (layer1). Under layer 1 is a second layer with just an image needing color correction(layer2). When I group the top layer1 with image layer2, the colour values disappear in the info pallette. Never did this in
-
Please help another publishing error
Hi I have checked around for answers (or at least a reasonable explanation of something fairly simple) and found nothing. I have just tried to add a new pictures page to my site, with a couple of holiday pics. All well and good. Then when I publish t