Search This Blog

Thursday, March 26, 2020

Internet Check In Oracle Apex


Step 1.  Download the GIF file from here... DOWNLOAD GIF
Step 2.  Create a Region in Global Page and Copy Pest below Code.
<html>
<head>
<title>Page Title</title>
<link href="https://cdnjs.cloudflare.com/ajax/libs/offline-js/0.7.19/themes/offline-theme-slide.min.css" rel="stylesheet" type="text/css"></link>
<link href="https://cdnjs.cloudflare.com/ajax/libs/offline-js/0.7.19/themes/offline-language-english.min.css" rel="stylesheet"></link>
</head>
<script src="https://cdnjs.cloudflare.com/ajax/libs/offline-js/0.7.19/offline.min.js"></script>
<script>
Offline.options = {checks: {xhr: {url: 'PASTE YOUR UPLOADED IMAGE URL'}}};
</script>
<body>
</body>
</html>

Step 3. Upload the GIF file into Static Application Files   
Step 4. Copy the reference URL of the gif file into above code.
Step 5. TO TEST YOU HAVE TO DISCONNECT YOU INTERNET CONNECTION.

Thank You

Collected From : Satish Yadav

Thursday, March 19, 2020

Character Restrict From a Item and Only Numeric Will Allowed

1. Copy The Below Code to Page Function and Global Variable Declaration. 
function validateNumber(event) {
  var keyCode = event.keyCode;
  var excludedKeys = [8, 37, 39, 46];

  if (!((keyCode >= 48 && keyCode <= 57) ||
      (keyCode >= 96 && keyCode <= 105) ||
      (excludedKeys.includes(keyCode)))) {
    console.log("alphabets are not allowed");
    event.preventDefault();

  }

  console.log("keycode: " + keyCode);
}
2.  And Copy the below function Calling on Item Custom Attribute.
onkeydown="return validateNumber(event)";  


Monday, February 10, 2020

Oracle Apex Developer User Password Change From Backend By Admin User



Step 1.  Go to APEX_050100 User

Step 2.  Go to WWV_FLOW_FND_USER table then >> Set Password On WEB_PASSWORD Column Of Respective User.
After Setting Password On WEB_PASSWORD Column Password May Hide/Invisible.

Step 3.  If Account Has Been Locked Then Change ACCOUNT_LOCKED Column Y Flag To N Flag For Unlock The Respective User.

Thank You 

Thursday, January 16, 2020

PRAGMA AUTONOMOUS_TRANSACTION

PRAGMA AUTONOMOUS_TRANSACTION is a Seen Text what make sub program successful even the main program got Rollback in Oracle PL/SQL. Normally we may use this Seen Text in Functions , Procedures , Trigger which we call in the PL/SQL block as a sub Program/Transaction. 1. Mainly PRAGMA AUTONOMOUS_TRANSACTION use to keep log at the middle of a PL/SQL Transaction block. To Know More and With Example You Can Visit This URL : PRAGMA AUTONOMOUS_TRANSACTION PRAGMA AUTONOMOUS_TRANSACTION  is a Seen Text what make sub program successful  even the main program got Rollback in Oracle PL/SQL. Normally we may use this Seen Text in Functions , Procedures , Trigger which we call in the PL/SQL block as a sub Program/Transaction.



1. Mainly PRAGMA AUTONOMOUS_TRANSACTION use to keep log at the middle of a PL/SQL Transaction block.

To Know More and With Example You Can Visit This URL :   PRAGMA AUTONOMOUS_TRANSACTION

CREATE AND DROP ACL VERSION 2

SELECT ACL

SELECT host,
       lower_port,
       upper_port,
       ace_order,
       TO_CHAR(start_date, 'DD-MON-YYYY') AS start_date,
       TO_CHAR(end_date, 'DD-MON-YYYY') AS end_date,
       grant_type,
       inverted_principal,
       principal,
       principal_type,
       privilege
FROM   dba_host_aces

ORDER BY host, ace_order;
CREATE ACL

BEGIN
  DBMS_NETWORK_ACL_ADMIN.CREATE_ACL(acl         => 'www.xml',
                                    description => 'WWW ACL',
                                    principal   => 'PUBLIC',
                                    is_grant    => true,
                                    privilege   => 'connect');

  DBMS_NETWORK_ACL_ADMIN.ADD_PRIVILEGE(acl       => 'www.xml',
                                       principal => 'PUBLIC',
                                       is_grant  => true,
                                       privilege => 'resolve');

  DBMS_NETWORK_ACL_ADMIN.ASSIGN_ACL(acl  => 'www.xml',
                                    host => '*');
