BookmarkSubscribeRSS Feed
HeidiDT
Quartz | Level 8

Hi All

Has anyone ever had the need to log the start and end dates and times for SAS campaigns? We would like to do this (logging the information into (an) Oracle table(s)), so that we can:

1. Create a dashboard showing which campaigns are currently running

2. Expand this further in order to log the start and end times for individual nodes in the campaigns

 

Any advice would be appreciated!

4 REPLIES 4
Shmuel
Garnet | Level 18

Locate in your code where the campaign starts and insert a new record with the starting variable using datetime() function.

You need keep the recordID in memory in order to update that record when the campaign ends, again using the datetime() function.

At that time you can calculate how long did it take.

 

Without having your code this design is the most I can let you.

HeidiDT
Quartz | Level 8

Hi

I am not sure what you mean when you say "locate in your code", I have never tried to view the generated code - how do I do that? And how do I insert code into the auto-generated code? 

Shmuel
Garnet | Level 18

In your first post you wrote 

...need to log the start and end dates and times for SAS campaigns

what do you mean by "sas campaign" ? Is it a program to run? is it a set of transactions treated inside a program?

how do you know when it starts? when it ends? 

In order to write info to a log you have to add some code to do it while program runs.

You need to know where to enter that code and how to code it.

 

HeidiDT
Quartz | Level 8

Hi

No it is not a SAS program, it is a campaign designed in SAS CI Studio. So I think we are talking about different things here Smiley Happy

SAS Innovate 2025: Save the Date

 SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!

Save the date!

SAS Enterprise Guide vs. SAS Studio

What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.

Find more tutorials on the SAS Users YouTube channel.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 4 replies
  • 1417 views
  • 0 likes
  • 2 in conversation