Re: [foxboro] AIM*Historian connection on Windows

  • From: "Lowell, Timothy" <Timothy.Lowell@xxxxxxxxxxx>
  • To: "'foxboro@xxxxxxxxxxxxx'" <foxboro@xxxxxxxxxxxxx>
  • Date: Wed, 11 Apr 2012 14:06:41 -0500

Yo,

It's been a while, but I remember having all kinds of problems connecting to 
AIM*ODBC, so it is not surprising that you are having these issues.

The key is picking the right table, and structuring the timestamp portion of 
the query. I think the table you actually want is IAALARM:ALARMMESG. This 
should return all the alarm messages regardless of type. The timestamp to use 
in your Select statement is:

Time BETWEEN {ts '1996-08-08 08:50:00'} AND
{ts '1996-08-08 10:50:00'}

You need those braces and single quotes to make it work.

The document that contains this information is the AIM*Datalink document 
(B0193YJ), which has a chapter on ODBC.

I have had good success creating Visual Basic for Excel macros that get the 
process and alarm data, but that was at a previous job, and I don't have access 
to the files. I could make some inquiries if you need the code. What I remember 
from Access is that it would only grab the first nine data points no matter 
what I set as the timestamp. I never did figure out why it only got nine 
points, and I just gave up and tried VB for Excel instead.

Good luck,

Tim Lowell
Tesoro Corporation | 54741 Tesoro Rd, Kenai, AK 99611 | 907-776-3526 (work) | 
210-439-5914 (cell)

-----Original Message-----
From: foxboro-bounce@xxxxxxxxxxxxx [mailto:foxboro-bounce@xxxxxxxxxxxxx] On 
Behalf Of Yolanda Dickerson
Sent: Wednesday, April 11, 2012 10:43 AM
To: foxboro@xxxxxxxxxxxxx
Subject: Re: [foxboro] AIM*Historian connection on Windows

To the list:

I'm trying to test the ODBC connection with MS Access for hisf52. I  define
a new DSN to access the "Event Messages" database. I make a linked table
from Access to AIM*Historian using this "Event Messages" ODBC connection
and I can't get any event messages from hisf52 with IAALARM:STATEMESG
Query.Because when I run it I get a error as follows ODBC --call failed. Do
any know what is mean?

Thanks ,
Yo

Yo Dickerson
DCS Technician
Phone: (409) 723-3518
Pager: (409) 726-4281
Email: yolanda_dickerson@xxxxxxxxxxxx



                                                                           
             Yolanda                                                       
             Dickerson/US/PC/H                                             
             UNTSMAN                                                    To 
                                       foxboro@xxxxxxxxxxxxx               
             04/11/2012 07:01                                           cc 
             AM                        jim.pan@xxxxxxxxxxxxxxxx,           
                                       James.Vaught@xxxxxxxxxxxx           
                                                                   Subject 
                                       Re: [foxboro] AIM*Historian         
                                       connection on Windows(Document      
                                       link: Yolanda Dickerson)            
                                                                           
                                                                           
                                                                           
                                                                           
                                                                           
                                                                           



To the list

One quick Question
Do you have to turn off the Instance or the Collector for that historian
before checking the "Logging Msgs" field of the message Names (such as
ALARMMESG, OPRACTION, and SYSMONMSG). And then Setting the
field to "Yes" will make these event messages available to ODBC access.


Thanks Yo




Yo Dickerson
DCS Technician
Phone: (409) 723-3518
Pager: (409) 726-4281
Email: yolanda_dickerson@xxxxxxxxxxxx



                                                                           
             "Pan, Jim"                                                    
             <Jim.Pan@Foxboro.                                             
             com>                                                       To 
             Sent by:                  "'foxboro@xxxxxxxxxxxxx'"           
             foxboro-bounce@fr         <foxboro@xxxxxxxxxxxxx>             
             eelists.org                                                cc 
                                                                           
                                                                   Subject 
             11/03/2004 10:41          Re: [foxboro] AIM*Historian         
             PM                        connection on Windows               
                                                                           
                                                                           
             Please respond to                                             
             foxboro@freelists                                             
                   .org                                                    
                                                                           
                                                                           




I never used AIM*API function calls, but I did use AIM*ODBC for other
applications to query event messages from AIM*Historian.

