PLSQL - to_date coded for the American date strings regardless of the machine?
I do a code to deal with some issues that originally come from an Excel... There are some fields being a string containing a date value. So my code is to take the string and turn it into a variable date so I can insert it into a date field Oracle. The format of the dates in Excel is like this: "DD/MONTH/YYYY" "MONTH" is written in American English.
So, if I do something like this:
Select to_date (April 1, 2013 ',' DD/MONTH/YYYY ')
in: myDate
OF THE DOUBLE
;
It works fine when I run it on my own machine English/American.
But... When I run the same on my client machine (which is in another country, Brazil)... I get an error "Invalid month.
Of course, if I had to do this:
Select to_date (' 01/ABR/2013 ',' MON/DD/YYYY "")
in: myDate
OF THE DOUBLE
;
Then it works fine.
And... It seems that even if their machine settings are Brazilian, they provide the date field in Excel (which they provide) in a USA-English format.
Then... What is a good way I can interpret their date field (which is in English)? I hope for a command that completes the to_date function that also tells the Oracle "interpret this" DD/MONTH/YYYY"format, where the MONTH is written in American English" regardless of work on a non-English machine?
Not sure it's what you're asking. Have you tried TO_DATE (April 1, 2013 ', ' DD/MONTH/YYYY', 'NLS_DATE_LANGUAGE = American') when inserting?
Tags: Database
Similar Questions
-
Not able to find drivers for the machine (hp 15-g009ax)
Hello
I'll try to find drivers for the machine HP (hp 15-g009ax) which runs on Windows 7 x 64, please find a snapshot of the devices that I need the drivers for.
The material I have. D of the ID of the hardware of these devices are listed below,
Ethernet controller
PCI\VEN_10EC & DEV_8136 & SUBSYS_22CE103C & REV_07
PCI device
PCI\VEN_10EC & DEV_5229 & SUBSYS_22CE103C & REV_01
PCI encryption/decryption controller
PCI\VEN_1022 & DEV_1537 & SUBSYS_15371022 & REV_00
SM Bus controller
PCI\VEN_1022 & DEV_780B & SUBSYS_22CE103C & REV_42
Please update me on the same I'll implement this machine for the first time.
Thanks in advance.
Concerning
David
Hello:
Here are links to the drivers you need:
PCI device:
Ethernet controller
SM Bus controller:
Here's what you need to do to the smbus controller...
I have zipped and attached below in attachments, the raw smbus controller driver files to decompress and install manually.
Download and unzip the file.
Go to Device Manager and click the controller smbus needing drivers. Click the driver tab. Click on set to update driver.
Select her browse my computer for driver software option and navigate to the driver folder that you unzipped.
Make sure that the include subfolders is selected and the driver should install. Then restart.
E/D PCI controller:
This driver should work and you need to install it manually as if auto installation does not get it.
To manually install this driver, click once on it follow the same steps as for the smbus controller but go to C:\SWSetup\sp66974.
The unknown device is no doubt this, but otherwise, I will need the hardware for this ID too...
-
IT IS POSSIBLE TO CHANGE THE CODING FOR THE DVD PLAYER REGION
is it possible to change the region coding on the dvd player
Yes, but only 5 times. It cannot be used to change the region to play a dvd, then changed back. After 5 it changes in locks
To change it, I think you do a right-click on the dvd drive and go to the tab (im not an atm computer) in the region.
-
Suggestion on Code PLSQL and concern for the Performance
Legends of dear,
We have the following code in place of a TRIGGER in a generation of report and as a Jr.DBA, I was able to analyze my development team does an AFTER DELETE or INSERT or UPDATE on a Table.
CREATE or REPLACE TRIGGER SOL_trigger
after delete or insert or update on SOL_MV
FOR EACH LINE
BEGIN
If the UPDATE can
UPDATE DIM_SOL
SET
DIM_SOL_ID =: new. DIM_SOL_ID,
ORGANIZATION_ID =:New.ORGANIZATION_ID,
SOL_ID =: new. SOL_ID,
CREATION_DATE =: new. CREATION_DATE,
..................
..................
where SOL_ID =: old. SOL_ID;
end if;
If the INSERTION
INSERT INTO DIM_SOL
VALUES)
: new. DIM_SOL_ID,
: new.ORGANIZATION_ID,.
: new. SOL_ID,
: new. CREATION_DATE,
...................
);
end if;
If REMOVE then
REMOVE FROM DIM_SOL
WHERE SOL_ID =: old. SOL_ID;
end if;
END;
/
My Question is:
1 will be this query gives any Performance issues when retrieving a large number of records as more than 100000. ?
2. this request may be adjusted better?
3 is there an order or sequence to perform an INSERTION DELETION or UPDATE? To avoid any competition or any other conflict?
4 or this request is better?
FYI--this request is now implemented and work very well so for. Just to acquire additional knowledge in terms of performance, I am looking for a better answer. Thanks in advance.
Thank you
Knockaert
c699f53e-f619-44F2-a5f7-3b1276d4f4d4 wrote:
My Question is:
1 will be this query gives any Performance issues when retrieving a large number of records as more than 100000. ?
By rΘcupΦre do you SELECT? SELECT has nothing to do with the trigger. The trigger code will not run when you run SELECT on the table.
2. this request may be adjusted better?
Query refers to the SELECT statement. I don't see any SELECT statement. What do you mean by query? The trigger code are you referring? I think the trigger code is simple and nothing much needs to be done.
3 is there an order or sequence to perform an INSERTION DELETION or UPDATE? To avoid any competition or any other conflict?
When the trigger is executed the event calling (insert, delete, or update) determines what part of the code in the trigger must be executed. All of them will not be executed in a single call. Its just one of the three.
4 or this request is better?
Still, once having no idea about what you're talking about. You use the query term very loosely without knowing its meaning, I suppose!
-
I try to write a compliance rule that can add an Active Directory group to a local group on a machine. For example the addition of our group of COMPUTER security in the local Administrators group on some machines.
Any help with this would be greatly appreciated.
DK
The name refers on behalf of the group, so the first line is correct, but you must change the other Member who appoints the members of the group. It would be like this, 'Member AS Server Ops % '. I'm guessing that server Ops is a security AD Group, then you could also do "members = DOMAIN\Server Ops. Usually best to select by pressing the 3 points and choosing from the available groups to make sure that you do not have typo and you have selected the correct attribute.
-
When I open a game or a program on my desktop, everything looks OK. But when online, I can't even see the entire page without moving around on the screen.
Check to see if you have Accessibility Options. It is often the cause of your problem. Control Panel > ease of access Center. If that does not resolve the issue, what browser are you using? IE, Firefox, etc. ? If IE, does the problem occur with Firefox? MS - MVP - Elephant Boy computers - don't panic!
-
Compensate for the div / positioning in IE problem
I posted this problem in another thread, but it was a sub-question. Anyway, the problem I have is positioned a div on all other divs. I managed to make it work perfectly on Firefox and Chrome as I wanted. The problem is usually when it comes to internet explore. I want just the image or the div on the right side of the site, but always placed by changing properties will give the same result, places of internet explore is far away where it is supposed to be. I'll add pictures, the code and the site below. Any help would be appreciated.
View of chrome:
View of Firefox:
* IE View (false):
Web site: http://emergencyclean-up.com
Code:
< ! DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional / / IN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" > ""
" < html xmlns =" http://www.w3.org/1999/xhtml ">
< head >
< meta http-equiv = "Content-Type" content = text/html"; charset = utf-8 "/ >"
< title > emergency Clean Up Homepage < /title >
< style type = "text/css" >
{body
background-color: #333333;
}
#entireSite #sidebar #spacer {}
height: 300px;
Width: 350px;
}
#entireSite #sidebar #newsletter {}
background-image: url (.. / Images/NewsLetterBackground.png);
height: 165px;
Width: 350px;
color: #FFF;
}
< / style >
< link hand. CSS"rel ="stylesheet"type =" text/css"/ >
"" < script src = "... / SpryAssets/SpryMenuBar.js" type = "text/javascript" > < / script >
< script type = "text/javascript" >
function MM_swapImgRestore() //v3.0 {}
var i, x = offline. MM_sr; for (i = 0; a & & I <.) Length & & (x = a [i]) & & x.oSrc; i ++) x.src = x.oSrc;
}
function MM_preloadImages() {//v3.0
var d = document; If (d.images) {if(!d.MM_p) d.MM_p = new Array();
var i, j is d.MM_p.length, a = MM_preloadImages.arguments; for (i = 0; i <.) Length; i ++)
If (a [i].indexOf("#")! = 0) {d.MM_p [j] = new Image; d.MM_p [j ++] .src = a [i] ;}}
}
function MM_findObj (n, d) {//v4.01
var p, i, x; if(!d) d = document; If ((p = n.IndexOf ("?")) > 0 & & parent.frames.length) {}
d = parent.frames [n.Substring(p+1)] .document; n = n.Substring (0, p) ;}
If (!) () x = d [n]) & & copyrights) x = d.all [n]; for (i = 0;! x & & i < d.forms.length; i ++) x = d.forms [i] [n];
for (i = 0;! x & & d.layers & & I < d.layers.length; i ++) x = MM_findObj (n, d.layers [i] .document);
If (! x & & d.getElementById) x = d.getElementById (n); Return x;
}
function MM_swapImage() {//v3.0
var i, j = 0, x, a = MM_swapImage.arguments; document. MM_sr = new Array; for (i = 0; i <(a.length-2); I += 3).
If ((x = MM_findObj (a [i]))! = null) {document. MM_sr [j ++] = x; if(!x.oSrc) x.oSrc = x.src; x.SRC = a [i + 2] ;}
}
< /script >
"" < link href = "... / SpryAssets/SpryMenuBarHorizontal.css" rel = "stylesheet" type = "text/css" / >
< / head >
< onload of the body = MM_preloadImages('..) ' / Images/Buttons/buttonOver_01.gif ','... / .png images/WaterDamageOver ','... / Images/FireDamageOver.png ','... / Images/MoldRemediationOver.png ','... / MovalOver.png images/SootRe ','... / Images/OdorControlOver.png ','... / Images/facebook - logoOver.png ','... / Image s/yelp - logoOver.png ','... / Images/LinkedIn_logoOver.png ','... '. Twitter/images /-logoOver.png') ">"
<!-it starts the encoding for the centering of the entire Web page->
< div style = "width: 100%;" >
< div style = "width: 900px; margin-left: auto; margin-right: auto; ">
< div style = "width: 100%;" float: left; background-color: #333333; ">
<! - this starts the background for the navbarArea layer - >
< div id = "navbarArea" >
<!-this starts the container div for the navigation bar->
< div align = "center" >
< div id = "navbar" >
< ul id = "MenuBar1" class = "MenuBarHorizontal" >
< li > < strong > < a href = "index.html" > Home Page < /a > < / strong > < /li >
< li > < strong > < a href = "On Us.html" > us < /a > < / strong > < /li >
< li > < strong > < a href = "Services.html" > Services < /a > < / strong > < /li >
< li > < strong > < a href = "Testimonials.html" > stories < /a > < / strong > < /li > ""
< li > < strong > < a href = "Us.html of Contact" > contact us < /a > < / strong > < /li >
< li > < strong > < a href = "Offers.html" special > offers special < /a > < / strong > < /li >
< /ul >
< / div > < / div >
<!-This completes the container div for the navigation bar->
< / div >
<! - This completes the background for the navbarArea layer - >
<!-this starts the entireSite area * excludes navbar *->
< div id = "entireSite" >
<! - this starts the container for the sidebar image - >
< div id = "sidebar" >
<! - it starts a div for spacing - >
< div id = "spacer" >
< / div >
<!-this ends a div for spacing->
<! - it starts div newsletter - >
< div id = "newsletter" >
< Center > < font size = "5" > subscribe to our Newsletter < / police > < / center >
< do action = "subscriptionform.php" method = "post" id = "Newsletter" > "
< table width = "100%" border = "0" cellpadding = "3" >
< b >
< td > name: < table >
< td > < input name = "News Letter Name" type = "text" size = "30" maxlength = "40" / > < table >
< /tr >
< b >
< td > Email: < table >
< td > < input name = "News Letter Email" type = "text" size = "30" maxlength = "40" / > < table >
< /tr >
< b >
< td > Zip Code: < table >
"" < td > < input name = "News Letter Postal Code" type = "text" size = "10" maxlength = "12" / > < table >
< /tr >
< /table >
Center of <>< input name = "Subscribing" type = "Submit" id = "subscribe" / > < / center >
< / make >
< / div >
<! - this bulletin ends div - >
< / div >
<!-This completes the bar area side image->
<! - this starts the maintext area - >
< div id = "maintext" >
<! - this starts the title within the maintext area bar - >
< div id = "title bar" >
< br / >
< / div >
<! - the ends of the title bar of maintext area - >
< br / >
"" Center of <>< img src = "... / Images/Logo.png" width = "500" height = "160" alt = "Logo" / >
< br / >
< br / >
< center > choose among our different services here for the emergency Clean-Up < /Center >
< br / >
< table width = "100%" border = "0" cellpadding = "0" >
< b >
"< td > < Center > < a href ="Damage.html water"MM_swapImgRestore" onmouseover = "MM_swapImage ('WD '", '... / Images/WaterDamageOver.png ', 1) "> < img src =" "... / pictures/WaterDamage.png" alt = "Water damage" name = "WD" width = height "75" = "75" border = "0" id = "WD" / > < /a > "
< br / >
Water damage < / center > < table >
"< td > < Center > < a href ="Damage.html fire"MM_swapImgRestore" onmouseover = "MM_swapImage ('FD '", '... / Images/FireDamageOver.png ', 1) "> < img src =" "... / pictures/FireDamage.png" alt = "Fire damage" name = "FD" width = "75" height = "75" border = "0" id = "FD" / > < /a > "
< br / >
Fire damage < / center > < table >
"< td > < Center > < a href ="Remediation.html Pan"MM_swapImgRestore" onmouseover = "MM_swapImage (' SIR '", '... / Images/MoldRemediationOver.png ', 1) "> < img src =" "... / pictures/MoldRemediation.png" alt = "Mold Remediation" name = "MR" width = "75" height = "75" border = "0" id = "MR" / > < /a > "
< br / >
Mold remediation < / center > < table >
"< td > < Center > < a href ="Removal.html of soot"MM_swapImgRestore" onmouseover = "MM_swapImage ('SR '", '... / Images/SootRemovalOver.png ', 1) "> < img src =" "... / Images/SootRemoval.png" alt = "Remove soot" name = "SR" width = "75" height = "75" border = "0" id = "SR" / > < /a > "
< br / >
Removal of soot < / center > < table >
"< td > < Center > < a href ="Control.html of the smell"MM_swapImgRestore" onmouseover = "MM_swapImage ('OC '", '..) " (/ Images/OdorControlOver.png',1) "> < img src ="... / pictures/OdorControl.png "alt ="Odor control"name ="OC"width ="75"height ="75"border ="0"id ="OC"/ > < /a >
< br / >
Odour control < / center > < table >
< /tr >
< /table >
< br / >
< Center > for more services please click < a href = "Services.html" > here < /a >. < /Center >
< / div >
<!-this ends the area-> maintext
<! - this starts the bottombar image - >
< div id = "bottombar" >
"" < img src = "... / Images/bottomBar.png" width = "900" height = "25" alt = "bottombar" / > < / div >
<! - this ends the image of the low bar - >
<! - this starts the hotlinks box - >
< div id = "hotlinks" >
"< a href =" # "MM_swapImgRestore" onmouseover = "MM_swapImage ('FB '", '... /Images/Facebook-logoOver.png',1) "> < img src =" "... /Images/Facebook-logo.png" alt = "Facebook" name = "FB" width = "25" height = "25" border = "0" id = "FB" / align = "left" > < / has > "
"< a href =" # "MM_swapImgRestore" onmouseover = "MM_swapImage ('YP '", '... /Images/Yelp-logoOver.png',1) "> < img src =" "... /Images/Yelp-logo.png" alt = "Yelp" name = "YP" width = "25" height = "25" border = "0" id = "YP" / align = "left" > < / has > "
"< a href =" # "MM_swapImgRestore" onmouseover = "MM_swapImage ('TR '", '... /Images/Twitter-logoOver.png',1) "> < img src =" "... /Images/Twitter-logo.png" alt = "Twitter" name = "TR" width = "25" height = "25" border = "0" id = 'B' / align = "left" > < / has > "
"< a href =" # "MM_swapImgRestore" onmouseover = "MM_swapImage ('LI '", '... / Images/LinkedIn_logoOver.png ', 1) "> < img src =" "... / Images/LinkedIn_logo.png ' alt = 'Linked In' name ="LI"width ="25"height ="25"border ="0"id ="LI"/ align ="left"> < / has >"
< / div >
<! - this end area of hotlinks - >
<! - this starts the field of copyright - >
< div id = 'copyright' >
< br / >
< p align = 'right' > content copyright 2012. EMERGENCYCLEAN - UP.COM. All rights reserved. < /p >
< / div >
<! - this end, the field of copyright - >
< / div >
<! - This completes the entireSite container - >
"" < div id = "containerEmergency" > < img src = "... / pictures / emergency contact.png" width = "220" height = "220" / >
< / div >
< / div >
< / div >
< / div >
<!-This completes the coding for the centering of the entire Web page * excludes navbar *->
< script type = "text/javascript" >
var MenuBar1 = new Spry.Widget.MenuBar ("MenuBar1", {imgDown: "..."}) "" / SpryAssets/SpryMenuBarDownHover.gif ', imgRight: ".. ({"/ SpryAssets/SpryMenuBarRightHover.gif"});
< /script >
< / body >
< / html >
A few steps to follow.
First make a backup copy of the file site just in case things go belly up and you need to revert to the original.
Add position: relative; to the
the bottom (as shown)Then move your
named "containerEmergency" directly below thewho added you position: relative; TO:Add z-index: 100; to the css "containerEmergency" as shown below:
{#containerEmergency}
height: 250px;
Width: 250px;
position: relative;
Top: 0px;
right: 0px;
left: 720px;
border-top-style: none;
border-right-style: none;
border-bottom-style: none;
border-left-style: none;
border-bottom-color: #F00;
border-right-color: #F00;
border-bottom-color: #F00;
border-left-color: #F00;
z-index: 100;
}
Add z-index: 2; to the css of 'entireSite ':
{#entireSite}
height: auto;
Width: 900px;
position: absolute;
top: 50px;
z-index: 2;
}
Add z-index: 1; to the css "navbar":
{#navbarArea #navbar}
background-color: #929BA0;
height: 40px;
Width: 900px;
position: relative;
top: 20px;
left: auto;
right: auto;
do-family: Arial, Helvetica, without serif.
do-size: 12px;
z-index: 1;
}
Now it should work ok in Internet Explorer.
-
Batch program - for the initializeThreadWork parameter null pointer exception
I'm a java program that receives some paramteres coding for the user batch screen and my logic for pick up/use of values is as follows:
1 using the method validateSoftParameters() of the batch class to retrieve the settings to public static variables: filePath = this.getParameters () .getFILE_PATH ();
2. in the initializeThreadWork() method of the Worker class static just use the static variable, not the parameter itself: fileWriter.openFile ( filePath, fileNameBuilder.toString ());
When I submit the batch of the online page, it seems that the validateSoftParameters method is not called if the variable cannot be set.
Issues related to the:
-Are there some reason that this method does not work?
-What is the flow of effective implementation of the methods abstract/ovirriden in order to decide where to put what logic according to the when the methods are called?
Thank you!
Published by: angelperez on February 16, 2011 07:14Hello
for a batch program, the settings that you have that you created don't appear in a class outter, you can add the parameters in the static inner class, it will be no exception nullpointter -
mouse left and right coding for games
Hello
Can someone point me in the right direction on where to find actionscript 2/3 coding for the left and right mouse click on the game. I am a student and want to design a game that uses the two left and right mouse click on an object which will give you different results depending on which mouse click, you did.
For example, on an object red you right click on a blue item, you click on left. Depending on how you have clicked on an object will determine the next step in the code.
Does make sense?
See you soon
Beth
Yes. You can click on something for any reason you might intend, and then use the arrow keys left and right.
-
Support for the standard T530 32 GB?
The processor does QM T530 has 4 slots SO-DIMM? I see it's max sold configuration is 16 GB with 2 modules DIMM; Quad-cores supports 4 DIMMS. Trying to decide whether the T530 can support 32 GB of ram. Crucial has the T530 configured with only 2 SO-DIMM type.
If there is 2 SO-DIMM type, expected on support SO-DIMMs to 4 quad-core models?
Thank you.
only two DIMMS T530, whatever CPU you choose for the machine.
Only four hearts W series models have 4 dimm slots.
-
License for the Oracle ODBC database gateway
Hello world!
I am using Oracle Database Gateway for ODBC (Oracle 11 g Gateway) to create dblink Oracle 10.2.0.4
According to this price list, I do not see the price details for the database gateway for ODBC Oracle
http://www.Oracle.com/us/corporate/pricing/technology-price-list-070617.PDF
Please refer to page 3 and 4
and according to the guidelines of it, I don't need a separate license. Could someone shed some light. I have the database and the gateway in the same machine
http://download.Oracle.com/docs/CD/E11882_01/license.112/e10594.PDF
Please refer to page 1-7, which says
Gateway for ODBC Oracle database
Database gateway for ODBC Oracle can be installed and used on a different machine
the machine where the database Oracle is installed and used. Should not be
to obtain a separate license for the machine running Oracle Gateway for ODBC
Please shed some light.
Thanks in advance.Hello
As it is said, as long as you have a license of RDBMS, you need not a separate license for DG4ODBC. If confusion is where it says "Oracle Database Gateway for ODBC can be installed and used on a different machine," then it is just to clarify that you run the gateway on a machine completely separated from the performer the RDBMS under license, but you can also run DG4ODBC on the same machine where the RDBMS is installed.
If you install 11g DG4ODBC on the same machine where you have a 10g RDBMS then it must be installed in an another ORACLE_HOME.If this still isn't clear, so please come back and let us know exactly what you need to clarify.
Kind regards
Mike -
Vista can ping machine to another, but cannot access shared folders on the machine
Hi experts,
Recently, we have problems with some Vista machines to access shared folders on other Vista machines. This seems to happen after the automatic updates of windows.
These 'problem' machines are able to ping other machines 'good' but is unable to connect to shared folders machines 'good '.
The reverse works fine ('good' machines can ping and access 'problem' machines).
When you connect to folders shared of these 'problem' to 'good' machines machines using \\machinename\folder or even \\machine_ip\folder, the error window "the network location cannot be reached" appears.
'Problem' machines can do desktop connection remote for the machines 'good '.
All machines have the parameters: -.
Same workgroup
Same domain - private network
Network discovery on
File sharing on
Public folder sharing
Password protected sharing
I am not able to find a solution on the web site and microsoft.
Re-install Vista on 1 machine of 'problem' and the problem goes away.
The problem with reinstalling is subject to re-registration of certain software licenses which has no registration online (through applications for certificates).
Is there a resolution without having to re - install Vista?ltkhoo
Hey
You can post your question here:
http://social.technet.Microsoft.com/forums/en/category/windowsvistaitpro
-
is it possible to make the machine and authentication of users in the same permission profile?
Hello
I want to know is - it possible to machine authentication authentication of users arrive at the same time? Something like that...
Condition
IF (wired_802.1x and AD:externalgroup computer dommain EQUAL AND Some_domain_user_group EQUAL AD:exteranalgroup)
Permissions
then Vlan x
Basically, I'm just checking a machine in the domain and user is valid only while he should be able to have full access.
Any help will be of great value.
Hello
IF (wired_802.1x and AD:externalgroup computer dommain EQUAL AND Some_domain_user_group EQUAL AD:exteranalgroup)
-Not possible
As the authentication of the user and the machine occur in different contexts.
ACS cannot check them both at the same time.
With the help of MAR, you can, although club together and reach:
"machine is part of the domain and user is valid only while he should be able to have full access"
Tips for MAR configuration:
(1) set the client to authenticate user or computer.
(2) create two rules in the authorization for the user and and the other for the machine (identity them using the ad group membership).
(3) enable MAR on the AD on ACS configuration page and set the aging time.
(4) in rule user, customize and use the condition "Has been authenticated machine" and the value is false.
Rate if useful
-
entry not long enough for the date format value
Hi all
my table PF having IN_DATE is number format we save date number format as 20120101 (Jan 01, 2012)
and IN_DATE can have 0 (zeros) also.
When running under query, I get error "not long enough for the format of the value entry date.
Please, help me to sort it, why this error is coming?
Thanks in advance
Published by: user10736825 on May 20, 2013 15:30SELECT * FROM pf WHERE TO_DATE(IN_DATE,'YYYYMMDD') > TRUNC(SYSDATE)-100 and IN_DATE != 0;
Hello
When you store date information in a column NUMBER (or string), you just ask in trouble. The best way to avoid this problem is to use a DATE for date information column.
The next best thing is to avoid the conversion of the NUMBER into a DATE. DATEs (such as returned by SYSDATE) still can b converted without risking a mistake, so instead of
user10736825 wrote:
SELECT * FROM pf WHERE TO_DATE(IN_DATE,'YYYYMMDD') > TRUNC(SYSDATE)-100 and IN_DATE != 0;
use:
SELECT * FROM pf WHERE in_date > TO_NUMBER ( TO_CHAR ( TRUNC (SYSDATE) - 100 , 'YYYYMMDD' ) ) ;
-
Literal string too long for the CLOB
Hello
My version of the database is:
Oracle Database 11 g Enterprise Edition Release 11.2.0.1.0 - 64 bit Production
PL/SQL Release 11.2.0.1.0 - Production
CORE 11.2.0.1.0 Production
AMT for Linux: Version 11.2.0.1.0 - Production
NLSRTL Version 11.2.0.1.0 - Production
When I run this piece of code, I get an error.
DECLARE
insCtx DBMS_XMLStore.ctxType;
lines NUMBER;
xmlDoc CLOB: = 'xml string is about 4600 long lines in TOAD...';
BEGIN
insCtx: = DBMS_XMLStore.newContext ("xmlTempTbl"); -get the context
lines: = DBMS_XMLStore.insertXML (insCtx, xmlDoc); -Insert the doc
DBMS_XMLStore.closeContext (insCtx); -close the handle
END;
ERROR:
ORA-06550: line 4, column 19:
PLS-00172: string literal too long
From my understanding a CLOB leave maximum string size of 2 GB. And on top, my xml string is not greater than 2 GB (I cannot display the xml data string, refers to the business). So why I get the error too long string literal.
For the above, I fault the XML into several parts and run the PLSQL, then it gives no error.
Please advice.
Published by: 934451 on November 8, 2012 07:06
Published by: 934451 on November 8, 2012 07:07From my understanding a CLOB leave maximum string size of 2 GB.
Not exactly:
http://docs.Oracle.com/CD/E11882_01/AppDev.112/e25519/datatypes.htm#CHDDCGEEbut this isn't the real problem.
The error is about the "string literal" size, there is a limitation too:
http://docs.Oracle.com/CD/E11882_01/server.112/e17766/pcmus.htm#sthref18132PLS-00172: string literal too long Cause: The string literal was longer than 32767 bytes. Action: Use a string literal of at most 32767 bytes.
For the above, I fault the XML into several parts and run the PLSQL, then it gives no error.
Is this a real case of production or you just test?
In practice, we should first save the file in a variable/column CLOB (or XMLType) and then reference the content from there.
Maybe you are looking for
-
Network (NIC) card does not work with DHCP or static IP
Hi, I have a ThinkCentre M70e (0809-C6S) with a problem in the network card. The link led is on and Windows detects that a cable has been connected. But the network can not aquire a DHCP lease and does not work with the static IP address. I uninstall
-
Trying to open "Windows Update" of the icon of the Office does not work.
Whenever I try to run "Windows Update" of an icon from this site that I placed on my desk, only about half of the Web site page opens, that is to say, only the ' express' and 'custom' button shows, does not show the calendar to update on the right si
-
InDesign CC 2015.4 - CRASH
Does anyone else have this problem. Legit... it's random. I am a person magazine and I can be working and boom - gone.It's happened for a few months. I'm relatively new to Mac so... kind of lost.Thank you
-
Hey-So many times when I'm playing with the CSS code, I'll make an adjustment to something like change the margins to place it where I want, but when I click on the screen other elements involuntarily to his place. Can someone help me understand why
-
I can not connect with my BC password. I tried to reset and all I get is an error. I can not even find a support option to solve the problem. Anyone know anything I can do?