In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-03-31 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)06/01 Report--
Look at the usage of these two default parameters through a question of 051:
91.View the Exhibit and examine the structure of the PROMOTIONS table. Which two SQL statements would execute successfully?
A.UPDATE promotions SET promo_cost = promo_cost+ 100WHERE TO_CHAR (promo_end_date, 'yyyy') >' 2000'
B.SELECT promo_begin_date FROM promotions WHERE TO_CHAR (promo_begin_date,'mon dd yy') = 'jul 01 98'
C.UPDATE promotions SET promo_cost = promo_cost+ 100WHERE promo_end_date > TO_DATE (SUBSTR ('01MJANMUR 2000))
D.SELECT TO_CHAR (promo_begin_date,'dd/month') FROM promotions WHERE promo_begin_date IN (TO_DATE ('JUN 01 98'), TO_DATE ('JUL 01 98'))
Answer: AB
A: correct
B: correct
C: error
D: error
Both C and D errors are due to the fact that the format of the conversion is not specified, and the default format is through the
Decided by NLS_DATE_LANGUAGEE and NLS_DATE_FORMAT, so they both have problems and can be modified as follows
SQL > select TO_DATE (SUBSTR (01Rajousei 2000) from dual;select TO_DATE (SUBSTR)) from dualORA-01861: text and format strings do not match SQL > alter session set NLS_DATE_FORMAT='yyyy';Session alteredSQL > select TO_DATE (01MJANMui 2000 jewelry 8) from dual TO_DATE (SUBSTR ('01murJANKULY 2000 calendar) 8FLV 2000 JUN 12SQL 1SQL > select TO_DATE (' JUN 098') from dual;select TO_DATE ('JUN 098') from dualORA-01841: (complete) the year value must be between-4713 and + 9999, and not 0SQL > alter session set NLS_DATE_FORMAT='MON DD RR' Session alteredSQL > alter SESSION SET NLS_DATE_LANGUAGE='AMERICAN';Session alteredSQL > select TO_DATE ('JUN0198') from dual;TO_DATE (' JUN0198')-1998-6-1
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.