Sponsored Content
Top Forums Shell Programming and Scripting Help to check if Oracle table exists Post 302938825 by saps19 on Thursday 19th of March 2015 08:09:12 AM
Old 03-19-2015
These queries should help you...

Code:
select owner, table_name from all_tables;
select table_name from user_tables;

Use where clauses, store the result in variable. take table as user input and then run the query.

Code:
vSQLResult=`sqlplus -s DBUID/DBPASS@SCHMA <<EOF
set pages 0
set head off
set feed off
<<Your DB queries goes here>>
exit
EOF`

You can do more R&D with above suggestion.

Last edited by saps19; 03-19-2015 at 09:09 AM.. Reason: icode tag
 

9 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

check if directory exists

Hi, I need to prompt for a response from a user to enter a path read dest_dir?"Please Enter Directory :" How do I do this until a valid directory is entered by the user. I can use to check the existence of the directory. However when I try the following I cannot get it to work. while ... (2 Replies)
Discussion started by: jerardfjay
2 Replies

2. Shell Programming and Scripting

How to check if a direcorty exists?

Hi Good people :D How do I check if a directory exists, if it does then carry on rest of the script, otherwise exit. ------------- cd $mainfolder/system1 #unzips files arrived in last 24 hrs into temp directory find * -mmin -1440 -exec unzip {} \; I'd like to check here if temp... (2 Replies)
Discussion started by: SunnyK
2 Replies

3. Shell Programming and Scripting

Check the record count in table (table in oracle)

I have requirement: 1) Check the record count in table (table in oracle) 2) If records exists generate the file for existing records and wait for some time (Go to sleep mode) and Again check the record count after 10 min.......... (Loop this process if record count >0). 3) Generate touch... (1 Reply)
Discussion started by: kamineni
1 Replies

4. Shell Programming and Scripting

Check the record count in table (table in oracle)

I have requirement: 1) Check the record count in table (table in oracle) 2) If records exists generate the file for existing records and wait for some time then Go to sleep mode and Again check the record count after 10 min.......... (Loop this process if record count >0). 3) Generate touch... (1 Reply)
Discussion started by: kamineni
1 Replies

5. Shell Programming and Scripting

Check to see if a file exists?

Hi. I'd like to have an IF-Then-Else statement where I can check to see if a file exists? We have the Bourne Shell by default. I'm looking for the syntax to do something like this: if myfile.txt exists then ...my code else ...my code end if Any help would be greatly... (5 Replies)
Discussion started by: buechler66
5 Replies

6. Shell Programming and Scripting

File exists, but cannot be opened.How to check- whether it could be opened to read when it exists

Hi #Testing for file existence if ; then echo 'SCHOOL data is available for processing' else echo 'SCHOOL DATA IS NOT AVAILABLE FOR PROCESSING' : i wrote a script, where it begins by checking if file exists or not. If it exists, it truncates the database... (2 Replies)
Discussion started by: rxg
2 Replies

7. UNIX and Linux Applications

Help in copying table structure to another table with constraints in Oracle

hi, i need to copy one table with data into another table, right now am using create table table1 as select * from table2 i want the constraints of table1 to be copied to table2 also , can anyone give me some solution to copy the constraints also, now am using oracle 10.2.0.3.0... (1 Reply)
Discussion started by: senkerth
1 Replies

8. UNIX for Dummies Questions & Answers

How to check if a number exists?

Hello, May i please know how do i check if the given input argument is one of the listed numbers then success else failure. I am using bash shell. if then echo "success" else echo "failure" fi Thank you. (2 Replies)
Discussion started by: Ariean
2 Replies

9. Shell Programming and Scripting

To check if file exists

Hi, I have the below code written. However I am not getting the desired output I am checking if the particular path has file in it. #!/bin/bash ls -l /IRS2/IRS2_ODI/INFILE/*LS* 1>/dev/null 2>/dev/null if then echo $? echo "File Exists" fi ... (3 Replies)
Discussion started by: Shanmugapriya D
3 Replies
XtParseTranslationTable(3)					   XT FUNCTIONS 					XtParseTranslationTable(3)

NAME
XtParseTranslationTable, XtAugmentTranslations, XtOverrideTranslations, XtUninstallTranslations - manage translation tables SYNTAX
XtTranslations XtParseTranslationTable(String table); void XtAugmentTranslations(Widget w, XtTranslations translations); void XtOverrideTranslations(Widget w, XtTranslations translations); void XtUninstallTranslations(Widget w); ARGUMENTS
table Specifies the translation table to compile. translations Specifies the compiled translation table to merge in (must not be NULL). w Specifies the widget into which the new translations are to be merged or removed. DESCRIPTION
The XtParseTranslationTable function compiles the translation table into the opaque internal representation of type XtTranslations. Note that if an empty translation table is required for any purpose, one can be obtained by calling XtParseTranslationTable and passing an empty string. The XtAugmentTranslations function nondestructively merges the new translations into the existing widget translations. If the new transla- tions contain an event or event sequence that already exists in the widget's translations, the new translation is ignored. The XtOverrideTranslations function destructively merges the new translations into the existing widget translations. If the new transla- tions contain an event or event sequence that already exists in the widget's translations, the new translation is merged in and override the widget's translation. To replace a widget's translations completely, use XtSetValues on the XtNtranslations resource and specify a compiled translation table as the value. The XtUninstallTranslations function causes the entire translation table for widget to be removed. SEE ALSO
XtAppAddActions(3), XtCreatePopupShell(3), XtParseAcceleratorTable(3), XtPopup(3) X Toolkit Intrinsics - C Language Interface Xlib - C Language X Interface X Version 11 libXt 1.1.3 XtParseTranslationTable(3)
All times are GMT -4. The time now is 07:11 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy