close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Anomoly in recordset results

Thread began 2/19/2018 12:54 pm by iain331081 | Last modified 2/22/2018 10:29 am by Ray Borduin | 1341 views | 3 replies |

iain331081

Anomoly in recordset results

I have an odd one here. Well, it seems odd on first look, but is the end of the day.

I have three pages, one that shows all records (index_wa1.php, attached), one that shows records which have a country (index_wa2.php, attached), and one that shows records where the country field is blank (index_wa3.php, attached).

So index_wa1.php returns 5530 records. I would expect the sum of the other to to add up to 5530, as they all either have a country, or don't have a country. However, they add up to 5491, a discrepancy of 39.

Its not the end of the world, but it would be good to know why that was if it wasn't too much of a pain to figure out.

Sign in to reply to this post

Ray BorduinWebAssist

My only guess is that if someone has multiple rows in a joined table it could meet both criteria. So one row has a blank Country and the other has an entry, so that particular record can be returned for both cases.

Sign in to reply to this post
Did this help? Tips are appreciated...

iain331081

Thanks for having a look.

If a record was returned in both cases, would that not make the total add up to more than the 5530 records though? Which would probably make sense like you say, ie a bit of double counting somewhere. But they are adding up to less then the 5530 records.

I'll play around with the SQL in phpMyAdmin and see if I can spot what's up.

Sign in to reply to this post

Ray BorduinWebAssist

I've updated the no country page to show all records where country = '' or country IS NULL. That has gotten the number even closer and now it adds up to 3 more than the total, which could be the repeat count issue I mentioned above.

Sign in to reply to this post
Did this help? Tips are appreciated...

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...