I have a script that is rather long. In one section I need the below portion to be executed only if a specific table is not empty. ...just need someone to help with making this happen. If the table has records, then the below snippet will run and then the rest of the script will continue. if the table does not have records, then the below snippet will not run and then the rest of the script will continue.
----------------------
var last_parent number;
BEGIN
SELECT max(parentcategoryID) into :last_parent
FROM SC_1_Parent_Collections;
dbms_output.put_line('last row number = ' || :last_parent);
END;
/
print last_parent;
column last_parent format 999999
column last_parent new_value last_parent noprint
select :last_parent as last_parent from dual;
Insert Into SC_1_Parent_Collections (parentcategoryID, parentcategoryName, partnerType, activeDate, timestamp, isUpdated, region, thumbnailImageUrl, LangID) VALUES (&last_parent + 1, 'New Additions', 'All', to_char(SYSDATE, 'yyyy-mm-dd'), to_char(LOCALTIMESTAMP(0), 'yyyy-mm-dd hh24:mi:ss'), '0', 'AmFO,EMEA,GC,JFO,K-SAP', '0','1')
Hi there.
Thanks for using our wesite freelancer com.
I can correct this sql script for you, it will be easy to add that condition on the empty table you are after.
I am available now, please ping me and we can get started bro.
Kind regards,
Sergio
Hello
I read your project description.
It is interested in me.
Because I have a rich experiences of developing web for almost 10 years.
So if you hire on me, you will get a dark horse.
Ok.
Hi
Hope you are doing well. I have 7yrs of experience on web developement with various assignment completed successfully and looking forward for many more.
I have great knowledge in sql queries in oracle mysql etc.
Hi, employer.
I am a full-experienced web and mobile developer over 7+ years.
And I have great colleagues who are able to satisfy the customer's requirements thoroughly.
If you believe and adopt me, I will get it done without fail.
Hi
I have more than 3 years of experience working with Sql Server,
in my past job for the deployment queries we validates if tables were empty to execute them, so i know how to do what you need
Thank you
I have 12+ years of working experience with multiple technologies and databases including SQL, would love to help you achieve your goals. Please provide more information about the project. Thanks.
Hi,
I have 4+ years of experience in Microsoft Dynamics Ax(Erp) as a technical Consultant.
Following are the responsibilities as a technical Consultant which i performed in these Years.
- Requirement Gathering sessions with Clients.
- Developed new reports from scratch & also customized default reports of Ax.
- Developed new forms from scratch & also customized default forms of Ax.
- Developing Complete Indent Process which includes (Tables,Erd relation,,Forms,reports,etc).
- Customized default workflows.
- Developed new Workflows.
- Complete knowledge & experience of Aif Services.
- Developed Workflow Android App by Consuming Aif services of Dynamics Ax. So user can perform Workflow tasks by App
- Developed & customized Sql ssrs reports.
- Expert in Sql (Complex queries,Store Procedures,Views etc)
- Expert in developing & designing Ssrs Sql Reports
- Customized Crystal Reports.
Because i am Technical Consultant of Dynamics AX (Erp), I have strong Expertise in Sql. In these 4+ years i have developed & Customized reports almost daily that's why to deal with complex queries is on my finger tips, I can do this job for you easily
Thanks & regards.
Waleed Iqbal
Technical Consultant of Ax (ERP)
hi sir.
we can achieve that simply using triggers, if you want to use it inside a function a simple if statement you can specify the desired functionality.
hope to do business with you.
thanks
Youssef Sellami
I am a certified SQL Programmer with over 15 years of experience in data warehousing and analytics. I already have a solution for your project based on the information you provided.
I can do this if you are using Microsoft SQL Server, but not MySQL. If you can verify the SQL Server and version/edition, I'll be able to help you do this. Also, I would need to know if you want this to automatically run or to executed by yourself.
Finally, If you allow me to shadow you, or remote desktop to the SQL Server, I can install it for you as well.