matty84 Posted November 13, 2006 Share Posted November 13, 2006 Hi,I have set up an ODBC connection so as to be able to display an archaeological finds database on the web. I have it working as I would like with a form that allows the user to search and choose which fields to return also. However, the database has 3000+ entries and this is far too many to return on one page so I was hoping to set up a pagination system. I am a beginner at PHP and have no idea how to do this - I have found some resources that deal with mysql but my attempts to modify these have failed. I was wondering if anyone could help me!!??Thanks,Matt Quote Link to comment https://forums.phpfreaks.com/topic/27086-odbc-pagination/ Share on other sites More sharing options...
printf Posted November 13, 2006 Share Posted November 13, 2006 Could you please show your code, so we can see how best to help you add this simple feature.Thanks Quote Link to comment https://forums.phpfreaks.com/topic/27086-odbc-pagination/#findComment-123862 Share on other sites More sharing options...
matty84 Posted November 13, 2006 Author Share Posted November 13, 2006 [code]<?php//ODBC CONNECTION$conn=odbc_connect('sax','','');if (!$conn){exit("Connection Failed: " . $conn);}//QUERY CRITERIA (VESSEL CHARACTERISTICS)$vesselchardrop=$_POST['vesselchardrop'];switch ($vesselchardrop){case "Any";$vesselchardrop1="";break;case "Rim";$vesselchardrop1="AND TblForm2.Rim>0.0";break;case "Base";$vesselchardrop1="AND TblForm2.Base>0.0";break;case "Handle";$vesselchardrop1="AND TblForm2.Handle>0.0";break;case "Lid";$vesselchardrop1="AND TblForm2.Lid>0.0";break;case "Neck";$vesselchardrop1="AND TblForm2.Neck>0.0";break;case "Shoulder";$vesselchardrop1="AND TblForm2.Shoulder>0.0";break;case "Body";$vesselchardrop1="AND TblForm2.Body>0.0";break;}//SQL QUERY$sql="SELECT TblForm1.SotonID, TblForm1.HungID, TblForm1.Period, TblForm1.SubPeriod, TblForm1.ExcavYear, TblForm2.Rim, TblForm2.Base, TblForm2.Handle, TblForm2.Lid, TblForm2.Neck, TblForm2.Shoulder, TblForm2.Body,TblForm2.Complete, TblForm2.Conjoinable, TblForm2.SherdNo, TblForm2.vesselForm, TblForm2.VesselType, TblForm2.SherdThickness, TblForm2.SherdrimPercentage, TblForm2.SherdBaseDiameter, TblForm2.SherdBasePercentage,TblForm3.Smoothed, TblForm3.Burnished, TblForm3.Roughened, TblForm3.Rusticated, TblForm3.Decorated, TblForm3.Slip, TblForm3.Untreated, TblForm3.Impressed, TblForm3.Incised, TblForm3.Applied, TblForm3.Painted, TblForm3.Encrusted, TblForm3.FireClouding,TblForm3.Colour, TblForm3.ExtColour, TblForm3.ExtSmoothed, TblForm3.ExtBurnished, TblForm3.ExtRoughened, TblForm3.ExtRusticated, TblForm3.ExtDecorated, TblForm3.ExtSlip, TblForm3.ExtUntreated, TblForm3.ExtImpressed, TblForm3.ExtIncised, TblForm3.ExtApplied, TblForm3.ExtPainted, TblForm3.ExtEncrusted, TblForm3.ExtRibbed, TblForm3.ExtFireClouding,TblForm3.GeneralFiringConditions, TblForm3.RyeNumber, TblForm4.Hardness, TblForm4.Feel, TblForm4.Fracture, TblForm4.PrimaryInclusionPresent, TblForm4.Frequency,TblForm4.Sorting, TblForm4.Rounding, TblForm4.AverageSize, TblForm4.PrimaryInclusion, TblForm4.SecInclusionPresent, TblForm4.SecFrequency, TblForm4.SecSorting, TblForm4.SecRounding, TblForm4.SecAverageSize, TblForm4.SecInclusion, TblForm4.OtherInclusionPresent, TblForm4.OtherInclusion,TblForm5.Residue, TblForm5.Sooting, TblForm5.ReBurning, TblForm5.Abrasion, TblForm5.Limescale, TblForm5.Pitting, TblForm5.Other,TblForm5.ExtResidue, TblForm5.ExtSooting, TblForm5.ExtReBurning, TblForm5.ExtAbrasion, TblForm5.ExtLimescale, TblForm5.ExtOther, TblForm6.PhotoNumberFROM TblForm1, TblForm2, TblForm3, TblForm4, TblForm5, TblForm6 WHERE TblForm1.SotonID=TblForm2.SotonID AND TblForm1.SotonID=TblForm3.SotonID AND TblForm1.SotonID=TblForm4.SotonID AND TblForm1.SotonID=TblForm5.SotonID AND TblForm1.SotonID=TblForm6.SOtonID$vesselchardrop1ORDER BY TblForm1.SotonID";$rs=odbc_exec($conn,$sql);if (!$rs){exit("Error in SQL");}//TABLE HEADINGSecho "<table><tr>";echo "<th>SotonID</th>";echo "<th>HungID</th>";$periodcheck=$_POST['periodcheck'];if ($periodcheck=="on")echo "<th>Period</th><th>Sub Period</th>";$excavyearcheck=$_POST['excavyearcheck'];if ($excavyearcheck=="on")echo "<th>Excav Year</th>";$vesselcharacteristicscheck=$_POST['vesselcharacteristicscheck'];if ($vesselcharacteristicscheck=="on")echo "<th>Vessel Characteristics</th><th>Vessel Form</th><th>Vessel Type</th>";$completecheck=$_POST['completecheck'];if ($completecheck=="on")echo "<th>Complete</th>";$conjoinablecheck=$_POST['conjoinablecheck'];if ($conjoinablecheck=="on")echo "<th>Conjoinable</th>";$sherddetailscheck=$_POST['sherddetailscheck'];if ($sherddetailscheck=="on")echo "<th>Sherd No.</th><th>Sherd Thickness</th><th>Sherd Rim %</th><th>Sherd Base Diameter</th><th>Sherd Base %</th>";$intdecorationcheck=$_POST['intdecorationcheck'];if ($intdecorationcheck=="on")echo "<th>Interior Decoration</th><th>Interior Colour</th>";$extdecorationcheck=$_POST['extdecorationcheck'];if ($extdecorationcheck=="on")echo "<th>Exterior Decoration</th><th>Exterior Colour</th>";$firingconditionscheck=$_POST['firingconditionscheck'];if ($firingconditionscheck=="on")echo "<th>Firing Conditions</th>";$ryenumbercheck=$_POST['ryenumbercheck'];if ($ryenumbercheck=="on")echo "<th>Rye Number</th>";$hardnesscheck=$_POST['hardnesscheck'];if ($hardnesscheck=="on")echo "<th>Hardness</th>";$feelcheck=$_POST['feelcheck'];if ($feelcheck=="on")echo "<th>Feel</th>";$fracturecheck=$_POST['fracturecheck'];if ($fracturecheck=="on")echo "<th>Fracture</th>";$primaryinclusioncheck=$_POST['primaryinclusioncheck'];if ($primaryinclusioncheck=="on")echo "<th>Primary Inclusion Present</th><th>Primary Inclusion Frequency</th><th>Primary Inclusion Sorting</th><th>Primary Inclusion Rounding</th><th>Primary Inclusion Average Size</th><th>Primary Inclusion Notes</th>";$secondaryinclusioncheck=$_POST['secondaryinclusioncheck'];if ($secondaryinclusioncheck=="on")echo "<th>Secondary Inclusion Present</th><th>Secondary Frequency</th><th>Secondary Sorting</th><th>Secondary Rounding</th><th>Secondary Average Size</th><th>Secondary Inclusion Notes</th>";$otherinclusioncheck=$_POST['otherinclusioncheck'];if ($otherinclusioncheck=="on")echo "<th>Other Inclusion Present</th><th>Other Inclusion Notes</th>";$intusewearcheck=$_POST['intusewearcheck'];if ($intusewearcheck=="on")echo "<th>Interior Use Wear</th>";$extusewearcheck=$_POST['extusewearcheck'];if ($extusewearcheck=="on")echo "<th>Exterior Use Wear</th>";$photocheck=$_POST['photocheck'];if ($photocheck=="on")echo "<th>Photo</th>";echo "</tr>";while (odbc_fetch_row($rs)){//RESULTS VARIABLES$sotonid=odbc_result($rs,"SotonID");$hungid=odbc_result($rs,"HungID");$period=odbc_result($rs,"Period");$subperiod=odbc_result($rs,"SubPeriod");$excavyear=odbc_result($rs,"ExcavYear");$complete=odbc_result($rs,"Complete");$conjoinable=odbc_result($rs,"Conjoinable");$sherdno=odbc_result($rs,"SherdNo");$vesselform=odbc_result($rs,"VesselForm");$vesseltype=odbc_result($rs,"VesselType");$sherdthickness=odbc_result($rs,"SherdThickness");$sherdrimpercentage=odbc_result($rs,"SherdRimPercentage");$sherdbasediameter=odbc_result($rs,"SherdBaseDiameter");$sherdbasepercentage=odbc_result($rs,"SherdBasePercentage");$interiorcolour=odbc_result($rs,"Colour");$extcolour=odbc_result($rs,"ExtColour");$firingconditions=odbc_result($rs,"GeneralFiringConditions");$ryenumber=odbc_result($rs,"RyeNumber");$hardness=odbc_result($rs,"Hardness");$feel=odbc_result($rs,"Feel");$fracture=odbc_result($rs,"Fracture");$primaryinclusionpresent=odbc_result($rs,"PrimaryInclusionPresent");$frequency=odbc_result($rs,"Frequency");$sorting=odbc_result($rs,"Sorting");$rounding=odbc_result($rs,"Rounding");$averagesize=odbc_result($rs,"AverageSize");$primaryinclusionnotes=odbc_result($rs,"PrimaryInclusion");$secinclusionpresent=odbc_result($rs,"SecInclusionPresent");$secfrequency=odbc_result($rs,"SecFrequency");$secsorting=odbc_result($rs,"SecSorting");$secrounding=odbc_result($rs,"SecRounding");$secaveragesize=odbc_result($rs,"SecAverageSize");$secinclusionnotes=odbc_result($rs,"SecInclusion");$otherinclusionpresent=odbc_result($rs,"OtherInclusionPresent");$otherinclusionnotes=odbc_result($rs,"OtherInclusion");$photo=odbc_result($rs,"PhotoNumber");//VESSEL CHARACTERISTICS CONDITIONS$rim=odbc_result($rs,"Rim");$base=odbc_result($rs,"Base");$handle=odbc_result($rs,"Handle");$lid=odbc_result($rs,"Lid");$neck=odbc_result($rs,"Neck");$shoulder=odbc_result($rs,"Shoulder");$body=odbc_result($rs,"Body");if ($rim=="0.0")$rim1="";else$rim1="Rim,";if ($base=="0.0")$base1="";else$base1="Base,";if ($handle=="0.0")$handle1="";else$handle1="Handle,";if ($lid=="0.0")$lid1="";else$lid1="Lid,";if ($neck=="0.0")$neck1="";else$neck1="Neck,";if ($shoulder=="0.0")$shoulder1="";else$shoulder1="Shoulder,";if ($body=="0.0")$body1="";else$body1="Body,";//INTERIOR DECORATION$smoothed=odbc_result($rs,"Smoothed");$burnished=odbc_result($rs,"Burnished");$roughened=odbc_result($rs,"Roughened");$rusticated=odbc_result($rs,"Rusticated");$decorated=odbc_result($rs,"Decorated");$slip=odbc_result($rs,"Slip");$untreated=odbc_result($rs,"Untreated");$impressed=odbc_result($rs,"Impressed");$incised=odbc_result($rs,"Incised");$applied=odbc_result($rs,"Applied");$painted=odbc_result($rs,"Painted");$encrusted=odbc_result($rs,"Encrusted");$fireclouding=odbc_result($rs,"FireClouding");if ($smoothed=="0")$smoothed1="";else$smoothed1="Smoothed,";if ($burnished=="0")$burnished1="";else$burnished1="Burnished,";if ($roughened=="0")$roughened1="";else$roughened1="Roughened,";if ($rusticated=="0")$rusticated1="";else$rusticated1="Rusticated,";if ($decorated=="0")$decorated1="";else$decorated1="Decorated,";if ($slip=="0")$slip1="";else$slip1="Slip,";if ($untreated=="0")$untreated1="";else$untreated1="Untreated,";if ($impressed=="0")$impressed1="";else$impressed1="Impressed,";if ($incised=="0")$incised1="";else$incised1="Incised,";if ($applied=="0")$applied1="";else$applied1="Applied,";if ($painted=="0")$painted1="";else$painted1="Painted,";if ($encrusted=="0")$encrusted1="";else$encrusted1="Encrusted,";if ($fireclouding=="0")$fireclouding1="";else$fireclouding1="Fire Clouding,";//EXTERIOR DECORATION$extsmoothed=odbc_result($rs,"Smoothed");$extburnished=odbc_result($rs,"Burnished");$extroughened=odbc_result($rs,"Roughened");$extrusticated=odbc_result($rs,"Rusticated");$extdecorated=odbc_result($rs,"Decorated");$extslip=odbc_result($rs,"Slip");$extuntreated=odbc_result($rs,"Untreated");$extimpressed=odbc_result($rs,"Impressed");$extincised=odbc_result($rs,"Incised");$extapplied=odbc_result($rs,"Applied");$extpainted=odbc_result($rs,"Painted");$extencrusted=odbc_result($rs,"Encrusted");$extribbed=odbc_result($rs,"Ribbed");$extfireclouding=odbc_result($rs,"FireClouding");if ($extsmoothed=="0")$extsmoothed1="";else$extsmoothed1="Smoothed,";if ($extburnished=="0")$extburnished1="";else$extburnished1="Burnished,";if ($extroughened=="0")$extroughened1="";else$extroughened1="Roughened,";if ($extrusticated=="0")$extrusticated1="";else$extrusticated1="Rusticated,";if ($extdecorated=="0")$extdecorated1="";else$extdecorated1="Decorated,";if ($extslip=="0")$extslip1="";else$extslip1="Slip,";if ($extuntreated=="0")$extuntreated1="";else$extuntreated1="Untreated,";if ($extimpressed=="0")$extimpressed1="";else$extimpressed1="Impressed,";if ($extincised=="0")$extincised1="";else$extincised1="Incised,";if ($extapplied=="0")$extapplied1="";else$extapplied1="Applied,";if ($extpainted=="0")$extpainted1="";else$extpainted1="Painted,";if ($extencrusted=="0")$extencrusted1="";else$extencrusted1="Encrusted,";if ($extribbed=="0")$extribbed1="";else$extribbed1="Ribbed,";if ($extfireclouding=="0")$extfireclouding1="";else$extfireclouding1="Fire Clouding,";//INTERIOR USE WEAR$residue=odbc_result($rs,"Residue");$sooting=odbc_result($rs,"Sooting");$reburning=odbc_result($rs,"ReBurning");$abrasion=odbc_result($rs,"Abrasion");$limescale=odbc_result($rs,"Limescale");$pitting=odbc_result($rs,"Pitting");$other=odbc_result($rs,"Other");if ($residue=="1")$residue1="Residue,";else$residue1="";if ($sooting=="1")$sooting1="Sooting, ";else$sooting1="";if ($reburning=="1")$reburning1="Reburning,";else$reburning1="";if ($abrasion=="1")$abrasion1="Abrasion,";else$abrasion1="";if ($limescale=="1")$limescale1="Limescale";else$limescale1="";if ($pitting=="1")$pitting1="Pitting";else$pitting1="";//EXTERIOR USE WEAR$extresidue=odbc_result($rs,"ExtResidue");$extsooting=odbc_result($rs,"ExtSooting");$extreburning=odbc_result($rs,"ExtReBurning");$extabrasion=odbc_result($rs,"ExtAbrasion");$extlimescale=odbc_result($rs,"ExtLimescale");$extpitting=odbc_result($rs,"ExtPitting");$extother=odbc_result($rs,"ExtOther");if ($extresidue=="1")$extresidue1="Residue,";else$extresidue1="";if ($extsooting=="1")$extsooting1="Sooting, ";else$extsooting1="";if ($extreburning=="1")$extreburning1="Reburning,";else$extreburning1="";if ($extabrasion=="1")$extabrasion1="Abrasion,";else$extabrasion1="";if ($extlimescale=="1")$extlimescale1="Limescale";else$extlimescale1="";//OTHER VARIABLE CONDITIONSif ($complete=="1")$complete1="Yes";else$complete1="No";if ($primaryinclusionpresent=="1")$primaryinclusionpresent1="Yes";else$primaryinclusionpresent1="No";if ($secinclusionpresent=="1")$secinclusionpresent1="Yes";else$secinclusionpresent1="No";//TABLE OUTPUTecho "<tr><td>$sotonid</td>";echo "<td>$hungid</td>";$periodcheck=$_POST['periodcheck'];if ($periodcheck=="on")echo "<td>$period</td><td>$subperiod</td>";$excavyearcheck=$_POST['excavyearcheck'];if ($excavyearcheck=="on")echo "<td>$excavyear</td>";$vesselcharacteristicscheck=$_POST['vesselcharacteristicscheck'];if ($vesselcharacteristicscheck=="on")echo "<td>$rim1 $base1 $handle1 $lid1 $neck1 $shoulder1 $body1</td><td>$vesselform</td><td>$vesseltype</td>";$completecheck=$_POST['completecheck'];if ($completecheck=="on")echo "<td>$complete1</td>";$conjoinablecheck=$_POST['conjoinablecheck'];if ($conjoinablecheck=="on")echo "<td>$conjoinable</td>";$sherddetailscheck=$_POST['sherddetailscheck'];if ($sherddetailscheck=="on")echo "<td>$sherdno</td><td>$sherdthickness</td><td>$sherdrimpercentage</td><td>$sherdbasediameter</td><td>$sherdbasepercentage</td>";$intdecorationcheck=$_POST['intdecorationcheck'];if ($intdecorationcheck=="on")echo "<td>$smoothed1 $burnished1 $roughened1 $rusticated1 $decorated1 $slip1 $untreated1 $impressed1 $incised1 $applied1 $painted1 $encrusted1 $fireclouding1</td><td>$interiorcolour</td>";$extdecorationcheck=$_POST['extdecorationcheck'];if ($extdecorationcheck=="on")echo "<td>$extsmoothed1 $extburnished1 $extroughened1 $extrusticated1 $extdecorated1 $extslip1 $extuntreated1 $extimpressed1 $extincised1 $extapplied1 $extpainted1 $extencrusted1 $extribbed $extfireclouding1</td><td>$extcolour</td>";$firingconditionscheck=$_POST['firingconditionscheck'];if ($firingconditionscheck=="on")echo "<td>$firingconditions</td>";$ryenumbercheck=$_POST['ryenumbercheck'];if ($ryenumbercheck=="on")echo "<td>$ryenumber</td>";$hardnesscheck=$_POST['hardnesscheck'];if ($hardnesscheck=="on")echo "<td>$hardness</td>";$feelcheck=$_POST['feelcheck'];if ($feelcheck=="on")echo "<td>$feel</td>";$fracturecheck=$_POST['fracturecheck'];if ($fracturecheck=="on")echo "<td>$fracture</td>";$primaryinclusioncheck=$_POST['primaryinclusioncheck'];if ($primaryinclusioncheck=="on")echo "<td>$primaryinclusionpresent1</td><td>$frequency</td><td>$sorting</td><td>$rounding</td><td>$averagesize</td><td>$primaryinclusionnotes</td>";$secondaryinclusioncheck=$_POST['secondaryinclusioncheck'];if ($secondaryinclusioncheck=="on")echo "<td>$secinclusionpresent1</td><td>$secfrequency</td><td>$secsorting</td><td>$secrounding</td><td>$secaveragesize</td><td>$secinclusionnotes</td>";$otherinclusioncheck=$_POST['otherinclusioncheck'];if ($otherinclusioncheck=="on")echo "<td>$otherinclusionpresent</td><td>$otherinclusionnotes</td>";$intusewearcheck=$_POST['intusewearcheck'];if ($intusewearcheck=="on")echo "<td>$residue1 $sooting1 $reburning1 $abrasion1 $limescale1 $pitting1 $other</td>";$extusewearcheck=$_POST['extusewearcheck'];if ($extusewearcheck=="on")echo "<td>$extresidue1 $extsooting1 $extreburning1 $extabrasion1 $extlimescale1 $extother</td>";$photocheck=$_POST['photocheck'];if ($photocheck=="on")echo "<td><a href=dbimages/$photo target=new>$photo</a></td>";echo "</tr>";}odbc_close($conn);echo "</table>";?>[/code] Quote Link to comment https://forums.phpfreaks.com/topic/27086-odbc-pagination/#findComment-123869 Share on other sites More sharing options...
printf Posted November 13, 2006 Share Posted November 13, 2006 Can you just tell me the database type, so I can write you a simple function for the paging!Sonia Quote Link to comment https://forums.phpfreaks.com/topic/27086-odbc-pagination/#findComment-123883 Share on other sites More sharing options...
matty84 Posted November 13, 2006 Author Share Posted November 13, 2006 It is an Access Database that I connect through ODBC System DSNMatt Quote Link to comment https://forums.phpfreaks.com/topic/27086-odbc-pagination/#findComment-123885 Share on other sites More sharing options...
printf Posted November 13, 2006 Share Posted November 13, 2006 I'll write you a simple paging link function, but you really need to think about changing some of your code. You use many conditions if('on'), but still process db results outside of those conditions. Then what are all those $var[b]1[/b] for, if your not using [b]$var[/b] and need to assign a different value base on a return result, then do that condition when you fetch the result, because the way your doing it you are making (2) variables and making (2) conditions for (1) single variable! Which is more code executions, that you don't need to do!We use conditions (if, switch, ...) so as to stop or to execute some code that does or does not need to be executed based on the condition. So when you use a condition but don't include all the (stop or execute) logic in that condition you are not creating a logical, manageable application.Look at this example....[code]while(db result resource){ $var = db_fetch($res, 'some_var'); if ( $var == '0' ) { $var1 = 'this'; } else { $var1 = ''; } if ( $_POST['show_some_var'] == 'on' ) { echo $var1; }}[/code]Now, see what your doing...1. fetch a result (that may never be used)2. create copy of $var based on a if() condition (that may never be used)3. the real condition that should control everything is last, it should be first, encompassing (1 and 2 )I'll post a paging example in a little bit!Sonia Quote Link to comment https://forums.phpfreaks.com/topic/27086-odbc-pagination/#findComment-123943 Share on other sites More sharing options...
matty84 Posted November 13, 2006 Author Share Posted November 13, 2006 Sonia,i am rather a beginning and what you just said makes a lot of sense and to be honest is obvious really! I have gone through and begun removing redundant code....there's rather a lot!!! Thanks for helping out with the pagination :)Matt Quote Link to comment https://forums.phpfreaks.com/topic/27086-odbc-pagination/#findComment-123952 Share on other sites More sharing options...
printf Posted November 13, 2006 Share Posted November 13, 2006 HiSorry for the slow reply, I had a meeting that kind of went on longer than I expected. Anyway, I had a few minutes, so I rewrote the code and added a simple paging function to the script. I didn't place the variable [b]$links[/b] in the code, because I didn't know where you want it placed. You can put it anywhere, like right above the <table> opening or below the </table> close, you could put one above and below if you want paging at the top and bottom of the page! So where ever you place [b]$links[/b], will display the simple paging option => (<< prev [jump to page] next >> )! The paging is only shown if you have more results than a single page of results!See the attachment...SoniaSorry I put the wrong file before, I fixed it now[attachment deleted by admin] Quote Link to comment https://forums.phpfreaks.com/topic/27086-odbc-pagination/#findComment-124115 Share on other sites More sharing options...
matty84 Posted November 13, 2006 Author Share Posted November 13, 2006 Many thanks for your help.However when I try and implement the code I get an SQL error I think it is because ACCESS does not recognise LIMIT as an SQL command. Is there a way around this?Matt Quote Link to comment https://forums.phpfreaks.com/topic/27086-odbc-pagination/#findComment-124145 Share on other sites More sharing options...
printf Posted November 14, 2006 Share Posted November 14, 2006 ya, I forgot about that MS Access only supports TOP, so I have been trying to figure a way around the problem...Can you answer this question...Do your tables have unique id, if they do then we could create a fake offset based on the unique id...Say we are at 55, of 500 records, and we want to show the next 5 records 56 to 60, we could[code]SELECT TOP 55 uid AS last_id FROM table ORDER BY uid DESC;[/code]That would give us the last uid, so we could do...[code]SELECT TOP 5 what_to_select_here FROM table WHERE conditions AND uid > last_id[/code]It's a extra query but it would work. But it depends on the tables having a unique id that matches how you want to sort the tables [b]TblForm1.SotonID[/b]That's why I try never to use access, if don't mind emailing me the database, I could get this to work for you without changing the database, doing what I explained, that's all I can do, but I can't do it without doing real time query testing, so I need the database! So I can see what is happening...If you want to do that PM me and I will give you my email.Sonia Quote Link to comment https://forums.phpfreaks.com/topic/27086-odbc-pagination/#findComment-124182 Share on other sites More sharing options...
matty84 Posted November 14, 2006 Author Share Posted November 14, 2006 Hi,Many thanks Sonia. As I am a noobie I cannot PM people, could you possible PM me? I do have a unique ID - my only concern is that if a serach is done and there are no results with unique ID 55-60 then will any results be shown? I really wish I wasnt using an MS database but the woman I am doing this project for updates in Access and wants the db kept that way (its a university project).Thanks Matt. Quote Link to comment https://forums.phpfreaks.com/topic/27086-odbc-pagination/#findComment-124359 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.