I am trying to use PERL to access Service Now database using the ServiceNow API provided. I could not find any threads pertaining to this. I hope someone might be able to give me some direction.
All necessary Modules are installed. I pulled the code attempted from sample code from...
Thanks feherke.qa !!
That did work...one last question, how would I print the key with it? Example code does not work but you get the isead of what I am trying to do.
foreach my $book ($configs->{'BOOK:BOOK'}->{'BOOK:Trees'}->{'BOOK:Tree'}) {
print "$book has $book->{content} books \n";
}...
Ok ...I needed to edit it down quite a bit to give a sample. Here is the XML file and another version of Data::Dumper below that which should match up with the XML file. Again, thanks for any help/ direction that you can offer.
XML file:
<?xml version="1.0" ?>
- <BOOK:BOOKConfigurationFiles...
I have an XML file that is thousands of lines long and I need to parse it out. I am attempting to use XML::Simple to read it in and put it into a Hash Array so that I can extract what I need. However, when I go to process with foreach I cant nail down the referenced data elements from the...
I have an epoch date time stored in a table that is UTC or GMT time. I need to convert the epoch date to standard date and adjust time to local time zone(CST). CST is 6 hours behind UTC or GMT.
If I use DATEADD I can convert epoch UTC to standard datetime in UTC/GMT but how do I also adjust for...
I need some expertise. I have 2 dates pulled out of a database record. They are in scalars $date_start and $date_end. I convert the dates to epoch and get the number of days between the 2 dates and place this value in another scalar called $day_diff_in_days. So, $date_fiff_in_days can be equal...
I need some help, not sure if this is possible.
Is there a way to query a SQL field that has variable length information and pull off only specific needed information. Example:
Field Filename could have any of the following values:
c:\windows\install\bin\thisfile.dat...
Hi Dagon,
Thanks so much for the reply. I do not understand the 4 bytes either. I am going to put your code in play and see if it translates it as is expected. Thanks so much for the help. I have never come across this before so it's good to learn through this forum from folks like yourself who...
Hi all,
I have no idea how to go about this and any direction would be a great help.
I need to query a 4 byte raw data field in a table and convert the bits to string values. The db layout manual has a mapping for this field:
From the DB Manual:
field_name = day_of_week (RAW 4-bytes)...
Hi Dagon,
Yes...I was using dense_rank. However, I neglected to state in my sample that my date field was actually a date and unique time. I was specifying to_char(My_DATE, 'yyyy-mm-dd') in SELECT Statement but not in the dense_rank ORDER BY statement(I was just stating My_Date). When I changed...
Thanks Dagon,
It doesn't seem to be working. WHen I just execute the inner query with the dense rank, I see the list of unique items/schedules and in my case it ranks a specific items/schedule with 150+ records (ranked1-150) some of the same date and some of different dates. The first 6 records...
I just realized based on the query output that there are some items that have the same date. What I need is DISTINCT date and a MAX of the field Status which would tell me the highest exit code for that date. I would want to create 10 records for each item with but each of the 5 records must...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.