SetString(1,"TO_DATE('2004-01-17','YYYY-MM-DD')"); Will that work
Hi all,
Can you tell me whether I can have whole SQL sections in my setXXX methods when
using PreparedStatements?
setString(1,"TO_DATE('2004-01-17','YYYY-MM-DD')");I thought I had my program working with such a statement, but now when I try it
it doesn't work but rather give me the following error:
ORA-01858: a non-numeric character was found where a numeric was expected
SQL would be i.e. "INSERT INTO myTest (myDate) VALUES (?)"
Something peculiar I found was this:
In my pstmt's SQL is the following:
INSERT INTO myTable (myInt,myDate) VALUES (?,TO_DATE(?,'YYYY-MM-DD'))
pstmt.setString(1,'1'); //for the int using Oracle for converting
pstmt.setString(2,'2005-01-17'); // this what I would normally use
But I had run into problem where myDate was supposed to be NULL,
that's why I posted the initial question about putting SQL into the setXXX
statement. But, what I found was that I could instead also put in a setDate
in place of the setString:
pstmt.setDate(2,null); // This will work even though I have the TO_DATE
Why would that be? Will the pstmt simply ignore the TO_DATE statement?
dailySun
Similar Messages
-
Just received a new Imac running OS10.8 Mountain Lion. I have MS Office 2004 that ran ok on OS 10.6 Snow Leopard. I'm told that this software will not work on the new OS. Are there any work arounds?
Nancy L F wrote:
Just received a new Imac running OS10.8 Mountain Lion. I have MS Office 2004 that ran ok on OS 10.6 Snow Leopard. I'm told that this software will not work on the new OS. Are there any work arounds?
... and have only used Word and hate to try to learn something new if not necessary.
The dirty little secret that they are keeping from you, is YES, there is a way to continue to use Microsoft Office's Word 2004 in Mountain Lion!
It is to install Snow Leopard Server into Parallels 8 on your new Mac and then install and run Word 2004 there:
[click on images to enlarge]
Apple is now selling Snow Leopard Server for $19.99 + sales tax & shipping costs at 1.800.MYAPPLE (1.800.692.7753) - Apple Part Number: MC588Z/A (telephone orders only). Parallels 8 retails for $79 but can be found for less searching for discounts on the internet.
Personally I hate the way Microsoft has changed Word 2008 and Word 2011, because I was 100% comfortable with how Word 2004 was setup and utilized. There is a learning curve to both of these upgrades and a more steeper one to the "free" alternatives that were suggested to you.
In a perfect world, you should upgrade to Office 2011; I did (actually it was a gift, but the price was not an object for me anyway). But the world is not perfect...
So, if, like me, there are times that you are most comfortable operating in the Word 2004 environment, my suggestion offers you a easy, stable, relatively inexpensive means to continue to do so in Mountain Lion.
GOOD LUCK! -
Lion - 2004 MS Office for Mac will not work
My 2004 version of Microsoft Office for Mac will not work in Lion. I suspect because this is a PowerPC application. My question is this:
Is there any program out there which will map the PowerPC to an Intel format? Other than trying to seel more products, I am surprised that Apple does not supply a mapping program for products made by Microsoft for the Apple devices.Eric, can you tell me where please? It's not mentioned on the Lion compatibility pages at all. (http://www.apple.com/uk/macosx/what-is/compatibility.html) nor on the 'how to upgrade' page (http://www.apple.com/uk/macosx/how-to-buy/)
-
I just upgraded my iMac to 10.6.8. Now my Microsoft office applications,(word, excel, ppt) and my camera software to transfer picts from my camera will not launch. (Separate apps but all stopped working as soon as I upgraded from 10.5.8). The software for the Canon Powershot is Ver.37.2. Image browser 6.2 EOS utility 1.1. Any help would be appreciated.
Also if you could tell me what happens to the individual jpegs that get imported through iPhoto, I would go back to using that instead of the Canon software. I want to be able to go into a folder and see all the jpegs and not have to rely on iPhoto's one enormous file. What happens if that iPhoto file gets corrupt? Thanks, LeeshaLeesha wrote:
I just upgraded my iMac to 10.6.8. Now my Microsoft office applications,(word, excel, ppt) and my camera software to transfer picts from my camera will not launch. (Separate apps but all stopped working as soon as I upgraded from 10.5.8).
Actually, Microsoft Office 2004 works fine with Snow Lepoard OS 10.6.x. However, it does require Rosetta, Apple's app for Classic apps. In your upgrade from Lepoard 10.5.8, Rosetta may not have installed but you can manually install it with the instructions here.
On another note, when upgrading the OS, some anomalies get resolved by repairing disk permissions with Disk Utility in the Utilities folder.
One more note, there was an issue with Rosetta crashing with OS 10.6.8 in February 2012. Apple released a security update that fixed it. You can see if Software Update (launch from the Apple menu) shows it or manually download Security Update 2012-001 v1.1 and install it. Software Update will also show other applicable apps available for updating for your upgraded system.
Rosetta is no longer available with OS 10.7 Lion and beyond. Then you will need to upgrade MS Office 2011 for Mac.
HTH -
NW 2004's getting port 443 on unix to work ??
I have loaded 2004s portals in my DEV system, (server at our data center at another site)every thing works ok, change the port from 50101 to 443 in VM but can not get to the server on that port. I believe it a UNIX problem because I know that ports under 1024 on unix are reserved.
How can I get Unix to now let my portales to use port 443.
Thanks for any help.
DarylHi Maurice,
Please check this url.
http://help.sap.com/saphelp_nw04s/helpdata/en/ce/9b673b079b4054e10000000a11405a/content.htm
Please award points for useful answers.
Regards.
Ruchit. -
SAP Netweaver 2004 [and] I.E 7 CONTEXT Menu not working??
Hello there,
Installed: SAP NetWeaver 7.0 (2004s) SPS 15
For some reason when I use Internet Explorer7 browsing the SAP Netweaver Portal. At the Content Administration>>RightClick on <Portal Content> is not working?
Like I mean, I am unable to open up the tiny context menu where you get the options: [New, Open, Refresh, Change ID]
But, when I use Firefox 3 everything is working fine. I can see the context menu opening up, but not in the case of I.E 7.
I got the latest Java SDK installed: j2sdk1.4.2.18
Please note: I previously had j2sdk1.4.2.09 which didnt fix the above issue. So, I thought upgrading the Java SDK would fix my issue.. but, it did not.
My O.S: Windows XP SP2.
Any of you had this issue in the past ? Found solution?
Can you please let me know?
Thanks
Dino.
Edited by: Dino R. on Jul 24, 2008 12:46 AM
Edited by: Dino R. on Jul 24, 2008 12:46 AM
Edited by: Dino R. on Jul 24, 2008 12:53 AMHi Dino,
The problem is not with the SAP NetWeaver 7.0 (2004s) SPS 15 but with the browser Internet Explorer7. We have also faced this problem then we installed IE 6. And it started giving the context menu.
regards,
Swati -
''Duplicate post, continue here - [https://support.mozilla.com/en-US/questions/785589]''
when i tried to upgrade in the past, i could access NOTHING. the only upgrade that would work with my mac osx 10.3.9 was the firefox 2.0.0.20.
please let me know which of your upgrades will work with my operating system.
i cannot lose contact with all my accounts. that is what happened the last time i tried to upgrade.Firefox 2.0.0.20 is the last version of Firefox that works on OS X 10.3.9
There are some alternative browsers you can try:
* iCab - http://www.icab.de/dl.php
* Classilla - http://www.floodgap.com/software/classilla/
* SeaMonkey 1.19 - http://www.seamonkey-project.org/releases/seamonkey1.1.19/ -
Inserting dates using TO_DATE and getDateTime with preparedStatement
Hi
I have this code here but its giving error msg, *"Cannot find symbol" Symbol: method TO_DATE(...)* . Can someone point to me what is wrong??
public static void pstmtQry(Connection con) {
try{
queryTable1 =" INSERT INTO Table1 "
+ "(DATE, ID) "
+ " VALUES (?, ?)";
pstmtTable1 = con.prepareStatement(queryTable1);
catch.......{
method1() {
try {
pstmtTable1.setString(1,*TO_DATE*(getDateTime("dd/MM/yyyy"), "DD/MM/YYYY"));
pstmtTable1.setString(2,ID);
RS = pstmtTable1.executeQuery();Thanks
Edited by: okun on Jun 9, 2010 9:02 PM
Edited by: okun on Jun 9, 2010 9:03 PMBelow is the query i would like to change to a preparedStatement:
query = " INSERT INTO Table1 "
+ "(DATE, ID) "
+ " VALUES ( TO_DATE('"
+ getDateTime("dd/MM/yyyy") + "','DD/MM/YYYY') "', '"
+ ID + "')";{code} -
How to convert date (dd/mm/yyyy) to week no. calendar?
hi all,
I have a question about if user enters 12/12/2004(dd/mm/yyyy), which week is that? I just know week no. should from 01 to no more than 53. How to convert date to week no.?
Thanksselect to_char(sysdate,'IW'),to_char(sysdate,'wW') from dual;
for IW, the week 2 starts on the first monday after 1.Jan, for WW, the week 2 starts on 8. Jan.
HTH
Laurent Schneider
OCM DBA -
Hi All-
Didn't see a forum for Power Point 2004 problems, so hope its ok to start here:
I created a PPT presentation with mostly inserted "photos from file", then added a few QuickTime video clips, several MB's each, added some graphics here and there, and saved it all to my desktop; total size of file is now 12 MB. The problem occured when I re-started my computer, after being in sleep mode only, the entire time during creation of the file.....when I tried to open my ppt presentation I received an error message that states 'Can not open file because file is either corrupt, in use, or in a format that PPT doesn't recognize.'
I've tried opening it by dbl-clicking on icon, holding down CTRL + click and OPEN WITH, and have also tried OPEN from the FILE menu within PPT, and all with the same error message. Also tried from the MOST RECENT list.
If I put it on the 'Network' at work and try to open it on a co-workers PC, will that work? and if not, what else can I try?? This was meant to be a xmas gift to my family back home in the states!
Thank you so much for any help you offer......
Cheers,
prana72
iBook G3 clamshell Mac OS X (10.4.2)Prana72,Welcome to Apple Discussions. There won't be a Forum for Powerpoint as these forums are for Apple made products - although you're more than welcome to discuss other items like that here.
I've never come across a file getting corrupted whilst sat on the desktop it sounds very like this has actually happened. I would try opening it with another version of Powerpoint. Have you set Office to create back-up files of everything (perhaps you should in future?).
I would also open Applications > Utilites > Disk Utility and click 'Repair Permissions'.
mrtotes -
Flat file to Oracle Database - Invalid Month
Hi All
I am New to XI and trying to create a simple interface between Legacy system (flat file) and Oracle database.
I have some date fields in the Oracle table.
When i run the interface it says "invalid month" with some SQL exception number.
I am using (mm/dd/yyyy) format for the date.
Is there any conversion i need to do. I am using XML SQL format for Oracle database.
Any help is appreciated.
Thanks
NagakishoreHello,
Oracle is very picky with the way date is stored. Assume that you have a field datefield that you need to save. In mapping add an attribute hasqQuote and set it to "NO". When mapping the value to the node use to_date as shown below.
<DateField hasQuot="No">
TO_DATE("2004-07-20", "yyyy-mm-dd hh:mi:ss")</DateField>
cheers,
Naveen -
Historical and transaction data in the same tables creates perf problems
Our Oracle based application is slow partly due to the fact that historical data are kept in the same table as transactional data. For example records about deceased patients, patients treated 5 years ago...etc, are kept in the one and only one patient table, which is needed to run the daily process of the hospital. So gradually all our major tables PATIENTS, CHARTS, NAMES, APPOINTMENTS have grown very large and since most of our SQL join all these tables at the same time, then all screens and reports run very slowly. I have introduced the idea that we should split all these tables in two: historical PATIENTS data, and CURRENT PATIENTS data...the same with all the others. A nice system would first search in the smaller transactional tables, which would run faster being smaller, and if no data found, then fallback to the historical tables. But this would require programming. From what I have read mateialized view could solve part of our problem. We could have views containing for example only one year worth of the data, and I guess any changes could be later replicated in the base table. What I dont know is what to do if we cannot find the patient in the matealized views ? Do I need to fallback to another SQL which will search in the initial base tables ? Anyway we can implement this without programming ? Tx.
Appointment table: 207,470
Visit table: 5,890,920
Patient table: 2,993,129
Chart table: 2,864,069
Patient names table: 3,938,118
SELECT
APPOI_OR_VISIT,
VISIT_SEQ,
PAT_SEQ,
INST_CODE,
INST_CODE_DISPL,
INST_DESC,
CLINIC_CODE,
CLINIC_CODE_DISPL,
CLINIC_DESC,
SPEC_CODE,
SPEC_CODE_DISPL,
SPEC_DESC,
VISIT_DATE,
VISIT_TIME,
VISIT_TIME_ARRIVAL,
APPTYPE_CODE,
SESSION_DOM_MODE,
PRESTYPE_CODE,
PRESTYPE_DOM_TYPE,
DIA_CODE,
VISIT_TIME_START_RESP,
VISIT_TIME_DISCHARGE,
APPOI_NB_DURATION,
VISIT_TX_REASON,
VISIT_TX_COMMENT,
EXTDOC_CODE,
VISIT_PN_REFPHYS_NAME,
PATYPE_CODE,
PAYRESP_CODE,
VISIT_IND_GROUP,
VISIT_PCODE,
VISIT_IND_COMPLETE,
VISIT_IND_ADMISSION,
VISIT_IND_CONFIDENTIALITY,
VISIT_DATE_ACCIDENT,
APPOI_SEQ,
BILLING_CODE,
VISIT_TX_DIAGNOSIS,
CST_CODE_1,
CST_CODE_2,
CST_CODE_3,
APPOI_DH_CRE,
APPOI_CODE_CRE_USER,
APPOI_DH_MOD,
APPOI_CODE_MOD_USER,
VISIT_CODE_CRE_USER,
VISIT_DH_CRE,
VISIT_UPDATED_COUNT,
VISIT_CODE_MOD_USER,
VISIT_DH_MOD,
APPOI_PAYRESP_CODE,
APPOI_DT_ACCIDENT,
PATIENT_LAST_NAME,
PATIENT_FIRST_NAME,
PATIENT_CONFIDENTIALITY,
PATIENT_CHART_EXT,
TO_NUMBER(SUBSTR(PATIENT_CHART_EXT, 1, INSTR(PATIENT_CHART_EXT, '|')-1)) AS PATIENT_CHART_NO,
PAT_IND_SPECIAL_RISK
FROM
SELECT
'VISIT' AS APPOI_OR_VISIT,
VISIT.VISIT_SEQ,
VISIT.PAT_SEQ,
INSTITUTION.INST_CODE,
INSTITUTION.INST_CODE_DISPL,
INSTITUTION.INST_DESC,
CLINIC.CLINIC_CODE,
CLINIC.CLINIC_CODE_DISPL,
CLINIC.CLINIC_DESC,
SPECIALTY.SPEC_CODE,
SPECIALTY.SPEC_CODE_DISPL,
SPECIALTY.SPEC_DESC,
VISIT.VISIT_DATE,
VISIT.VISIT_TIME,
VISIT.VISIT_TIME_ARRIVAL,
VISIT.APPTYPE_CODE,
VISIT.SESSION_DOM_MODE,
VISIT.PRESTYPE_CODE,
VISIT.PRESTYPE_DOM_TYPE,
VISIT.DIA_CODE,
VISIT.VISIT_TIME_START_RESP,
VISIT.VISIT_TIME_DISCHARGE,
VISIT.APPOI_NB_DURATION,
VISIT.VISIT_TX_REASON,
VISIT.VISIT_TX_COMMENT,
VISIT.EXTDOC_CODE,
VISIT.VISIT_PN_REFPHYS_NAME,
VISIT.PATYPE_CODE,
VISIT.PAYRESP_CODE,
VISIT.VISIT_IND_GROUP,
VISIT.VISIT_PCODE,
VISIT.VISIT_IND_COMPLETE,
VISIT.VISIT_IND_ADMISSION,
VISIT.VISIT_IND_CONFIDENTIALITY,
VISIT.VISIT_DATE_ACCIDENT,
VISIT.APPOI_SEQ,
VISIT.BILLING_CODE,
VISIT.VISIT_TX_DIAGNOSIS,
VISIT.CST_CODE_1,
VISIT.CST_CODE_2,
VISIT.CST_CODE_3,
VISIT.APPOI_DH_CRE,
VISIT.APPOI_CODE_CRE_USER,
VISIT.APPOI_DH_MOD,
VISIT.APPOI_CODE_MOD_USER,
VISIT.VISIT_CODE_CRE_USER,
VISIT.VISIT_DH_CRE,
VISIT.VISIT_UPDATED_COUNT,
VISIT.VISIT_CODE_MOD_USER,
VISIT.VISIT_DH_MOD,
NULL AS APPOI_PAYRESP_CODE,
TO_DATE(NULL) AS APPOI_DT_ACCIDENT,
NAME.NAM_PN_NAM AS PATIENT_LAST_NAME,
NAME.NAM_PN_FNAM AS PATIENT_FIRST_NAME,
CONFIDENTIALITY.CONF_DESC AS PATIENT_CONFIDENTIALITY,
PI_SECURITY.F_GET_CHART_NUMBER_SCAN_CODE(VISIT.PAT_SEQ, 103 /*:pChartInstitutionID*/, 0) AS PATIENT_CHART_EXT,
PATIENT.PAT_IND_SPECIAL_RISK
FROM
AS_T_VISITS VISIT,
CT_R_INSTITUTIONS INSTITUTION,
AS_T_CLINICS CLINIC,
CT_R_SPECIALITIES SPECIALTY,
PI_T_NAMES NAME,
PI_T_PATIENTS PATIENT,
PI_R_CONF_LEVELS CONFIDENTIALITY
WHERE
VISIT_DATE >= TO_DATE('2004-04-01', 'YYYY-MM-DD') /*:P_VISIT_DATE_FROM*/ AND
VISIT_DATE <= TO_DATE('2004-04-02', 'YYYY-MM-DD') /*::P_VISIT_DATE_TO*/ AND
CLINIC.CLINIC_CODE = VISIT.CLINIC_CODE AND
SPECIALTY.SPEC_CODE = CLINIC.SPEC_CODE AND
INSTITUTION.INST_CODE(+) = VISIT.INST_CODE AND
NAME.PAT_SEQ = VISIT.PAT_SEQ AND
NAME.NAMTYP_CODE = 1 AND
PATIENT.PAT_SEQ = VISIT.PAT_SEQ AND
CONFIDENTIALITY.CONF_CODE (+) = PATIENT.CONF_CODE
UNION
SELECT
'APPOI' AS APPOI_OR_VISIT,
0 AS VISIT_SEQ,
NVL(APPOINTMENT_GROUP.PAT_SEQ, APPOINTMENT.PAT_SEQ) AS PAT_SEQ,
INSTITUTION.INST_CODE,
INSTITUTION.INST_CODE_DISPL,
INSTITUTION.INST_DESC,
CLINIC.CLINIC_CODE,
CLINIC.CLINIC_CODE_DISPL,
CLINIC.CLINIC_DESC,
SPECIALTY.SPEC_CODE,
SPECIALTY.SPEC_CODE_DISPL,
SPECIALTY.SPEC_DESC,
APPOINTMENT.SESSION_DATE AS VISIT_DATE,
APPOINTMENT.APPOI_TIME AS VISIT_TIME,
'' AS VISIT_TIME_ARRIVAL,
APPOINTMENT.APPTYPE_CODE,
APPOINTMENT.SESSION_DOM_MODE,
0 AS PRESTYPE_CODE,
'' AS PRESTYPE_DOM_TYPE,
0 AS DIA_CODE,
'' AS VISIT_TIME_START_RESP,
'' AS VISIT_TIME_DISCHARGE,
APPOINTMENT.APPOI_NB_DURATION,
APPOINTMENT.APPOI_TX_REASON AS VISIT_TX_REASON,
APPOINTMENT.APPOI_TX_COMMENT AS VISIT_TX_COMMENT,
APPOINTMENT.EXTDOC_CODE,
APPOINTMENT.APPOI_PN_REFPHYS_NAME AS VISIT_PN_REFPHYS_NAME,
APPOINTMENT_TYPE.PATYPE_CODE AS PATYPE_CODE,
0 AS PAYRESP_CODE,
DECODE(APPOINTMENT_GROUP.PAT_SEQ,NULL,0,1) AS VISIT_IND_GROUP,
'' AS VISIT_PCODE,
0 AS VISIT_IND_COMPLETE,
0 AS VISIT_IND_ADMISSION,
APPOINTMENT.APPOI_IND_CONFIDENTIALITY AS VISIT_IND_CONFIDENTIALITY,
TO_DATE(NULL) AS VISIT_DATE_ACCIDENT,
APPOINTMENT.APPOI_SEQ,
0 AS BILLING_CODE,
'' AS VISIT_TX_DIAGNOSIS,
0 AS CST_CODE_1,
0 AS CST_CODE_2,
0 AS CST_CODE_3,
APPOINTMENT.APPOI_DH_CRE AS APPOI_DH_CRE,
APPOINTMENT.APPOI_CODE_CRE_USER AS APPOI_CODE_CRE_USER,
APPOINTMENT.APPOI_DH_MOD AS APPOI_DH_MOD,
APPOINTMENT.APPOI_CODE_MOD_USER AS APPOI_CODE_MOD_USER,
'' AS VISIT_CODE_CRE_USER,
SYSDATE AS VISIT_DH_CRE,
0 AS VISIT_UPDATED_COUNT,
'' AS VISIT_CODE_MOD_USER,
SYSDATE AS VISIT_DH_MOD,
PAYRESP_CODE AS APPOI_PAYRESP_CODE,
APPOI_DT_ACCIDENT,
NAME.NAM_PN_NAM AS PATIENT_LAST_NAME,
NAME.NAM_PN_FNAM AS PATIENT_FIRST_NAME,
CONFIDENTIALITY.CONF_DESC AS PATIENT_CONFIDENTIALITY,
PI_SECURITY.F_GET_CHART_NUMBER_SCAN_CODE(APPOINTMENT.PAT_SEQ, 103 /*:pChartInstitutionID*/, 0) AS PATIENT_CHART_EXT,
PATIENT.PAT_IND_SPECIAL_RISK
FROM
AS_T_APPOINTMENTS APPOINTMENT,
AS_R_APPOINTMENT_TYPES APPOINTMENT_TYPE,
AS_T_CLINICS CLINIC,
CT_R_SPECIALITIES SPECIALTY,
CT_R_INSTITUTIONS INSTITUTION,
AS_T_APPOINTMENT_GROUPS APPOINTMENT_GROUP,
PI_T_PATIENTS PATIENT,
PI_R_CONF_LEVELS CONFIDENTIALITY,
PI_T_NAMES NAME,
AS_T_APPOINTMENT_SEQ_MAPPING SEQMAP
WHERE
SESSION_DATE >= TO_DATE('2004-04-01', 'YYYY-MM-DD') /*:P_VISIT_DATE_FROM*/ AND
SESSION_DATE <= TO_DATE('2004-04-02', 'YYYY-MM-DD') /*::P_VISIT_DATE_TO*/ AND
APPOINTMENT.APPOI_DOM_TYPE IN('A','AR') AND
CLINIC.CLINIC_CODE = APPOINTMENT.CLINIC_CODE AND
SPECIALTY.SPEC_CODE = CLINIC.SPEC_CODE AND
INSTITUTION.INST_CODE(+) = APPOINTMENT.INST_CODE AND
APPOINTMENT_GROUP.APPOI_SEQ (+) = APPOINTMENT.APPOI_SEQ AND
APPOINTMENT_TYPE.APPTYPE_CODE (+) = APPOINTMENT.APPTYPE_CODE AND
NAME.PAT_SEQ = NVL(APPOINTMENT.PAT_SEQ, APPOINTMENT_GROUP.PAT_SEQ) AND
NAME.NAMTYP_CODE = 1 AND
PATIENT.PAT_SEQ = NVL(APPOINTMENT.PAT_SEQ, APPOINTMENT_GROUP.PAT_SEQ) AND
CONFIDENTIALITY.CONF_CODE (+) = PATIENT.CONF_CODE AND
SEQMAP.APPOI_SEQ (+) = APPOINTMENT.APPOI_SEQ AND
SEQMAP.APPOI_SEQ IS NULL
ORDER BY
VISIT_DATE, VISIT_TIME, PATIENT_CHART_NO -
Most efficient way to query dates
Hi!
Just wondering if anyone know the quickest or best way to to date comparisons with Oracle. Ie does it take longer for oracle to convert the input date from the inputted date to a date it can use to compare. eg
iuser.CreateDate <= to_date('07:Dec:2004:11:59:59:PM', 'DD:MON:YYYY:HH:MI:SS:AM')
OR
iuser.CreateDate <= to_date('07:12:2004:11:59:59:PM', 'DD:MM:YYYY:HH:MI:SS:AM')Hello,
I have two comments:
a) what about to use only "<" operator with next day instead of "<="
iuser.CreateDate <= to_date('07:Dec:2004:11:59:59:PM', 'DD:MON:YYYY:HH:MI:SS:AM')
iuser.CreateDate < ('08:Dec:2004', 'DD:MON:YYYY')
b) I think that more faster could be passing the comparision date as date parameter iuser.CreateDate < :inp_test_date.
sasa -
Hi all!
I need export different tables from my 10.2.0.4 database using expdp. Some of this tables, needs be under different conditions. How can I prepare my parameter file for this export?
Table1 --> query: where valid=1
Table2 --> query: where valid=1 and secure=0
Table3 --> query: where valid=1 and secure=1
Thanks a lot!!!I'm a bit confused about parameter file ...
*1. ways to export*
There are 3 ways to export, you can use parameter file but there is no need for it (personally I never use it)
a. using expdp
b. using PL/SQL
c. external table
*2. what to export*
you simply use QUERY clause to specify where conditions, for example if you want to use (a) then it would look like this
$ expdp query=employees:"where salary>10000" tables=employeesif if you want to use parameter file
TABLES:emp_salary
DUMPFILE=dump_dir
QUERY= emp_salary:"WHERE emp_id IN (SELECT id from emp
where join_date> to_date('2004-01-01','YYYY-MM-DD')
AND dept='SALSE')"here are some useful links
Part I http://www.orafaq.com/node/65
Part II http://www.orafaq.com/node/67
Part III http://www.orafaq.com/node/74
http://www.rampant-books.com/art_nanda_datapump.htm -
I'm trying to update a table using a PreparedStatement. Always receive the following SQL exception : ORA-01858: a non-numeric character was found where a numeric was expected. I send my date parameter has a string and try to convert them using the TO_CHAR/TO_DATE function.
String psQuery = "update requ_ord set adj_horizon_date=? where ...";
PreparedStatement pSt = conn.prepareStatement(psQuery);
pSt.setString(1, "TO_DATE('2000-03-10', 'YYYY-MM-DD')");
pSt.execute();
nullHi,
Your SQL statement is equivalent to
update xxx set sdate='TO_date('2000-01-01','yyyy-mm-dd')'
Above statement will give same error which you were getting..
what you can do is change your sql statement to
String psQuery = "update requ_ord set adj_horizon_date=to_date(?,'yyyy-mm-dd') where ...";
Suresh
null
Maybe you are looking for
-
NEW ITUNES 10.7 UPDATE DOES NOT WORK
OK PEOPLE AT APPLE.....ALL I SEE ARE QUESTIONS RELATED TO THE NEW UPDATE ITUNES 10.7..I WAS ON THE PHONE FOR 2 HOURS YESTERDAY WITH TECHNICAL SUPPORT..AND THEY COULDNT EVEN FIX THE PROBLEM......SINCE I DOWNLOADED THE UPDATED VERSION I CAN OPEN ITUNES
-
Composite Salary Survey/Survey Results
I'm looking for details information on how to configure Composite Salary Survey and Survey Results infotypes in HR ECM. Please let me know where can I find detail information. Thank you in advance. H
-
cannot open documents in "PAGES" app since upgrading from original ipad 3 software to 7.1.2. can anyone offer suggestions please?
-
In my CF form, I use <cfinput name="field_name" size="20" required message="this field is required"> to make a field required. Now I have to have a text area for free form entry. How can I make the textarea required also in CF (use javascript ?) and
-
SuperDuper! clone & Snow Leopard
In my MacPro I have a two 1tb HD setup where the 2nd drive is an exact clone of the 1st using 'Superduper!' When I installed 'Snow Leopard' I chose to replace the 1st HD and test the system for a week before making a new clone. Having done so without