User talk:Satish gaude
From Wikipedia, the free encyclopedia
Satish gaudo
satishgaude@gmail.com
satkom rules
Top Sites List used by $me {
Translator site http://translate.google.com/translate_t
satish --------
http://www.opera.com/support/tutorials/userjs/specs/ http://stevehollasch.com/cgindex/index.html http://www.azlyrics.com/i/iglesias.html====================> http://dev/~satish/test.php http://mboard.rediff.com/board/postboard.php?action=p --->rediff clipboard about:config ===>for codebase http://xulplanet.mozdev.org/tutorials/xultu/introxbl.html - xulplanet.com @@@@@@@@@@@@@@@http://mozdev.mirrors.nyphp.org/xulmaker/xulplanet/@@@@@@@@@@@@imp source code of the mozilla packeges http://sports.si.cnn.com/default.asp?c=cnnsi&page=soc-eng/stand/standing.htm >>for the latest EPL standings
http://www.hindilyrix.com/songs/get_song_Ab%20Mujhe%20Raat%20din.html http://www.cs.fiu.edu/~weiss/dsaa_c++/code/ ==>c/c++ codes (header files) http://www.soccerstats.com/latest.asp?league=England ==>EPL
=link for bypassing the proxies --for blocked sites.
http://www.oreillynet.com/pub/h/4807
conatins info regarding hacking
/*
http://www.javascriptkit.com/jsref/date.shtml -- javascript classes
---------------------------------- external/cflwiki/ -- help dev/~dev/ -- path
http://www.ss64.com/bash/history.html --list of linux commands
http://basic.mozillanews.org/mozilla_book/ch03.html#77042 --- xul link for overlays
http://www.karakas-online.de/gnu-linux-tools-summary/network-commands.html ---- linux commands
http://javascript.about.com/library--- javascript link
http://codepunk.hardwar.org.uk/bjs.htm -- javascript link http://ashutoshsaxena.tripod.com/jstut/quickstart/ch080.html---javascript link http://phrogz.net/JS/Classes/ExtendingJavaScriptObjectsAndClasses.html ....................................................................................................
chown satish.dev cls_modules_00.01.php ,..............change owner chmod 755 cls_modules_00.01.php ,..............change permission 777 all ......750 ..........755
.............................................................................................................. http://basic.mozillanews.org/mozilla_book/ch03.html
http://www.lib.tsinghua.edu.cn/chinese/INTERNET/JavaScript/objects.html#selection_object
} //----------------------------------------------------- // Function to get Buttons on the form //----------------------------------------------------- function getButtons() { if (sTabPermissions.length) { aResult = sTabPermissions.split("|"); aResult.shift(); for (var i in aResult) { aValues = aResult[i].split("#"); if (aValues[0] == "tab_sy_mo_modules") { if (aValues[1].indexOf('C') >= 0) document.getElementById("btnWSAdd").disabled = false; if (aValues[1].indexOf('U') >= 0) document.getElementById("btnWSUpd").disabled = false; if (aValues[1].indexOf('D') >= 0) document.getElementById("btnWSDel").disabled = false; } else if (aValues[0] == "tab_sy_mo_users") { if (aValues[1].indexOf('U') >= 0) document.getElementById("btnWSUpdUser").disabled = false; } } } } //----------------------------------------------------------------------------------------------------------------- //------------------------------------------------------- // buildListBox -multi-col list box //------------------------------------------------------- function buildListBox(oIdLsb, aSent, aSelected, iListCellNo) { iRowCount = document.getElementById(oIdLsb).getRowCount(); for (i = 0; i < iRowCount; i++) { document.getElementById(oIdLsb).removeChild(document.getElementById(oIdLsb).lastChild); } var oLstItem = new Array(); var oLstCell = new Array(); j = 0;
for (i in aSent) {
if (aSent[i]) { oLstItem = document.createElement('listitem');
oLstItem.setAttribute('id', oIdLsb + aSent[i][0]); if (iListCellNo > 0) { for (k = 1; k <= iListCellNo; k++) { oListCell = document.createElement('listcell'); oListCell.setAttribute('label', aSent[i][k]); oLstItem.appendChild(oListCell); } } else { oListCell = document.createElement('listcell'); oListCell.setAttribute('label', aSent[i][1]); oLstItem.appendChild(oListCell); }
oLstItem.setAttribute('value', aSent[i][0]); document.getElementById(oIdLsb).appendChild(oLstItem); } } if (aSelected == undefined) aSelected = ;
if (aSelected.length > 0) { for (j in aSelected) { iIndex = -1; iIndex = document.getElementById(oIdLsb).getIndexOfItem(document.getElementById(oIdLsb+aSelected[j])); document.getElementById(oIdLsb).addItemToSelection(document.getElementById(oIdLsb).getItemAtIndex(iIndex)); } }
}//EOF multi-col list box
//----------------------------------------------------- // Batches : validDate //----------------------------------------------------- function validDate(sDatePassed) { //if the date is in dd/mm/yyyy format then valid date returns 1else 0 if (sDatePassed.length > 0) {
aDate = sDatePassed.split("/");
if (aDate.length != 3) return(0); if (aDate[1].length == 1) aDate[1]= "0"+aDate[1];
var iLeapyear = 0;
// check whether the year is leap year - aleap year is div by 4 ,100, 400
if ((aDate[2] % 4) == 0) { if ((aDate[2] % 100) == 0) { if ((aDate[2] % 400) == 0) { iLeapyear = 1; } } } if (aDate[2].length != 4) { return(0); } else if (isNaN(aDate[2])) { return(0); } else if (aDate[2] < 0) { return(0); } else if ((aDate[1].length == 0) || (aDate[1].length > 2)) { return(0); } else if (isNaN(aDate[1])) { return(0); } else if ((aDate[1] <= 0) || (aDate[1] > 12)) { return(0); } else if ((aDate[0].length == 0) || (aDate[0].length > 2)) { return(0); } else if (isNaN(aDate[0])) { return(0); } else if (aDate[0] <= 0) { return(0); } else if ((iLeapyear == 1) && (aDate[1] == 02) && (aDate[0] > 29)) { return(0); } else if ((iLeapyear == 0) && (aDate[1] == 02) && (aDate[0] > 28)) { return(0); } else if (((aDate[1] == '01') || (aDate[1] == '03') || (aDate[1] == '05') || (aDate[1] == '07') || (aDate[1] == '08') || (aDate[1] == '10') || (aDate[1] == '12')) && (aDate[0] > '31')) { return(0);
} else if (((aDate[1] == '04') || (aDate[1] == '06') || (aDate[1] == '09') || (aDate[1] == '11')) && (aDate[0] >'30')) { return(0); } return 1; } else {
return(1); }
}// EOF validDate
- details about the database
mozilla editting the source code cd .mozilla cd default/ cd chrome/
chrome.rdf -- package registry file contains the list of all the packages included in the mozilla version and the links of all the packages
TO EDIT THE SOURCE CODE OF THE BROWSER MOZILLA JUST UNZIP THE JAR FILES AND CHANGES THE CORRES LINKS FOR THE PACKAGES TO THIS NEW FILES IN THE chrome.rdf
the browser preferences are stored in the prefs.js file
type in the browser about:config to see and edit ur mozilla preferences.
innoDB mysql
transaction module the transaction - seq of rel. instructions that must be treated as an single indivisible unit. that is all wrk in the transaction is fully done or not done fully----atomicity.
Linux commands kill all
code for generating the hierarchy --dashes
if (is_array($aPostDetails)) {
$iCount = 0; foreach ($aPostDetails as $iPostId => $aValues) { $iNewRight = $aValues['post_right']; if($iCount){ if($iNewRight < current($aRight)){ $aRight[sizeof($aRight)] = $iNewRight; next($aRight); }else{ $iCurrent = current($aRight);
while($iNewRight > $iCurrent){
$aSelected[$iCurrent] = sizeof($aRight)-1; array_pop($aRight); end($aRight); $iCurrent = current($aRight); } $aRight[sizeof($aRight)] = $iNewRight; end($aRight); $aSelected[$iNewRight] = sizeof($aRight)-1; } }else{ $aRight[sizeof($aRight)] = $aValues['post_right']; $aSelected[$aValues['post_right']] = 0;
}$iCount++;
}
if(is_array($aRight)){
foreach($aRight as $lng_key =>$iValue){
$aSelected[$iValue] = $lng_key;
}
}
//event listners track any action on the on the document //----------------------------------------------------- // Employees:WSDelPfEsi //----------------------------------------------------- function setFocusedElement() // call the eventlistner function // addEventListener("input",setFocusedElement,true);
// ventListener("input",setFocusedElement,true); { alert("===================satish");
var focused = document.commandDispatcher.focusedElement; alert(focused.nodeName);
alert(focused.getAttribute("id"));
return;
}
the javascript commands
setInterval("fnClick()",3000); ->runs the function fnClick() after every 3 seconds setTimeout("fnClick()",3000); ->runs the function fnClick() after 3 seconds clearInterval(ID); ->Clears the timer set using ID=setInterval(). clearTimeout(ID) ; ->Clears the timer set using ID=setTimeout().
php sessions
if you want to protect users from simple social engineering tactics, you need to enable session.use_only_cookies. In that case, cookies must be enabled unconditionally on the user side, or sessions will not work.
CSS for the xul tree /* treechildren::-moz-tree-row(selected) { background-color: #eeeee; }
treechildren::-moz-tree-row(odd) { background-color: #FF0000; } treechildren::-moz-tree-row(odd, selected) { background-color: #aaaaa; } treechildren::-moz-tree-cell-text(selected) { color: #94FF86; } treechildren::-moz-tree-cell-text(odd) { text-align: right; }*/
css for listitem cell
oListCell[iListCell].setAttribute('style', 'text-align:right;border-style: solid;border-left-width: 1px;border-right-width: 1px;border-top-width: 1px;border-bottom-width: 1px;border-color:#cccccc;');//background-color:#dddddd;
<?php
header("Content-Type: text/css"); include_once("../../../../common/conf.php"); $oConfig = new config(); ?> @namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"); treechildren::-moz-tree-cell-text(pending) { color: #ff1d5d; }
.overflow {
overflow :auto;
} .textAlign {
text-align: right;
} .width1 {
min-width:100px;
} .width2 {
min-width:150px;
}
.onMouseOverTextColor { color:#000000; text-weight:strong;
background-color:#d9d4d4;
}
.caption { color:#000000;
background-color:#d4d4d4;
}
.caption1 { color:#000000;
background-color:#d0d0d0;
}
code to edit the sessions <?php
exec("cat /tmp/sess_*", $aOutput); print_r($aOutput);
?>
XBL eXtensible binding language - helps to change how an element works helps to change the functionality of an element.
Mysql storage limit max - 4 GB . becos 32 bit hardware used.
//----------------------------------------------------- // function to set the timer //----------------------------------------------------- function setTimer() { window.setTimeout("setMousePointer(\"winMod\",0)", 1000); return false; }
//----------------------------------------------------- //function to set mouse pointer //----------------------------------------------------- function setMousePointer(oWindowId, iflag) { if (iflag == 1){ document.getElementById(oWindowId).setAttribute("wait-cursor", "true"); }else{ document.getElementById(oWindowId).removeAttribute("wait-cursor"); return true; } }//EOF function to set mouse pointer
Using the attributes array ==>
http://www.javascriptkit.com/dhtmltutors/domattribute2.shtml
alert(document.getElementById('txbRSWSWSPromotionValue').attributes); for (i in document.getElementById('txbRSWSWSPromotionValue').attributes) { alert(document.getElementById('txbRSWSWSPromotionValue').attributes[i].value); } it gives the array of attributes defined for a element .
script to detect the browser used by the client <SCRIPT> </SCRIPT>
// contains all the vars that are reqd for the detection of the OS/Lang through javascript http://www.mozilla.org/docs/web-developer/sniffer/browser_type.html
here is the script // end hide JavaScript
http://www.whitebeam.org/dispcode.rhtm?file=/library/guide/TechNotes/httpreq.rhtm -->SOAP related info
// editng of the cookies in the javascript
document.cookie =\"sSelectedPostIds = 123 \"; alert(document.cookie);
php code to easily interact with javascript
if (is_array($aPosts)) { $s = "var aPostsDivWise = new Array; aPostsDivWise[1] = new Array; aPostsDivWise[2] = new Array; aPostsDivWise[5] = new Array;"; $iCnt = 1; foreach ($aPosts as $iDivId => $aValue) { foreach ($aValue as $iPostId => $sValue) { if (($iCnt > 1)) { $s.= "aPostsDivWise[$iDivId][$iPostId] = \"$sValue \"; "; } $iCnt++; } } }
php code to download pdf file --- if($tmp_str_flag=="readPDF")
{ $tmp_str_pdfPath = $_GET['fName']; $tmp_str_pdfPath = base64_decode($tmp_str_pdfPath); if (file_exists($tmp_str_pdfPath)) { $fp = fopen($tmp_str_pdfPath,"r"); $buf = fread($fp, filesize($tmp_str_pdfPath)); $len = strlen($buf);
header("Content-disposition: attachment; filename=hip.pdf"); header("Content-Type: application/force-download"); header("Content-Transfer-Encoding: binary"); header("Content-Length: ".strlen($buf)); print $buf; die(); } }
ORACLE DETAILS
Top sites
http://www.exforsys.com/content/view/1332/267/ http://www.psoug.org/reference/type.html For Data dictionary view http://www.ss64.com/orad/
best site == http://www.orafaq.com/faqsql.htm
PHP ORACLE SCRAP
create user sat identified by satish; grant connect,resource to sat; connect sat;
password:
create sequence sat_detail_seq;
//get the hidden row info select SYS_NC_ROWINFO$, account_kind_id from account_kind; //all the system colums select name, length from sys.col$
NAME LENGTH
----------
CACHE 15 TABLE_LOCK 8 SAMPLE_SIZE 22 LAST_ANALYZED 7 PARTITIONED 3 IOT_TYPE 12 TEMPORARY 1 SECONDARY 1 NESTED 3 BUFFER_POOL 7 ROW_MOVEMENT 8
// all the system tables
select * from user_sequences; select * from user_tables; select * from user_types;
TYPE_NAME TYPE_OID
--------------------------------
TYPECODE ATTRIBUTES METHODS PRE INC FIN INS
---------- ---------- --- --- --- ---
SUPERTYPE_OWNER SUPERTYPE_NAME LOCAL_ATTRIBUTES
------------------------------ ----------------
LOCAL_METHODS TYPEID
--------------------------------
HI_Q35_TYPE 16E52A0D56BDA012E040A8C0030043BB OBJECT 3 0 NO NO YES YES
TYPE_NAME TYPE_OID
--------------------------------
TYPECODE ATTRIBUTES METHODS PRE INC FIN INS
---------- ---------- --- --- --- ---
SUPERTYPE_OWNER SUPERTYPE_NAME LOCAL_ATTRIBUTES
------------------------------ ----------------
LOCAL_METHODS TYPEID
--------------------------------
HI_Q37_TYPE 16E52A0D56C3A012E040A8C0030043BB OBJECT 3 0 NO NO YES YES
TYPE_NAME TYPE_OID
--------------------------------
TYPECODE ATTRIBUTES METHODS PRE INC FIN INS
---------- ---------- --- --- --- ---
SUPERTYPE_OWNER SUPERTYPE_NAME LOCAL_ATTRIBUTES
------------------------------ ----------------
LOCAL_METHODS TYPEID
--------------------------------
HI_Q33_TYPE 16E52A0D56B8A012E040A8C0030043BB OBJECT 2 0 NO NO YES YES
// important -- all the attributes of an user defined type // table - user_type_attrs
eg .
select attr_name from user_type_attrs where type_name='agree_type'
TYPE_NAME ATTR_NAME
-----------------------
ATTR_TYPE_OWNER ATTR_TYPE_NAME
-----------------------
PRECISION SCALE CHARACTER_SET_NAME
---------- --------------------------------
INH --- HE_I38_TYPE IS_ITEM38_INCLUDED
CHAR CHAR_CS
NO
TYPE_NAME ATTR_NAME
-----------------------
ATTR_TYPE_OWNER ATTR_TYPE_NAME
-----------------------
PRECISION SCALE CHARACTER_SET_NAME
---------- --------------------------------
INH --- HE_I37_TYPE IS_ITEM37_INCLUDED
CHAR CHAR_CS
NO
HE_I36_TYPE IS_ITEM36_INCLUDED
select ATTR_NAME from USER_TYPE_ATTRS where TYPE_NAME='HI_Q33_TYPE'
All the system tables that stores the user defined tables/sequences/object types :
user_types USER_TYPE_ATTRS
user_sequences
user_tables USER_TAB_COLUMNS
Code for taking back of live tables -
CREATE TABLE HIP_TASK_INFO_satish as SELECT HIP_TASK_ID ,
HIP_TASK_ID as HIP_TASK_BUDGET_ID, HIP_TASK_ID as HIP_DUTY_DETAIL_ID, IS_ACTIVE, IS_DELETE, ADDDT FROM HIP_TASK_INFO
DROP table HIP_TASK_INFO;
RENAME HIP_TASK_INFO_satish TO HIP_TASK_INFO ;
// for implementation of limit in queries
SELECT temp.*,rownum FROM (
SELECT sp.company_name, sp.contact_phone, sp.office_fax, sp.sub_id, sb.branch_id, sb.branch_url, sp.Office_Address.Address1 || ', ' || sp.Office_Address.Address2 || ', ' || sp.Office_Address.Address3 || ', ' || sp.Office_Address.City || ', ' || sp.Office_Address.County as address FROM subscriber_primary sp, subscriber_branch sb, subscriber_info si WHERE si.sub_id=sp.sub_id AND sb.sub_id=sp.sub_id AND si.sub_kind_id=4 AND sp.primacy_no=1 AND sb.branch_level = '0' ) temp
GROUP BY
temp.contact_phone, temp.office_fax, temp.sub_id, temp.branch_id, temp.branch_url, temp.address, rownum having rownum>=2 AND rownum<4
SELECT tablespace_name FROM dba_tablespaces;
SELECT * FROM dba_tablespaces;
CREATE TABLESPACE tools DATAFILE '/u02/oradata/mypack/MYPACK/datafile/o1_tools_.dbf' SIZE 50M, AUTOEXTEND ON BLOCKSIZE 8192 FORCE LOGGING DEFAULT NOCOMPRESS EXTENT MANAGEMENT LOCAL UNIFORM SIZE 256K FLASHBACK ON ONLINE;
ALTER TABLESPACE lmtemp ADD TEMPFILE '/u02/oradata/temp02.dbf' SIZE 200M;
SELECT tablespace_name FROM dba_tablespaces;
SELECT * FROM dba_tablespaces;
SELECT table_name FROM dba_tables WHERE tablespace_name = 'USERS';
SELECT dd.tablespace_name tablespace_name, dd.file_name file_name, dd.bytes/1024 TABLESPACE_KB, SUM(fs.bytes)/1024 KBYTES_FREE, MAX(fs.bytes)/1024 NEXT_FREE FROM sys.dba_free_space fs, sys.dba_data_files dd WHERE dd.tablespace_name = fs.tablespace_name AND dd.file_id = fs.file_id GROUP BY dd.tablespace_name, dd.file_name, dd.bytes/1024 ORDER BY dd.tablespace_name, dd.file_name;
CREATE OR REPLACE VIEW freespace_view AS SELECT tablespace_name, SUM(bytes/1024/1024) AVAILABLE_MB FROM user_free_space GROUP BY tablespace_name;
commit;
select * from freespace_view
SELECT tablespace_name, (bytes/1024/1024) AVAILABLE_MB FROM user_free_space;
CREATE TABLESPACE satish DATAFILE 'D:\ORA9IAS\ORADATA\INTRA\SATISH02.DBF' SIZE 1024M BLOCKSIZE 8192 EXTENT MANAGEMENT LOCAL UNIFORM SIZE 1M SEGMENT SPACE MANAGEMENT AUTO;
ALTER TABLESPACE satish ADD DATAFILE 'D:\ORA9IAS\ORADATA\INTRA\SATISH03.DBF' SIZE 2M;
ALTER DATABASE DATAFILE 'D:\ORA9IAS\ORADATA\INTRA\SATISH02.DBF' RESIZE 20 M;
ALTER TABLESPACE satish AUTOEXTEND OFF;
create tabel sat1 (id number (11));
ALTER DATABASE DATAFILE 'D:\ORA9IAS\ORADATA\INTRA\SATISH02.DBF' RESIZE 1024 M;
ALTER DATABASE DATAFILE 'D:\ORA9IAS\ORADATA\INTRA\SATISH02.DBF' RESIZE 1024 M AUTOEXTENT ON;
SELECT table_name FROM dba_tables WHERE tablespace_name = 'satish';
CREATE TABLE "SATISH"."HIP_INFO" ("HIP_ID" NUMBER(11) NOT NULL, "HIP_CODE"
VARCHAR2(25 byte), "BRANCH_ID" NUMBER(11) NOT NULL, "HIP_STATUS_ID" NUMBER(11) NOT NULL, "HIP_EXPIRY_DATE" DATE, "HIP_EXPECT_COMPLETE" DATE, "HIP_COMPLETION_DATE" DATE, "DEFFERED_CREDIT_OPTION" CHAR(1 byte), "INSURANCE_OPTION" CHAR(1 byte), "LOGGED_MEMBER" CHAR(1 byte) NOT NULL, "LOGGED_MEMBER_ID" NUMBER(11) NOT NULL, "INITIATED_BY" VARCHAR2(15 byte) NOT NULL, "INITIATOR_ID" NUMBER(11) NOT NULL, "INITIATION_DATE" DATE NOT NULL, "INSTRUCT_SUB_NOW" VARCHAR2(1 byte));
Through sql / pl in oracle send mail create or replace
PROCEDURE send_mail (p_sender IN VARCHAR2, p_recipient IN VARCHAR2, p_message IN VARCHAR2) as l_mailhost VARCHAR2(255) := '192.168.1.21'; l_mail_conn utl_smtp.connection; BEGIN l_mail_conn := utl_smtp.open_connection(l_mailhost, 25); utl_smtp.helo(l_mail_conn, l_mailhost); utl_smtp.mail(l_mail_conn, p_sender); utl_smtp.rcpt(l_mail_conn, p_recipient); utl_smtp.open_data(l_mail_conn ); utl_smtp.write_data(l_mail_conn, p_message); utl_smtp.close_data(l_mail_conn ); utl_smtp.quit(l_mail_conn); end; /
begin send_mail( 'satishg@imageonline.co.in',
'rolvy@imageonline.co.in', 'Hello Tom' );
end; /
ORACLE
-- This is procedure for altering a object type when it has been used in a table with data. -- this is demo procedure for subscriber_primary where the office_address columns type is changed from -- office_address_type to office_address_type2
CREATE OR REPLACE PROCEDURE "INST_SUB_PRIMARY_DET_SAT" (tmp_int in number) IS
BEGIN
-- cursor DECLARE CURSOR PRIMARY_DET IS SELECT t.PRIMARY_ID p, t.SUB_ID s, t.OFFICE_ADDRESS.OFFICE_NO o1, t.OFFICE_ADDRESS.OFFICE_NAME o2, t.OFFICE_ADDRESS.ADDRESS1 o3, t.OFFICE_ADDRESS.ADDRESS2 o4, t.OFFICE_ADDRESS.ADDRESS3 o5, t.OFFICE_ADDRESS.CITY o6, t.OFFICE_ADDRESS.COUNTY o7, t.OFFICE_ADDRESS.POST_CODE o8, t.PRIMACY_NO pri, t.COMPANY_NAME com, t.CONTACT_NAME cont, t.CONTACT_MOBILE mob, t.CONTACT_PHONE phone, t.CONTACT_EMAIL email, t.OFFICE_PHONE opho, t.OFFICE_FAX ofax, t.OFFICE_EMAIL oemail, t.IS_ACTIVE act, t.IS_DELETE del, t.ADDDT adt, t.ADDED_BY aby, t.ADDED_BY_ID aid, t.EDITDT edt, t.UPDATE_BY uby, t.UPDATE_BY_ID ubi FROM SUBSCRIBER_PRIMARY t;
--cres PRIMARY_DET%ROWTYPE;
BEGIN FOR cres IN PRIMARY_DET LOOP INSERT INTO SUBSCRIBER_PRIMARY_test2 VALUES( cres.p, cres.s, cres.pri, cres.com, cres.cont, cres.mob, cres.phone, cres.email, office_address_type2(cres.o1, cres.o2, cres.o3, cres.o4, cres.o5, cres.o6, cres.o7, cres.o8, null), cres.opho, cres.ofax, cres.oemail, cres.act, cres.del, cres.adt, cres.aby, cres.aid, cres.edt, cres.uby, cres.ubi ); END LOOP; END;
END;
execute begin INST_SUB_PRIMARY_DET_SAT('1');end;
CREATE TABLE "SUBSCRIBER_PRIMARY_TEST2"
("PRIMARY_ID" NUMBER(11) NOT NULL, "SUB_ID" NUMBER(11) NOT NULL, "PRIMACY_NO" NUMBER(11), "COMPANY_NAME" VARCHAR2(100 byte), "CONTACT_NAME" VARCHAR2(100 byte), "CONTACT_MOBILE" CHAR(20 byte), "CONTACT_PHONE" CHAR(20 byte), "CONTACT_EMAIL" CHAR(50 byte) NOT NULL, "OFFICE_ADDRESS" "TEENA2"."OFFICE_ADDRESS_TYPE2", "OFFICE_PHONE" CHAR(20 byte), "OFFICE_FAX" CHAR(20 byte), "OFFICE_EMAIL" CHAR(50 byte), "IS_ACTIVE" CHAR(1 byte) DEFAULT 'y' NOT NULL, "IS_DELETE" VARCHAR2(15 byte) DEFAULT 'n' NOT NULL, "ADDDT" DATE DEFAULT sysdate NOT NULL, "ADDED_BY" CHAR(1 byte), "ADDED_BY_ID" NUMBER(11), "EDITDT" DATE, "UPDATE_BY" CHAR(1 byte), "UPDATE_BY_ID" NUMBER(11), CONSTRAINT "CHK_PRIMARY_ADDEDBY2" CHECK(ADDED_BY IN ('a','s','u')), CONSTRAINT "CHK_PRIMARY_UPDTBYID2" CHECK(UPDATE_BY_ID > '0'), CONSTRAINT "CHK_SUBPRIME_UPDTBY2" CHECK(UPDATE_BY IN ('a','s','u')), CONSTRAINT "PK_SUBSCRIBER_EMAIL2" PRIMARY KEY("CONTACT_EMAIL") );
SELECT
t.OFFICE_ADDRESS.COUNTRY
FROM
SUBSCRIBER_PRIMARY_TEST2 t;
--TWO DIMensional array implementation in ORACLE PLSQL--
CREATE OR REPLACE PROCEDURE "INSTUPDT_EXTENDEDLICENCE" (
tmp_int_subidFrom IN NUMBER, tmp_subKindid IN NUMBER, frm_str_subSelected IN VARCHAR2, frm_str_optionSelected IN VARCHAR2, tmp_added_by IN CHAR, tmp_addedby_id IN NUMBER
) IS
-- define two dim array TYPE data_t IS TABLE OF NUMBER INDEX BY binary_integer; TYPE array_t IS TABLE OF data_t INDEX BY binary_integer; arrPriv array_t;
kindid VARCHAR2(50); extlicenceid NUMBER(11); tmp_str_subSelected VARCHAR2(5000); tmp_str_optionSelected VARCHAR2(5000);
tmpExtLicId NUMBER; tmpDefaultValue VARCHAR2(10);
iPrivId NUMBER(11); iPrivValue NUMBER(11); sData VARCHAR2(5000); iPos NUMBER(11); iPos1 NUMBER(11); iCnt NUMBER(3); sData1 VARCHAR2(5000); iPos2 NUMBER(11); iPos3 NUMBER(11);
BEGIN
-- create a two dim array of selected subscribers tmp_str_subSelected := frm_str_subSelected; LOOP -- split the string of selected subscribers - frm_str_subSelected iPos := INSTR(tmp_str_subSelected, ',');
IF (NVL(iPos,0) = 0) THEN sData:= LTRIM(RTRIM(tmp_str_subSelected)); ELSE sData:= LTRIM(RTRIM(SUBSTR(tmp_str_subSelected,1,iPos-1))); END IF;
iPos1 := INSTR(sData, '#');
iPrivId := LTRIM(RTRIM(SUBSTR(sData,1,iPos1-1))); iPrivValue := LTRIM(RTRIM(SUBSTR(sData,iPos1+1)));
-- split iCnt :=0; LOOP iCnt:= iCnt +1;
iPos2 := INSTR(iPrivValue, '|');
IF (NVL(iPos2,0) = 0) THEN sData1:= LTRIM(RTRIM(iPrivValue)); ELSE sData1:= LTRIM(RTRIM(SUBSTR(iPrivValue,1,iPos2-1))); END IF; arrPriv(iPrivId)(iCnt):= sData1;
EXIT WHEN (iPos2 = 0); iPrivValue := SUBSTR(iPrivValue, iPos2+1); END LOOP;
EXIT WHEN (iPos = 0); tmp_str_optionSelected := SUBSTR(tmp_str_subSelected, iPos+1); END LOOP; -- end of array creation iPrivId:=0; iPos:=0; sData:=;
-- get the all the priv and the corr option selected tmp_str_optionSelected := frm_str_optionSelected;
LOOP iPos := INSTR(tmp_str_optionSelected, ',');
IF (NVL(iPos,0) = 0) THEN sData:= LTRIM(RTRIM(tmp_str_optionSelected)); ELSE sData:= LTRIM(RTRIM(SUBSTR(tmp_str_optionSelected,1,iPos-1))); END IF;
iPos1 := INSTR(sData, '#');
iPrivId := LTRIM(RTRIM(SUBSTR(sData,1,iPos1-1))); iPrivValue := LTRIM(RTRIM(SUBSTR(sData,iPos1+1)));
-- check whether there exists a rule or main record in the extended_licence table for the tmp_int_subidFrom and the tmp_subKindid
SELECT extended_licence_id, default_value INTO tmpExtLicId, tmpDefaultValue FROM EXTENDED_LICENCE WHERE sub_id_from=tmp_int_subidFrom AND ext_lic_sub_kind=tmp_subKindid AND is_active='y' AND privileges_id=iPrivId AND is_delete='n';
IF (tmpExtLicId >0) THEN
IF (tmpDefaultValue != iPrivValue) THEN -- update the default value UPDATE EXTENDED_LICENCE SET default_value=iPrivValue WHERE extended_licence_id=tmpExtLicId; END IF;
-- delete all the previous records from dependency table extended_licence_sub for this extended licence reocrd DELETE FROM extended_licence_sub WHERE extended_licence_id=tmpExtLicId; -- ELSE -- insert a default record INSERT INTO EXTENDED_LICENCE ( EXTENDED_LICENCE_ID, SUB_ID_FROM, EXT_LIC_SUB_KIND, PRIVILEGES_ID, DEFAULT_VALUE, IS_ACTIVE, IS_DELETE, ADDDT, ADDED_BY, ADDED_BY_ID ) VALUES ( extended_licence_seq.NEXTVAL , tmp_int_subidFrom, tmp_subKindid, iPrivId, iPrivValue, 'y', 'n', SYSDATE, tmp_added_by, tmp_addedby_id );
SELECT extended_licence_seq.CURRVAL INTO tmpExtLicId FROM dual; END IF;
-- insert the dependency records into the extended_licence_sub table
FOR i IN arrPriv(iPrivId).FIRST..arrPriv(iPrivId).LAST LOOP -- insert into extended_licence_sub INSERT INTO EXTENDED_LICENCE_SUB ( EXTENDED_LICENCE_ID, SUB_ID_TO , PRIVILEGES_VALUE ) VALUES ( tmpExtLicId, arrPriv(iPrivId)(i), iPrivValue ); END LOOP; EXIT WHEN (iPos = 0); tmp_str_optionSelected := SUBSTR(tmp_str_optionSelected, iPos+1);
END LOOP;
END;
ORACLE PROBLEMS ORA-30036: Unable to extend segment by %s in undo tablespace '%s'
The undo tablespace you are currently using is unable to extent. There is not enough space left either due to the datafiles being full, autoextend which is not set at datafile level or due to a disk which's full.
You'll have to check the size of the datafiles attached to the undo tablespace and check whether they can autoextend or not..
select file_name, bytes, autoextensible, maxbytes from dba_data_files where tablespace_name='here UNDO TABLESPACE_NAME'
Either add more datafiles to the undo tablespace, set the autoextensible flag or enlarge the datafile(s).
To add more space to a file issue following command:
alter database datafile 'C:\ORACLE\ORADATA\UNDO01.DBF' resize 1000m;
To turn on the autoextend feature on a datafile use following command:
alter database datafile 'C:\ORACLE\ORADATA\UNDO01.DBF' autoextend on next 100m maxsize 2000m;
To add a new datafile to the undo tablespace use following command:
alter tablespace UNDOTBS01 add datafile 'C:\ORACLE\ORADATA\UNDOTBS02.DBF' autoextend on next 100m maxsize 2000m;
temporary tablespace ALTER DATABASE TEMPFILE 'D:\ORA9IAS\ORADATA\INTRA\TEMP01.DBF'
AUTOEXTEND ON
data file
ALTER DATABASE DATAFILE 'D:\ORA9IAS\ORADATA\INTRA\TEMP01.DBF'
AUTOEXTEND ON
c.ctl -- control file loading a big ascii/txt file into oracle database --via sql loader
LOAD DATA INFILE 'D:\ora9ias\fpcompst.c01' APPEND INTO TABLE PAF1 FIELDS TERMINATED BY "\n" (POSTCODE )
call sql loader -command sqlldr sat/sat@intra control=D:\ora9ias\c.ctl
site LINK :