Teradata ODBC driver with Apache/PHP
Teradata Teradata Discussion Forums Teradata.com Discussion Forum
Visit Teradata.com
Home       Guidelines    Member List
Welcome Guest ( Login | Register )
        


This online forum is for user-to-user discussions of Teradata products, and is not an official customer support channel for Teradata. If you require direct assistance, please contact Teradata support.


Teradata ODBC driver with Apache/PHP Expand / Collapse
Author
Message
Posted 8/10/2007 1:11:21 PM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: Forum Members
Last Login: 3/3/2008 12:41:28 PM
Posts: 5, Visits: 4
Has anyone successfully setup and run an Apache/PHP environment with the Teradata ODBC driver?

I can get everything running, but odbc_connect() PHP calls result in segfaults in Apache. It's strange, because running php from the command line with the same php script works fine. Looking at the trace files, it looks like the authentication step is happening, and then poof.

Any ideas of things to try?
Post #8516
Posted 9/5/2007 11:14:53 AM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: Forum Members
Last Login: 9/5/2007 10:56:00 AM
Posts: 1, Visits: 1
I have XAMPP installed on my windows desktop and the odbc_connect with PHP works okay. I tried to run odbc_connect from Linux and got an error via the command line. I haven't tried the XAMPP install on Linux yet.
Post #8801
Posted 9/5/2007 11:32:51 AM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: Forum Members
Last Login: 3/3/2008 12:41:28 PM
Posts: 5, Visits: 4
I'm not sure why (though I think it has something to do with easing filesystem access restraints), but setting the Apache directive CoreDumpDirectory makes the setup work.
Post #8802
Posted 2/27/2008 10:28:33 PM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: Forum Members
Last Login: 3/3/2008 8:07:53 AM
Posts: 2, Visits: 6
Ok, so here's my setup.
Redhat ES 5
Apache 2.2
Php 5.14
odbc 2.21
Teradata driver 8.1....all rpms installed.

when I run isql -v dbname dbuser dbpassword , I get this
[ISQL]ERROR: Could not SQLConnect

through php -> odbc_connect("edw_prod", "user", "password")
I get this...popped into the apache error_log
PHP Warning: odbc_connect() [ ]: SQL error: , SQL state 00000 in SQLConnect in

(also the same for the user's .odbc.ini)

[ODBC]
InstallDir = /usr/odbc
Trace = Yes
TraceDll = /usr/odbc/lib/odbctrac.so
TraceFile = /edw/trace.log
TraceAutoStop = 0

[ODBC Data Sources]
default = tdata.so
edw_prod = tdata.so

[edw_prod]
Driver = /usr/odbc/drivers/tdata.so
Description = EDW PROD 5380
DSNTraceEnable = Yes
DBCName = serverIP
LastUser =
Username = user
Password =
Database = prod
DateTimeFormat = AAA
SessionMode = ANSI



[ODBC DRIVERS]
Teradata = Installed
Trace = Yes
UsageCount = 4

[Teradata]
Driver = /usr/odbc/drivers/tdata.so
UsageCount = 2
APILevel = CORE
ConnectFunctions = YYY
DriverODBCVer = 3.51
SQLLevel = 1


HOME=/edw
TWB_ROOT=/opt/teradata/client/tbuild/08.01.00.02
TD_ICU_DATA=/opt/teradata/tdicu/lib
ODBCINST=/etc/odbcinst.ini

Guys, need your help ! been struggling in getting this working for over 3 days now.


if all else fails, rm -rf /
Post #10730
Posted 3/3/2008 8:08:52 AM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: Forum Members
Last Login: 3/3/2008 8:07:53 AM
Posts: 2, Visits: 6
no one have a setup like this at all???
Linux/apache/php ?
bunch of winblows users on here or what?


if all else fails, rm -rf /
Post #10771
Posted 3/3/2008 12:43:50 PM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: Forum Members
Last Login: 3/3/2008 12:41:28 PM
Posts: 5, Visits: 4
My guess would be the programs are not finding the odbc files correctly. Use 'strace' to run isql and carefully look at the strace output to see if there are some necessary file isql can not find. This will take you time.
Post #10779
« Prev Topic | Next Topic »


Reading This Topic Expand / Collapse
Active Users: 0 ( 0 guests, 0 members, 0 anonymous members )
No members currently viewing this topic.


All times are GMT -5:00, Time now is 5:04pm

Powered By InstantForum.NET v4.1.4 © 2008
Execution: 0.078. 9 queries. Compression Disabled.