Help swivel... Please
Hi all...Please help me with the following problem swivel.
I went through some forums prior to this announcement and I just want to
of course, what I do is correct.
I need to rotate my "'per month'", like JAN_2012, FEB_2012.
But my pivot "" in the paragraph"' is not static. I mean it's 'PivotChart.
I mean, sometimes I'll have given 1 month and 2 months of time data etc etc...
so everything I do is
«"«DYNAMIC SQL»»»
I'm generating my pivot "" in the paragraph"" depends on date settings I get.
Here is the example of how I intend to use
to build the "" pivot in the clause"" dynamically.
It generates '' string' ' month and year dependent on the start date and end date.
create or replace procedure test3(in_start_date date, in_end_date date) as
v_query varchar2(4000);
begin
-- months string
for crec in (select dte,
extract(year from dte) || '_' ||
upper(to_char(dte, 'Mon')) year_month
from (select add_months(in_start_date, level - 1) dte
from dual
connect by level <=
ceil(months_between(in_end_date,
in_start_date)))) loop
v_query := v_query || ' ' || '''' || crec.dte || '''' || ' ' ||
crec.year_month || ',';
end loop;
-- Years string
for i in 1 .. floor(ceil(months_between(in_end_date, in_start_date)) / 12) loop
v_query := v_query || ' ' || '''' ||
to_char(extract(year from in_start_date) + (i - 1)) || '''' || ' ' ||
to_char(extract(year from in_start_date) + (i - 1)) || ',';
end loop;
v_query := rtrim(v_query, ',');
dbms_output.put_line(v_query);
end test3;
Please let me know if I'm doing something wrong or there at - it an easy way toDo it??
(* I DON'T NEED THIS FEATURE in SQL, I CAN USE PL/SQL *)
Hello
Kumar wrote:
... Please let me know if I'm doing something wrong or there at - it an easy way to
Do it??(* I DON'T NEED THIS FEATURE in SQL, I CAN USE PL/SQL *)
The best way would be a dynamic slider, found in the site, AskTom
If you want to build the part dyunamic of a PL/SQL PIVOT clause, this should give you some ideas:
CREATE OR REPLACE FUNCTION month_list
( in_start_date DATE
, in_end_date DATE
)
RETURN VARCHAR2
DETERMINISTIC
AS
return_txt VARCHAR2 (1000);
this_month DATE := TRUNC (in_start_date, 'MONTH');
BEGIN
WHILE this_month <= in_end_date
LOOP
return_txt := return_txt || Q'{, DATE '}'
|| TO_CHAR (this_month, 'YYYY-MM-DD')
|| Q'{' }'
|| TO_CHAR (this_month, 'YYYY_MON');
this_month := ADD_MONTHS (this_month, 1);
END LOOP;
return_txt := LTRIM (return_txt, ', ');
RETURN return_txt;
END month_list;
/
You want to retrieve a value, so use a FUNCTION instead of a PROCEDURE.
"... from DUAL CONNECT BY LEVEL<= ..."="" is="" handy="" a="" way="" of="" simulating="" a="" loop="" in="" pure="" sql,="" but="" pl/sql="" has="" real="" loops,="" so="" there's="" no="" need="" to="" simulate="">=>
If you are rotating on a DATE, you can find it easier not to convert the DATE into a VARCHAR2. The above function compares the DATEs, not VARCHAR2s.
In general, try to avoid the conversion from one type of data to another.
Tags: Database
Similar Questions
-
I used Nectar as my homepage and a toolbar added for many years. I always that it is simple and easy to use (a big plus for aging technophone!) and it is especially useful for letting me know what stores I could shop with through Nectar to increase my Nectar points. Points were also earned to complete the 'research', another useful feature.
In the past months, I have struggled with this up to the point where I contacted the persistent Nectar. They have kindly added 'free' points to my account to compensate for the fact that I had been unable to use the toolbar or to the shop via the Nectar. They suggested uninstalling and reinstalling the improved version of their toolbar. I tried to do several times, but have failed to be able to access online stores through Nectar and also to add to my total points using the Nectar search tool.
After trying again, in vain, to reload the toolbar, I now have to find a message from Firefox saying "Nectar Toolbar could not be verified for use in Firefox. Proceed with caution.
Can you please check this product so that I can continue its use? I don't know how else more to come this problem and would like to make things as simple as they were until this issue has been raised.
I hope someone can help - but please keep in mind of my state of technophobia and explain things in a way very simple for me (IE without using jargon 'computer' and technical writing!).
Thank you and hoping that you can help.
Firefox 40 verification is only a warning message, the new 'signature' feature add-on will keep an extension to work in Firefox 40.
If this Nectar toolbar simply stop working in Firefox 40, I can only imagine that this is due to a deprecated API that uses the extension or another issued compatibility. Add-on developers who are registered with the official website of modules was warned about this, API removed from Firefox 9 to 12 months to give developers time to fix their add-on before Mozilla removed the corresponding code for this API.
Bottom line is the Nectar needs to fix their extension to get it working again, AND they need to submit it to Mozilla Add - ons for the signature.
In 41 Firefox Add - ons that are not "signed" will be disabled, but the user can substitute for it. In Firefox 42 that replace the missing aura of the Beta and Release versions - signature is required for Firefox 42 and subsequently.
-
I have my 5 factory reset iPhone, now I can't set up my iPhone because it must be enabled, and I don't have a sim card to make. Is there a way I can install and use my iPhone without needing to be activated? Can someone help me please?
To skip the activation of sim card, you can use iTunes if you have a CDMA iPhone. However, if you have a GSM model you will need to insert a sim card to activate your iPhone (it can even be used/inactive). Here is an article that will help you determine if your iPhone is GSM or CDMA: http://osxdaily.com/2012/11/15/determine-iphone-gsm-or-cdma/
-
the sidebar is twice as wide as necessary and I can only do broader, not narrowed down to about 30-35 mm. helps refine please
Try Firefox SafeMode to see how it works there.
A way of solving problems, which disables most of the modules.
(If you use it, switch to the default theme).- You can open the Firefox 4, 5, 6, 7 SafeMode pressing the SHIFT key when you use the desktop Firefox or shortcut in the start menu.
- Or use the Help menu option, click restart with the disabled... modules while Firefox is running.
Do not choose anything at the moment, just use 'continue in safe mode.
To exit safe mode of Firefox, simply close Firefox and wait a few seconds before using the shortcut of Firefox (without the Shift key) to open it again.
If it's good in Firefox SafeMode, your problem is probably caused by an extension, and you need to understand that one.
http://support.Mozilla.com/en-us/KB/troubleshooting+extensions+and+themes -
I need to uninstall the iTunes 12.2.0.145 in Windows 7-32 bit, but I don't have the installation of this version files. Can someone help me, please?
The problem lies in a PC with Windows 7 32 bit
For general advice, see troubleshooting problems with iTunes for Windows updates.
The steps described in the second case are a guide to remove everything related to iTunes and then rebuild what is often a good starting point, unless the symptoms indicate a more specific approach. Review other cases and a list of documents to support further down the page, in which case one of them applies.
More information area has direct links with the current and recent if you have problems to download, need to revert to a previous version or try the version iTunes for Windows (64-bit-for old video cards) as a workaround for the problems of performance or compatibility with third-party software.
Your library must be affected by these measures, but it is also related to backup and recovery advice if necessary.
TT2
-
I downloaded 4 FF and now 5 and nor with my screen looks nothing like it says on the page of FF. For example, I don't have the orange FF tab in the upper left corner, I have no "PIN as app" option, nor do I view. Can someone help me please?
To get the orange FF tab, go to view > toolbars > menu bar. This should uncheck the menu bar giving you the orange button.
Panorama is a box made of 4 gray rectangles which should be on the far right, if not once you activate the orange FF tab, right click anywhere on a toolbar that doesn't has nothing to this topic, and you should get a menu with a list of your toolbars that you can check and uncheck the box. Come on down to personalize everything down and it will open a window with all your buttons. Find groups of panorama/tab button and drag it to the toolbar of your choice.
to pin a tab as an app, right-click on it; It is an option in the context menu.
-
Hello
can someone help me please? I received a call from the CTIC Tech and they offered me an Anti Malver software which I paid 179 euros. I would like to ask you about it?
These phone calls, e-mails or popup messages will ALWAYS be a scam.
You have been scammed.
Based on your other posts, you aapear have called these criminals. You allow to access your computer?
Note: Please stop rather create several threads with the same question, answer in one of the many other threads.
-
I have problem with my iphone 5 has no 4g 3g only. in Sweden in the works of 4g Malmö... can someone help me please...
Where did you buy this phone? 4G has already worked on this phone? Whatever the carrier said when contacting you? Have what troubleshooting you tried?
-
Install windows xp in hp mini 210 1010NR, help me please is urgent...
How can I install windows xp in hp mini 210 1010NR... I tried to install windows xp service pack 3, but I could not, can someone help me please its urgent thank you...
You need to integrate the drivers Sata ( ICH7M/MDH SATA AHCI ) and burn a new cd XP with nLite.
Here is a guide showing how to integrate and here are the drivers Sata . 7-ZIP or Universal Extractor are good out of the installer.
-
Repeat me an adobe flash plugin broke down I tried to fix it but can u help me please
He repeats to me adobe flash plugin crashed I tried ti fix but can't u can help me please
This has happened
Each time Firefox opened
its saying my adobe flash crushed Ive followed all the instructions, but does still not can not someone help me please
-
The keyword of Office Word mac is all mixed up. However in excel are more in their own as well as what I write today. Can you help me please?
Mac OS 9 is 16 years old. I asked that your post moved to the forum of Mavericks, since that's what you have published in your signature.
-
Hi help me please my disapled system [16017] what is the password
Hello
Enter pjooi
or
abpjoal
Kind regards
DP - K
-
Presario cq56: administrator password. Help me please
Hi maestrorod... I have a presario CQ56 notebook and it was working fine until suddenly I turn it on and it says to enter the administrator password. I try to enter my password 3 times and then he said: Disable System, key: 66905437. Can you help me please
Enter 79663419
REO
-
I want to display the summary cell by touchsmart? can you help me, please!
Dear Sir/dear Madam!
I want to display the summary of HP touchsmart laptop? can you help me, please!
Thank you very much!
on the infomation:
I have Touchsmart 520-1140e.
I see him having "Port HDMI in", I want content o switch of your laptop for work and the touchsmart screen, I don't know that same job switching with laptop LCD.
-
0x02DA1E1c error code. I am trying to download a game. This error happens then it say, drmactivtor applicationn also. Can U help me please.
Hello
Welcome to the community of Windows Vista answers.
You get this error message during the download or installation of the game?
This problem occurs with every game that you are trying to download/install?
If you receive the DRM activator error message do the following to correct the problem.
1 left-click on start
2 - right click on computer
3 - left click on properties 4 - left click on advanced system settings
5 - running, click settings
6. left click on the parameters of Performance data
7 - click TURN DEP FOR ESSENTIAL WINDOWS PROGRAMS AND SETTINGS ONLY.
8. click on apply and then OK.
UAC: (User Account Control)
Open Control Panel and type in the user account in the search box. You will see the link for "turn User Account Control (UAC) or not". Until it clicks. Uncheck the box and restart your computer
Concerning
Marnie. -
How to fix this error "generic host process for win32 services has encountered a problem and needs to close ' help me please I am using windows xp with SP3.
When I close this error or click on send or do not send, my session network remote also network mapped drive United Nations accessible then I restart my computer and I can access my network grows but after awhile once again this error and the same network behavior that I discussed earlier.someone has a better solution that take care of this problem.Hello
Given that the problem is related to the server of the IRIS, IRIS Contact support for assistance:
http://www.IRISLink.com/C2-1967-189/I-R-I-S---technical-support.aspx
Hope the above information is helpful.
Maybe you are looking for
-
Re: Satellite L750D - driver after WIn8 upgrade issues
Hello I use a Toshiba laptop (model: Satellite L750D psk4ye). Yesterday I spend this Windows 7 to Windows 8 pro (32 bit). I installed a driver but when I try to install my driver VAP (value added package) & pilot pc health monitor it doesn't. I try o
-
had 2 software companies were ringing me for about 3 months, say I have a problem with the software and the intimate cause of wii, the computer stops working too much, today, it was a called ammyy.com farm which is a computer company share? I, ve onl
-
bios systems stopped working on acer laptop aspire 5520 vista 32 bit
Signature of the signatureroblem problem Problem event name: BEX Application name: setup.exe_99 Machine slot Application version: 11.0.0.0 Application timestamp: 4dc9b238 Fault Module name: setup.exe Fault Module Version: 11.0.0.0 Timestamp of Module
-
Problem with printing of pdf documents: landscape instead of portrait
When I try to print a pdf file or a map of bing, my all-in-one HP officejet (J6480) started printing landscape although the portrait is selected. I use Adobe Reader X, Office 2010 and IE 2012 (64-bit), Windows 7 (64-bit).
-
I have connected a second monitor to my computer for Windows 8.1 using the DVI - D port. My first monitor is connected in VGA. Windows recognizes and identifies the second monitor correctly, but will not extend the office both monitors. All other wor