Date Formatter needed.
Hi Friends,
I've this method in my code to display the date.But this is showing the results as:
Fri Feb 07 16:24:42 GMT-05:00 2005
But I need them as:
2005-02-07 08:10:10
I can do this formatting with the "format" method,but i need it done with the "parse" method.I went through some tutorials,but coudn't find any answer,can someone help me please.
private DateFormat dateFormatter;
dateFormatter = new SimpleDateFormat("yyyy-MM-dd hh:mm:ss");
private Date getDate(String s) {
Date d = null;
try {
d = dateFormatter.parse(s);
} catch (ParseException pe) {}Thanking you in advance.
I can do this formatting with the "format" method,but i need it done with the "parse" method.
But i need it as:
2005-02-04 15:25:10You have answered you own question, use format.
Why do you believe you need to use parse, which pasres a string (as the name suggests)
Similar Messages
-
How to know which master data objects need to activated in R3
SALES OVERVIEW CUBE -0SD_C03
How to know which master data objects need to activated from delivery version to active version in R/3 for a particular standard cube like 0SD_C03.
its very urgent please advise.
R/3 in RSA5
Sales Master Data
0ACCNT_ASGN_TEXT Account assignment group for this customer
0ACCNT_GRP_TEXT Customer account group
0BILBLK_DL_TEXT Locked
0BILBLK_ITM_TEXT Billing block for item
0BILL_BLOCK_TEXT Billing block in SD document
0BILL_CAT_TEXT Billing Category
0BILL_RELEV_TEXT Relevant for Billing
0BILL_RULE_TEXT Billing rule
0BILL_TYPE_TEXT Billing Type
0CONSUMER_ATTR Consumer
0CONSUMER_LKLS_HIER Consumer
0CONSUMER_TEXT Consumer
0CUST_CLASS_TEXT Customer Classification
0CUST_GROUP_TEXT Customer Group
0CUST_GRP1_TEXT Customer Group 1
0CUST_GRP2_TEXT Customer Group 2
0CUST_GRP3_TEXT Customer Group 3
0CUST_GRP4_TEXT Customer Group 4
0CUST_GRP5_TEXT Customer Group 5
0DEALTYPE_TEXT Sales Deal Type
0DEL_BLOCK_TEXT Delivery block (document header)
0DEL_TYPE_TEXT Delivery Type
0DISTR_CHAN_TEXT Distribution Channel
0DIVISION_TEXT Division
0DLV_BLOCK_TEXT Schedule line blocked for delivery
0DOC_CATEG_TEXT SD Document Category
0DOC_TYPE_TEXT Sales Document Type
0INCOTERMS_TEXT Incoterms (Part 1)
0INDUSTRY_TEXT Industry keys
0IND_CODE_3_TEXT Industry code 3
0IND_CODE_4_TEXT Industry code 4
0IND_CODE_5_TEXT Industry code 5
0IND_CODE_TEXT Industry code
0ITEM_CATEG_TEXT Sales document item category
0ITM_TYPE_TEXT FS item type
0KHERK_TEXT Condition Origin
0MATL_GRP_1_TEXT Material Group1
0MATL_GRP_2_TEXT Material Group 2
0MATL_GRP_3_TEXT Material Group 3
0MATL_GRP_4_TEXT Material Group 4
0MATL_GRP_5_TEXT Material Group 5
0MATL_TYPE_TEXT Material Type
0MAT_STGRP_TEXT Material statistics group
0NIELSEN_ID_TEXT Nielsen ID
0ORD_REASON_TEXT Order reason (reason for the business transaction)
0PICK_INDC_TEXT Indicator for picking control
0PRODCAT_TEXT Product Catalog Number
0PROD_HIER_TEXT Product Hierarchy
0PROMOTION_ATTR Promotion
0PROMOTION_TEXT Promotion
0PROMOTYPE_TEXT Promotion Type
0PROV_GROUP_TEXT Commission Group
0REASON_REJ_TEXT Reason for rejection of quotations and sales orders
0REBATE_GRP_TEXT Volume rebate group
0RECIPCNTRY_TEXT Destination country
0ROUTE_TEXT Route
0SALESDEAL_ATTR Sales deal
0SALESDEAL_TEXT Sales deal
0SALESORG_ATTR Sales organization
0SALESORG_TEXT Sales Organization
0SALES_DIST_TEXT Sales district
0SALES_GRP_TEXT Sales Group
0SALES_OFF_TEXT Sales Office
0SCHD_CATEG_TEXT Schedule line category
0SHIP_POINT_TEXT Shipping point/receiving point
In BW
Base Unit of Measure 0BASE_UOM
Bill-to party 0BILLTOPRTY
Calendar Day 0CALDAY
Calendar Year/Month 0CALMONTH
Calendar Year/Week 0CALWEEK
Change Run ID 0CHNGID
Company code 0COMP_CODE
Cost in statistics currency 0COST_VAL_S
Credit/debit posting (C/D) 0DEB_CRED
Distribution Channel 0DISTR_CHAN
Division 0DIVISION
Number of documents 0DOCUMENTS
Sales Document Category 0DOC_CATEG
Document category /Quotation/Order/Delivery/Invoice 0DOC_CLASS
Number of Document Items 0DOC_ITEMS
Fiscal year / period
Fiscal year variant 0FISCVARNT
Gross weight in kilograms 0GR_WT_KG
Number of Employees 0HDCNT_LAST
Material 0MATERIAL
Net value in statistics currency 0NET_VAL_S
Net weight in kilograms 0NT_WT_KG
Open orders quantity in base unit of measure 0OPORDQTYBM
Net value of open orders in statistics currency 0OPORDVALSC
Payer 0PAYER
Plant 0PLANT
Quantity in base units of measure 0QUANT_B
Record type 0RECORDTP
Request ID 0REQUID
Sales Employee 0SALESEMPLY
Sales Organization 0SALESORG
Sales group 0SALES_GRP
Sales Office 0SALES_OFF
Shipping point 0SHIP_POINT
Ship-To Party 0SHIP_TO
Sold-to party 0SOLD_TO
Statistics Currency 0STAT_CURR
In R3 RSA5 we have all the Master data data sources as mentioned above, and BW also. How to find the related Master data Infosource in R/3 Master data Data sources.
Thanks in advance,
Bhima.
Message was edited by: Bhima Chandra Sekhar GuntlaHi,
<i>How to know which master data objects need to activated from delivery version to active version in R/3 for a particular standard cube like 0SD_C03.</i>
I think, you are looking for master data sources(text,attributes,hier).Am i right?
If so, This cube has almost all SD master data characterstics. So you can activate all the all master data datasources of SD in r/3 (SD-IO).
Any way you requirement does not stop only by using this cube . You will activate all other cubes in SD also. So if you want to activate only needed master data datasources when you are activating a cube, the job becomes senseless. There is no problem(wrong) in activating all master data available under that application , even though you want to activate only one cube.
With rgds,
Anil Kumar Sharma .P -
I downloaded and installed Airport Express Utility 5.6 to get my old Airport Express to work with the latest Mac OSX 10.7.4, but when I install and run it, it still says my Airport Express is out-of-date and needs the 5.6 utility. What's up?
It is likely that you downloaded AirPort Utility 5.6.1. If you checked the requirements, this only runs on Leopard or Snow Leopard Macs.
You have Lion, so you need AirPort Utility 5.6 for Mac OS X Lion -
Disk Utility - Partition map needs repair because a data partition needs loader space.
I just finished setting up both my OSX and Windows installs from scratch after fitting an SSD, which in-turn was right before my logic board died and Apple replaced it, now it looks like I have some sort of hard drive issue brewing.
This was my plan for the SSD, and how it currently displays in Disk Utility although that wasn't the case earlier:
And in Terminal:
My intention was to have two boot partitions for each OS, 'Macintosh HD' and 'Win 7 Pro' and a third shared data partition 'Projects' on the SSD, which I made in Drive Genius after installing Boot Camp. I don't want Macintosh HD accessible from Windows because I'll be using Paragon HFS+ or MacDrive to give write access and don't want OSs stomping on other OSs turf, hence needing three partitions. Everything looked fine until I just checked Disk Management under windows and realised it couldn't see the Projects volume. Even though it's fine in OS X, it was just marked black/unallocated space.
So I booted back into OSX, all my files look fine so I ran Disk Utility and the Partition tab looked really odd - unfortunately I didn't get a screenshot. All volumes reported their size correctly but visually, Macintosh HD took up most of the drive. I could see 'Windows 7 Pro' under this, but the Partition Layout section had a scrollbar, which if I scrolled down showed 'Projects' squished into a tiny gap at the bottom. I ran a Verify, which reported no problems, and at some time since the Partition Layout has reverted to how it should look (as in the screenshot above), with 'Projects' book-ended by "Macintosh HD' and 'Windows 7 Pro'.
Now when I run a Verify on Macintosh HD or Projects volumes, it says there's no problem, but if I run one on the drive, I get this message:
Volume Macintosh HD on disk0s2 has 0 bytes of trailing loader space and it needs 134217728 bytes
Problems were found with the partition map which might prevent booting
Error: Partition map needs repair because a data partition needs loader space.
I've only managed to find one other mention of this error here, but the fix is not relevant to me because I don't have Sophos installed. I've tried Single User/Safe Mode but it just boots into normal mode, so I can't do a fsck -fy.
** /dev/rdisk0s2 (NO WRITE)
Can't open /dev/rdisk0s2: Permission denied
That value in bytes is exactly 128mb, so I suspect the problem lies with one of the invisible partitions that show up in iPartition and Disk Management under Windows, but not in Disk Utility. I have backups and I suspect the root of the problem is partitioning in iPartition after installing Boot Camp, but I've never had issues with this approach in the past so I'm wary of just giving up and reinstalling Windows again will be massive hassle because I no longer have a SuperDrive and last time it refused to install from USB.
Anyone have any idea what's going on? It seems like the sort of issue Disk Utility should just handle, at least in Recovery mode, but it's not playing ball. It also doesn't seem like a massive problem since my files all look fine and performance is OK, so I'm reluctant to do anything major.
I'll update with a shot of the drive in Disk Management from Windows in a few minutes, in case that sheds light on anything. Thanks!Similar issue here. I manually partitioned my hard disk for triple boot (using Gparted on Linux), then everything was just fine until I ran bootcamp, to do something as simple as create a boot USB.
I get the same error as a result and have to work my way into booting, by resorting first to a Linux live USB, then restarting from the live USB, to finally reach my rEFInd boot manager, or whichever boot manager should be initialized at startup.
I suppose that the cause in my case is that some operation "scratched" the protective MBR. See this:
http://www.mactech.com/articles/mactech/Vol.23/23.03/APMtoGPT/index.html
I am hoping to fix it using an external Yosemite installation media: see this guide -
http://www.macworld.com/article/2367748/how-to-make-a-bootable-os-x-10-10-yosemi te-install-drive.html
And as a last resort to reinstall.
I'll admit I am negatively surprised. I need this computer for professional reasons, and for the sake of "preserving the integrity of OSX", measures defined by Apple instead tend to make partitions far easier to damage. And this problem seems to affect a number of users.
As for what I have to go through to fix it: a 5GB download, during which I have to register my credit card to the Apple Store. "Pay first, get your free software next."
IF Disk Utility can fix it, from the external media, then fair enough. The hassle is unpleasant but it files as "a choice".
Otherwise you can file it safely under software design calamity. -
Date format needs to be in selection screen mm/dd/yyyy but in alv output ..
hi
i need help on displaying date in alv output
date format needs to be in selection screen mm/dd/yyyy but in alv output ..it should be displayed as yyyymmdd
regards
Nishanthi,
you are passing the value to ALv using an internal table.
so store the format YYYYMMDD date in the internal table and pass it to ALV.
use the below FM
DD/MM/YYYY -> YYYYMMDD
<b>CONVERSION_EXIT_PDATE_INPUT</b>
rgds
Anver -
10.1.2: Problem with ConrolHint Date-Formatter
Hi,
when defining an control hint of format type Simple Date and format "yyyy-MM-dd G 'at' hh:mm:ss" in an EO the business components browser shows values like "2005-01-04 n. Chr. at 12:00:00". But the SQL column contains a correct time fragment like "9:35:21.0". Without control hint definition the value is displayed as "2005-01-04 9:35:21.0" !!
The attribute is defined as DATE/oracle.jbo.domain.Date.
Any workaround?
With JDev9052 I get the same results! Please, have a look at Date (Formatter) problem in JDev 9052
MarkusHello,
is is bug really not fixed?
When I take a look at the Entries in the Bug Fixed List
(Bugs Fixed in Oracle JDeveloper 10g 10.1.2), I would have though differently:
2825228 3730910 BC4J RT DEFAULTDATEFORMATTER DOES NOT SUPPORT NEW TIMESTAMP DOMAIN?
3730910 BC4J DOMAIN TIMESTAMP DOMAIN NOT EQUIVALENT TO JAVA.SQL.TIMESTAMP, FORMATING BROKEN?
3668688 3730910 BC4J DATA_TAGS TIME VALUES NOT SHOWN IN JSP - WHEN USING SQL DIALECT SQL92?
Or is this referring to an other problem?
Greetings
Harald. -
How much data is needed to download the whole creative suite?
How much data is needed to download the whole creative suite?
Jacoedit you can see the size of the base installers at http://prodesigntools.com/adobe-cc-direct-download-links.html. Please be aware that you will still need to download the updates for the applications as well.
-
Error -2003: a data handler needed by the movie could not be found
Hello.
I just purchased QuickTime Pro and the MPEG-2 add-on for it, for the single purpose of transcoding some MPEG-2 recordings to H.264. However, when I try to open any of my MPEG-2 files in Quicktime, I get the message: "error -2003: a data handler needed by the movie could not be found (my-filename.mpg)"
I can play these files in a number of different free players--VLC, Mplayer, Windows Media Player, RealPlayer... but not in the player I paid $50 for.
Can someone please help me?That doesn't really help. Besides, I haven't even got to the point where I'm trying to export. I get this error message when I try to open the file. I can't even play back the clip.
And the MPEG-2 page clearly states: "The QuickTime MPEG-2 Playback Component provides QuickTime users with the ability to import and play back MPEG-2 content, including both multiplexed (a.k.a. muxed, where the audio and video tracks are interleaved together into one track) and non-multiplexed (a.k.a. elementary) streams."
Also, Streamclip crashes when I try to load my MPEG-2 clips, so that's not going to work (and even if it did, I am trying to find a simple way to take the HDTV content I've recorded off the air and get it onto my AppleTV--I want fewer steps, not more).
Looks like I'll have to waste some time calling customer service to get a refund, since there's no way to do this via the website. -
Profit Center Master Data- Segement need to be changed
Hello Gurus,
We have somehow set wrong segment in Profit Center Master Data, We need to change the segment. Transction is posted to the profit center what is the easy way out to change the segment for profit Center master data?
Any help will be apreciated? i have gone through the SAP Note
940721 - KE52: Segment in prof center master record cannot be changed
Or a work around solution.
Thanks
PrasadHi Prasad,
As you already find out, once there is transaction data on a profit center, the segment field is no longer changeable in order to prevent inconsistencies and incorrect result from the segment reporting point of view. This is standard system behaviour!
You can try with the the following *Notes. It will provide further corrections relevant for your issue.
*Notes:1373616 Segment in profit center changed despite transaction data
1037986 KE52: Changing the segment in the profit center master data
Regards
Eugene -
Help with simple date formatter
hi i have a text box which has a date , day , time on it, i would like to use simple date formatter and change the format...
i would like to get the day part alone getin displayed below the text box,
any suggestions?Yes. Read the SimpleDateFormat API docs about specifying formatting patterns.
-
Installer could not locate the data it needed... Entourage 2008
Hi, I'm a bit of newbie to Mac's... I am trying to work out why a copy of Entourage 2008 I have wont install... I have posted on the Mactopia forums but with no success, so I thought I would try here, as I am not sure if it is an Entourage/Microsoft issue or a Mac OS issue. Every time I try to install my downloaded e2008.iso (came with my Exchange server rental) I get the following error: "Install Failed. The installer could not locate the data it needed to install the software. Check your install media or internet connection and try again or contact the software manufacturer for assistance". I am assured that the download I have is complete and 'verified'. When I double click the .iso file, it mounts and then opens - i then click through 'Office Installer_mpkg / contents / distribution.dist to begin the install. If anyone has any advice on what I might be doing wrong I would appreciate it! Thanks.
Thanks - it is reputable (should be...) as it is from the company i get my exchange server rental through, part of the 'package' is a download of entourage or outlook. Unfortunately they do not offer very good mac support... Have gone back to them to make it their problem! thanks all the same.
-
i recently upgraded my OS, all my data is backed up on my laptop, to restore the data i need to enter the password to my phone data backup, which i forgot, is there anyway i could get back?
No. If there was a way of getting hold of the password, it wouldn't be much of a security system, would it? The backup is lost if you can't remember.
-
I tried to write my own Date formatter (something like oracle.jbo.format.DefaultDateFormatter).
It's name is or.jbo.format.DateFormatter. But when I started my JSP DataTags page, when my Date attribute should be rendered, I get ClassNotFoundException error:
oracle.jbo.JboException: JBO-29000: Unexpected exception caught: oracle.jbo.JboException, msg=JBO-29000: Unexpected exception caught: java.lang.ClassNotFoundException, msg=or.jbo.format.DateFormatter void oracle.jbo.JboException.(java.lang.Throwable) java.lang.String oracle.jbo.server.AttributeDefImpl.getFormattedAttribute(oracle.jbo.AttributeList, oracle.jbo.LocaleContext) java.lang.String oracle.jdeveloper.html.HTMLFieldRendererImpl.getHTMLValue(oracle.jbo.Row, oracle.jbo.AttributeDef) java.lang.String oracle.jdeveloper.html.HTMLFieldRendererImpl.getHTMLValue(oracle.jbo.Row)
But I am definitely sure my class (oracle.jbo.format.DefaultDateFormatter) IS in the classpath....
So I am absolutely confused...
This behavior were inside Oracle OC4J container.
I tried run it inside Tomcat and there are not ClassNotFoundException.... So it is problem of OC4J??
Thank you very much for any comments
Jan PechanecThank you for your answer.
I tried to put my class to client project (there is .class file inside classes directory - I'm sure). But there is the same problem.
I tried following:
Put inside DataTableComponent.jsp following lines:
<%
Class c = Class.forName("or.jbo.format.DateFormatter");
%>
And ClassLoader found my class "or.jbo.format.DateFormatter" (I saw value of variable 'c' in the watch.).
But then (while rendering data table) there was the same excetion (JBO-29000: Unexpected exception caught: java.lang.ClassNotFoundException, msg=or.jbo.format.DateFormatter) - see above.
I checked the name of class hundred times, and it is right ...
I am still confused. Have you same idea, what's the problem?
Thank you
Jan Pechanec
PS. I'm using JDev 9.0.2
PS2. I haven't source code of oracle.jbo.server.AttributeDefImpl, co I can't debug it properly... -
Hi,
We are using a basic version of Sharepoint 2007 and do not have access to InfoPath. I have created a list to allow team members to submit their weekly time on specific activities. How do I go about tracking any changes to previously submitted data?
For instance, a team member enters 5 hours for Activity 1 and submits on April 1. on April 10 they realize they submitted too few hours and want to go in to edit the 5 hours to 12 hours.
From a reporting perspective we already pulled a report (export to excel) and have the 5 hours listed for April 1. If the user goes in to edit their time sheet from April 1, we don't want the data to just override the 5 hours, we want some sort of flag to
show the hours went from 5 to 12 hours. How do we do this?
As a work around, I added a question at the beginning of the survey/list asking is this a new submission or an edit. I thought if they select edit and were taken to a screen that allowed them to select the date (April 1), the activity and the new hours that
I would have all of the previous data plus these 3 columns with the additional data: "Edit", "Activity 1", "12". Instead the original data was over written and all I show are blanks for the previous questions and the edited
info ("Edit", "Activity 1", "12").
What suggestions do you have so that I can maintain the integrity of the original data and flag for my Project Manager which data needs to be changed in previous reports.
Thanks in advance!
AAI think the best way to answer your question would be to create a simple form and try various submissions. Be aware that unless the e-mail system is controlled, e-mail submission is not recommended due to client configuration issues of e-mail. Your question sounds like online submission would already be something you are comfortable with. In that case you can submit form data in 3 different ways: HTML, FDF, or XML. It can also be submitted as a PDF by saving the form, but that does not sound like what you need and also gets into issues of whether folks are using Reader or Acrobat.
Also be careful (or try both) about using forms from within Acrobat and the forms created by the link in Acrobat to Designer. Once you go to Designer with the form you can not come back for editing in Acrobat. Normally you would create the basic form in a word processor or layout tool and then add the form fields in Acrobat (or Designer if that is preferred).
I will let others address the anonymous and yet confirmation check issue. -
Internal hard drive not recognised, but has a lot of data i need on it!HELP
hi all
i'm on mac pro, quad core, leopard 10.5.2.
basically for some reason my hard drive was working fine, then one day last week i turned my mac back on and the hard drive will not initialize anymore.
i've gone into disk utility to try and repair disk. but it's listed there, not the name i gave it but 'disk1s1'.
i then go to verify disk and it comes up with this error.
*Verifying volume “disk1s1”*
* /dev/disk1s1*
*Invalid BS_jmpBoot in boot block: fa31c0*
*Error: Filesystem verify or repair failed.*
so i started looking for data recovery software, i found one called data rescue and its found alot of data on it, some i dont need (like stuff i deleted a long time ago), but i have 3 logic project folders full of projects i need to get finished for releasing!
but the thing with data rescue is... it is renaming all the fle aiff001, aiff002 etc etc, and for logic files this is no good as you need the files named as they were other wise it won't recognise the files and all the individual parts won't load up!
so i need a way of either making the mac recognize my hard drive again so i can drag everything off it and reformat it, or use a data recovery software that does not rename the files?
can anybody please HELP!
cheers
BOOM!
Message was edited by: boomboom1980orangekay wrote:
SMART is largely snake oil in implementation and practice and it's entirely commonplace for a dead drive to report itself functional and vice versa. I've seen Seagates whose heads were audibly grinding against the platters claim they were functioning normally, and I've seen others that said they were failing go on to provide years of reliable service. SMART status is a ballpark guess at best.
yes I understand that but I wouldn't trust a drive with a non-verified SMART status. as you say, it might continue to function but chances are pretty high that it will soon fail altogether. that's already happened to the OP who should consider himself lucky he can get anything off the drive at all with Data rescue. professional data recovery is of course also an option but a very expensive one. at least when I tried to use a service like this once about 5 years ago they wanted to charge me a small fortune. not sure what that would cost these days...
Maybe you are looking for
-
Somehow hdmi and dvi cables cause random blackouts when not playing games. When i start playing game, it tends to blackout a few times then complete pitch black. The vga cable works. Any idea?
-
Topology Services Applet error: "No JRE found in configuration file."
Is there an issue with IE7 and opening up Topology Services? Or can someone guide me in fixing this error message? I'm using LMS 3.1 and had uninstalled all of my Java versions and installed jre-6u5-windows-i586-p_withjacorb.exe on my client. However
-
SHOW h:message giving problem
Hi every body , I am facing one peculiar problem in my App. I am validating some textfields , radiobuttons , checkboxes by JSF (I am using JSF 1.1) simple validation (by required "true") and showing message by h:message .But when I am pressing the SU
-
Trying to edit HTML Template in SMW0
I am trying to revise URLs in HTML templates in the SAP Web Repository. I my MIME settings are configured. I say change, it prompts me for a transport, I then revise the HTML and say SAVE, then close. But, when I reopen the template the new HTML is n
-
Where can I download free Java Libraries supporting FTPS(FTP+SSL)
as the title, thanks!