Ask a Question related to ASP Database, Design and Development.
-
David #1
Re: "find duplicates" sql query
Access from Office 2000
"Hans" <hansb@sorry.nospam.com> wrote in message
news:eer8XdbMEHA.628@TK2MSFTNGP11.phx.gbl...work> Hi!
>
> I don't know which database you are using but something like this might> (there may be some typos of course)
>
> Select formtype, entrydate, ipaddress from formdate group by formtype,
> entrydate, ipaddress having count(*) >1 order by ipaddress
>
> Regards
> /Hans
>
>
David Guest
-
ColdFusion+cfquery+Oracle+CLOB+"Query of Query"
Error message is: Query Of Queries runtime error. Unsupported SQL type "java.sql.Types.CLOB". My database table: RESMIGAZETEFIHRISTI: ... -
cfgrid inside a <cfoutput query="myQuery" group="GROUP">
Is it possible to use a cfgrid inside a cfoutput with a query and a group. When I try do that I get the following error: INVALID_CHARACTER_ERR:... -
"cannot find server or DNS error" after installing 1394 card in XP system
After intalling a 1394 firewire card in my xp machine, IE can no longer connect to the internet. Even after I remove the card and uninstall it... -
"Unable to find the plugin that handles this media type" - Shockwave
Can anyone help me with this please? In DreamweaverMX, I insert a shockwave file on the webpage, and when I click on play I get that message. it... -
"The system cannot find the file specified." when invoking method ~HTTP Get/Post
Developed and successfully tested my web service on a development server with .asmx mapped to v1.0.3705 \aspnet_isapi.dll, but when I migrated it... -
David #2
Re: "find duplicates" sql query
Sorry - forgot to include original post:-
I want to do a query that displays duplicate records in the database based
on IP address. What syntax should I use in the WHERE********** bit please?
Thanks,
set rsData = con.execute("SELECT formtype, entrydate, ipaddress FROM
formdata WHERE ************ ORDER BY ipaddress")
arData = rsData.getrows
David Guest
-
Aaron Bertrand - MVP #3
Re: "find duplicates" sql query
Please pick *ONE* newsgroup to post messages to. This is the correct one;
asp.general is not.
--
Aaron Bertrand
SQL Server MVP
[url]http://www.aspfaq.com/[/url]
"David" <david.brown@tesco.net> wrote in message
news:O4Nlc.287$dl3.242@newsfe1-win...> Sorry - forgot to include original post:-
>
> I want to do a query that displays duplicate records in the database based
> on IP address. What syntax should I use in the WHERE********** bit please?
>
> Thanks,
>
> set rsData = con.execute("SELECT formtype, entrydate, ipaddress FROM
> formdata WHERE ************ ORDER BY ipaddress")
> arData = rsData.getrows
>
>
Aaron Bertrand - MVP Guest
-
Phillip Windell #4
Re: "find duplicates" sql query
Well I'll take a "stab" since no one else has. I think GROUP BY might be
better than ORDER BY but decide that for yourself.
To show all entries:
SELECT formtype, entrydate, ipaddress FROM formdata GROUP BY ipaddress
To show a specific IP#
SELECT formtype, entrydate, ipaddress FROM formdata WHERE ipaddress = "<your
input>" GROUP BY ipaddress"
--
Phillip Windell [MCP, MVP, CCNA]
[url]www.wandtv.com[/url]
"David" <david.brown@tesco.net> wrote in message
news:O4Nlc.287$dl3.242@newsfe1-win...> Sorry - forgot to include original post:-
>
> I want to do a query that displays duplicate records in the database based
> on IP address. What syntax should I use in the WHERE********** bit please?
>
> Thanks,
>
> set rsData = con.execute("SELECT formtype, entrydate, ipaddress FROM
> formdata WHERE ************ ORDER BY ipaddress")
> arData = rsData.getrows
>
>
Phillip Windell Guest
-
Gary Jones #5
Re: "find duplicates" sql query
SELECT formtype, entrydate, fd.ipaddress FROM formdata fd
INNER JOIN
(SELECT ipaddress, [count] = count(*)-1 FROM formdata GROUP BY by ipaddress)
dup
AND dup.ipaddress = fd.ipaddress AND dup.[count] > 0
"David" <david.brown@tesco.net> wrote in message
news:O4Nlc.287$dl3.242@newsfe1-win...> Sorry - forgot to include original post:-
>
> I want to do a query that displays duplicate records in the database based
> on IP address. What syntax should I use in the WHERE********** bit please?
>
> Thanks,
>
> set rsData = con.execute("SELECT formtype, entrydate, ipaddress FROM
> formdata WHERE ************ ORDER BY ipaddress")
> arData = rsData.getrows
>
>
Gary Jones Guest



Reply With Quote