The first thing I would do is to check the "Logging Msgs" field of the
message Names (such as ALARMMESG, OPRACTION, and SYSMONMSG). Setting the
field to "Yes" will make these event messages available to ODBC access.

The next I would do is to test the ODBC connection with MS Access. You need
to define a new DSN to access the "Event Messages" database, not the
"Message" database. Make a linked table from Access to AIM*Historian using
this "Event Messages" ODBC connection and see if you can get any event
messages from Access Query.

Jim Pan
Lifetime Learning Center
Houston



-----Original Message-----
From: foxboro-bounce@xxxxxxxxxxxxx [mailto:foxboro-bounce@xxxxxxxxxxxxx] On
Behalf Of Ales Vaupotic
Sent: Wednesday, November 03, 2004 5:24 PM
To: foxboro@xxxxxxxxxxxxx
Subject: [foxboro] AIM*Historian connection on Windows

Hi,

here is my real problem:

I have written a program which connects to AIM*Historian and collects
the RTP samples and reduction values. It works perfectly. I got stuck
when trying to get the alarm messages from AIM*Historian. I work in the
following 70-series environment:
Windows XP with SP1
I/A release 7.1
AIM*AT 3.2.1
AIM*API version 5.4.0

The problem is the fh_FdbMsgQuery call which doesn't seem to return the
data as specified in the manual. Has anyone got any experience with this
call? Also, there is fh_FdbMsgQueryFilterNew function which is not
described in the manual but works in apitst. I looked over The Cassandra
project and couldn't find a similar program. Have I missed someting? My
manual is B0193YN, rev. C, from March 3, 2003.

The other problem is ODBC and OLE*DB on Windows. I keep getting strange
resultsets from them. Sometimes RecordCount is accurate but after first
record it is already at EOF. Or, it returns different fields on two
subsequent calls with the same SQL command. The first field is sometimes
a table name or tag name and after another call there is no such field.
Wierd! Is there anyone actually using OLE*DB connetion to AIM*Historian
from PHP or ASP?

I would be happy with any other solution to get to the data I need into
my PHP or ASP or C or ....

Thanks for you help, everyone!

Ales




_______________________________________________________________________
This mailing list is neither sponsored nor endorsed by Invensys Process
Systems (formerly The Foxboro Company). Use the info you obtain here at
your own risks. Read http://www.thecassandraproject.org/disclaimer.html

foxboro mailing list:             //www.freelists.org/list/foxboro
to subscribe:         mailto:foxboro-request@xxxxxxxxxxxxx?subject=join
to unsubscribe:      mailto:foxboro-request@xxxxxxxxxxxxx?subject=leave



_______________________________________________________________________
This mailing list is neither sponsored nor endorsed by Invensys Process
Systems (formerly The Foxboro Company). Use the info you obtain here at
your own risks. Read http://www.thecassandraproject.org/disclaimer.html

foxboro mailing list:             //www.freelists.org/list/foxboro
to subscribe:         mailto:foxboro-request@xxxxxxxxxxxxx?subject=join
to unsubscribe:      mailto:foxboro-request@xxxxxxxxxxxxx?subject=leave




 
 
_______________________________________________________________________
This mailing list is neither sponsored nor endorsed by Invensys Process
Systems (formerly The Foxboro Company). Use the info you obtain here at
your own risks. Read http://www.thecassandraproject.org/disclaimer.html
 
foxboro mailing list:             //www.freelists.org/list/foxboro
to subscribe:         mailto:foxboro-request@xxxxxxxxxxxxx?subject=join
to unsubscribe:      mailto:foxboro-request@xxxxxxxxxxxxx?subject=leave
 
 
 
_______________________________________________________________________
This mailing list is neither sponsored nor endorsed by Invensys Process
Systems (formerly The Foxboro Company). Use the info you obtain here at
your own risks. Read http://www.thecassandraproject.org/disclaimer.html
 
foxboro mailing list:             //www.freelists.org/list/foxboro
to subscribe:         mailto:foxboro-request@xxxxxxxxxxxxx?subject=join
to unsubscribe:      mailto:foxboro-request@xxxxxxxxxxxxx?subject=leave
 

Other related posts: