how to get records from a parameter query in Access?

This is a discussion on how to get records from a parameter query in Access? within the alt.comp.lang.php forums, part of the PHP Programming Forums category; Hi, Our database is Access (i know, i would be better to use Mysql, but at the present time, it'...


Go Back   Usenet Forums > PHP Programming Forums > alt.comp.lang.php

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 02-04-2006
Bill
 
Posts: n/a
Default how to get records from a parameter query in Access?

Hi,

Our database is Access (i know, i would be better to use Mysql, but at the
present time, it's access ...) and i created a parameter query (like a
stored procedure in Mysql) for identification with name 'proctest'. The
criterium in the query is [na]. PHP must execute the query with the value of
variable 'name'.
I know how to use PHP with access using dynamic sql, but i don't know how to
do with a query.
Here is a attempt, but doesn't work.
Thanks for helping
Bill

<?php
name="bibi";
$db = 'c:\\mydb.mdb';
$conn = new COM('ADODB.Connection');
$conn->Open("Provider=Microsoft.Jet.OLEDB.4.0; Data Source=$db");
$rs = $conn->Execute('proctest' na);
while (!$rs->EOF)
{
$lg=$rs->fields[0];
echo $lg;
echo "<br>";
$rs->MoveNext();
}
$rs->Close();
$conn->Close();
?>


Reply With Quote
  #2 (permalink)  
Old 02-09-2006
Drakazz
 
Posts: n/a
Default Re: how to get records from a parameter query in Access?

try msdn.com / microsoft.com / google -> "Microsoft Access procedure
list SQL query" , using Access and ODBC is not a php issue

Reply With Quote
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 11:22 PM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0