X-Original-To: pgsql-odbc-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 66C608B9F3A for ; Fri, 18 Feb 2005 17:23:10 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 77189-08 for ; Fri, 18 Feb 2005 17:23:01 +0000 (GMT) Received: from gk-us2.michelin.com (gk-us2.michelin.com [156.65.14.19]) by svr1.postgresql.org (Postfix) with ESMTP id 2E3CA8B9F55 for ; Fri, 18 Feb 2005 17:22:59 +0000 (GMT) Received: from ONCMH1.onc.michelin.com (unverified) by gk-us2.michelin.com (Content Technologies SMTPRS 4.3.10) with ESMTP id for ; Fri, 18 Feb 2005 12:15:28 -0500 Received: from oncmtap1.onc.michelin.com by oncmh1.onc.michelin.com with ESMTP for pgsql-odbc@postgresql.org; Fri, 18 Feb 2005 12:17:30 -0500 Received: from oncems01.onc.michelin.com ([156.65.125.150]) by oncmtap1.onc.michelin.com (Netscape Messaging Server 4.15) with ESMTP id IC4AY800.CCW for ; Fri, 18 Feb 2005 12:22:56 -0500 Received: from us.michelin.com (unverified) by oncems01.onc.michelin.com (Content Technologies SMTPRS 4.2.5) with ESMTP id ; Fri, 18 Feb 2005 12:22:56 -0500 Message-Id: <4216246B.2090605@us.michelin.com> Date: Fri, 18 Feb 2005 12:22:51 -0500 From: "Greg Campbell" User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.6) Gecko/20040113 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Steve Backman Cc: pgsql-odbc@postgresql.org Subject: Re: More Problems with ODBC and Access References: <6.2.1.2.2.20050217214558.04e65b30@pop.earthlink.net> In-Reply-To: <6.2.1.2.2.20050217214558.04e65b30@pop.earthlink.net> Content-Type: multipart/mixed; boundary="------------080800000604050108020903" X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.032 tagged_above=0 required=5 tests=AWL X-Spam-Level: X-Archive-Number: 200502/88 X-Sequence-Number: 4978 This is a multi-part message in MIME format. --------------080800000604050108020903 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit On the BIG-INT IDs. I'm pretty sure Access has an Integer of 16-bit and a Long Integer of 32-bit that it understands. In PG that's int2 and int4 respectively. I think int8 or 64-bit are problematic for Access because the ODBC conversion must choose between string and decimal and float single or double. I am really not sure if decimal or float(singles or doubles) serve well as a primary keys, especially for an exact match parent-child / primary key-foreign key relationship. It seem a little limiting but I try to limit my non-string primary keys to int4 and serial int4 (not big serial). If it works Access should not complain about being unable to identify a primary key if you link a table manually.I would check my ODBC driver settings on how it treats int8 (datasource button - tab 2). Unfortunately, I haven't personally done forms with subforms for parent-child relations using the PostgreSQL ODBC served datasource. I've only done it with Access tables, but I do wish you good luck. Steve Backman wrote: > Thanks to follks who posted ideas about resolving connection problems > between Access and pgsql. SOme ideas may have helped; some now. > > I tried a couple different versions of the newer drivers. i updated > the MDAC install. I set registry timeout to 0. > > On newer version of the ODBC drivers, including 7.02.0005 and > 8.00.0004, things got worse, not better. WIth them, the Access forms > did not show any sub-forms with parent child data. I could open all > the tables individually, and I can view the sub-form on its own, but > if I open the main form, I can an error and no child data. I have > listed a snipped from the 8.00.0004 version log below. > > So, I put the version back to 7.03.2000 which is where I started with > last summer. This version works better, except not stable (loses > connection after a while, as I described before) > > Related: What makes big int id's in pg show up as decimals in Access? > Could this be part of the problem? Does it matter whether the id's are > big ints or just ints? Do any of the settings refer to this? The > documentation of the settings leaves some room for improvement... > > I also have seen some random comments about the present of time stamp > fields, booleans, memo/text fields. I'm not sure its worth > restructuring the database and the web site around it in order to test > these possibilities without more insight. > > Also, does anyone have a sense of whether links created in code are > deficient in some ways compared to links created through Access IDE? > > here's sample problematic sql. In opening the form, first the log > shows query for main table (individual...), which works. Then shows > trying to get a child table, org affiliations for an individual, which > failed on recent versions of the driver. > > conn=201676480, query='SELECT > "public"."org_ind"."org_ind_id","public"."individual"."firstname" > ,"public"."individual"."lastname" FROM > "public"."org_ind","public"."individual" WHERE (( 4129' > ERROR from backend during send_query: 'ERROR: syntax error at end of > input at character 168' > STATEMENT ERROR: func=SC_execute, desc='', errnum=7, errmsg='Error > while executing the query' > > ------------------------------------------------------------ > hdbc=201676480, stmt=201912520, result=174373392 > manual_result=0, prepare=0, internal=0 > bindings=0, bindings_allocated=0 > parameters=174370736, parameters_allocated=1 > statement_type=0, statement='SELECT > "public"."org_ind"."org_ind_id","public"."individual"."firstname" > ,"public"."individual"."lastname" FROM > "public"."org_ind","public"."individual" WHERE (( ? = > "public"."org_ind"."org_id" ) AND ("public"."org_ind"."ind_id" = > "public"."individual"."individual_id" ) ) ' > stmt_with_params='SELECT > "public"."org_ind"."org_ind_id","public"."individual"."firstname" > ,"public"."individual"."lastname" FROM > "public"."org_ind","public"."individual" WHERE (( 4129' > data_at_exec=-1, current_exec_param=-1, put_data=0 > currTuple=-1, current_col=-1, lobj_fd=-1 > maxRows=0, rowset_size=1, keyset_size=0, > cursor_type=0, scroll_concurrency=1 > cursor_name='SQL_CUR0C08F0C8' > ----------------QResult Info > ------------------------------- > fields=174381160, manual_tuples=0, backend_tuples=0, > tupleField=0, conn=0 > fetch_count=0, num_total_rows=0, num_fields=0, > cursor='(NULL)' > message='ERROR: syntax error at end of input at > character 168', command='(NULL)', notice='(NULL)' > status=7, inTuples=0 > CONN ERROR: func=SC_execute, desc='', errnum=110, errmsg='ERROR: > syntax error at end of input at character 168' > ------------------------------------------------------------ > henv=174339688, conn=201676480, status=1, num_stmts=16 > sock=201675736, stmts=174383240, lobj_type=-999 > ---------------- Socket Info ------------------------------- > socket=836, reverse=0, errornumber=0, errormsg='(NULL)' > buffer_in=174385016, buffer_out=201655216 > buffer_filled_in=1, buffer_filled_out=0, buffer_read_in=1 > > sorry for long post. > > > Steven A Backman - Database Designs Associates, Inc. > PO Box 715 - Jamaica Plain, MA 02130 > 617-889-0929 personal fax: 309-404-2252 > sbackman@dbdes.com www.dbdes.com > > ---------------------------(end of broadcast)--------------------------- > TIP 6: Have you searched our list archives? > > http://archives.postgresql.org --------------080800000604050108020903 Content-Type: text/x-vcard; charset=utf8; name="greg.campbell.vcf" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="greg.campbell.vcf" begin:vcard fn:Greg Campbell n:Campbell;Greg org:Michelin North America;ENG-IT adr;dom:;;2420 Two Notch Road;Lexington;SC;29071 email;internet:greg.campbell@us.michelin.com title:Systems Engineer tel;work:803-951-5561 tel;fax:803-951-5531 x-mozilla-html:FALSE version:2.1 end:vcard --------------080800000604050108020903--