END;
/
COMMIT;


DROP ACL

BEGIN
  DBMS_NETWORK_ACL_ADMIN.drop_acl (
    acl         => 'www.xml');

  COMMIT;

END;

Json Parsing Using Json Table in PLSQL Oracle 12c Release 1

DECLARE
V_JSON VARCHAR2(4000);
ECO VARCHAR2(3000);
BEGIN
/*
{
"ChallanNo":"2020-0000000047",
"RefNo":"1234567",
"BankBranchNameEn":"BANK ASIA LTD., HEAD OFFICE",
"BankBranchNameBn":"BANK ASIA LTD., HEAD OFFICE",
"ClientNameEn":"Md Zafar Iqbal Edit",
"ClientNameBn":"মোঃ জাফর ইকবাল আà¦ÂªÃ ¦¡Ã §‡Ã ¦Ÿ",
"Amount":3450.0,
"ChallanEconomic":[
{
"EconomicCode":"1422311",
"EconomicNameEn":"Passport fee",
"EconomicNameBn":"à¦ÂªÃ ¦¾Ã ¦¸Ã ¦ÂªÃ §‹Ã ¦°Ã §Ã ¦Ÿ ফি",
"ChallanSubNo":"01",
"Amount":3000.0
},
{
"EconomicCode":"1141102",
"EconomicNameEn":"Supplementary duty on domestically produced commodities",
"EconomicNameBn":"দেশজ উৎà¦ÂªÃ ¦¾Ã ¦¦Ã ¦¿Ã ¦¤ à¦ÂªÃ ¦£Ã §Ã ¦¯Ã §‡Ã ¦° ওà¦ÂªÃ ¦° সমà§Ã ¦ÂªÃ §‚রক শà§Ã ¦²Ã §Ã ¦•",
"ChallanSubNo":"02",
"Amount":450.0
}
],
"SuccessFlag":"Y"
}
*/
  SELECT a.JSON_RESPONSE.ChallanEconomic.EconomicCode
     INTO eco
     FROM
     IN_OUT_JSON a
    WHERE REQUESTID = 27;

   eco := LTRIM (RTRIM (eco, ']'), '[');

   FOR FOO IN (    SELECT REGEXP_SUBSTR (eco,
                                         '[^,]+',
                                         1,
                                         LEVEL)
                             TXT
                     FROM DUAL
               CONNECT BY REGEXP_SUBSTR (eco,
                                         '[^,]+',
                                         1,
                                         LEVEL)
                             IS NOT NULL)
   LOOP
      DBMS_OUTPUT.PUT_LINE (FOO.TXT);
   END LOOP;
END;

Saturday, January 11, 2020

Multiple Process Execute On Same Button Problem In Oracle Apex

When we try to execute multiple process on same button there is may problem arise from oracle apex. Error would be like Jquery from apex builtin library file. We can get the error from browser inspect and console .

Solve : Goto to Page Properties >>  Advance >> Reload On Submission >> Always

Wednesday, December 11, 2019

Check Box In Header to Check all In Classic or Interactive Report Oracle Apex

Classic and Interactive Report Header Check Box
-------------------
<input type="checkbox" id="checkAll" > Check All

function and Global Variable Declaration
---------------------
$('#checkAll').click(function () {   
     $('input:checkbox').prop('checked', this.checked);   
 });

Monday, November 25, 2019

Day, Minute, Second Difference Between Two Date

SELECT :end_date,
       :start_date,
       TRUNC (MONTHS_BETWEEN ( :end_date, :start_date) / 12) AS yrs,
       TRUNC (MOD (MONTHS_BETWEEN ( :end_date, :start_date), 12)) AS mnts,
       TRUNC (:end_date- ADD_MONTHS(:start_date,MONTHS_BETWEEN(:end_date,:start_date)))AS dys,
       TRUNC (24 * MOD ( :end_date - :start_date, 1)) AS hrs,
       TRUNC (MOD (MOD ( :end_date - :start_date, 1) * 24, 1) * 60) AS mins,
       MOD (MOD (MOD ( :end_date - :start_date, 1) * 24, 1) * 60, 1) * 60 AS secs
  FROM (SELECT :end_date, :start_date FROM DUAL);

Wednesday, November 20, 2019

Create a Form Using Python for Save Data into Excel like a Database

#Download Pyhton from here https://www.python.org/downloads/  #Download Python: #Click the “Download Python 3.x.x” button (the latest versio...