471,071 Members | 3,839 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,071 software developers and data experts.

QUERY HELP: Selecting distinct for two columns group by one

Greetings.

I'm having a little trouble with a query. The idea is simple I need to
display a list of recently unique visited URLs and the last time I
visited.

I have 2 table one stores the user and time/date and another has the
URL.

So all I need is the URL (no duplicates) and the last visit.

Below is the SQL to create the tables and data to help with the query.

Thank you for your help.
CREATE TABLE [stat_hits] (
[hit_id] [int] (1, 1) NOT NULL ,
[hit_date] [datetime] NOT NULL CONSTRAINT [DF_stat_hits_hit_date]
DEFAULT (getdate()),
[user_id] [varchar] (12) NOT NULL ,
[hit_ip] [varchar] (15) NOT NULL ,
[shp_id] [int] NOT NULL ,
CONSTRAINT [PK_stat_hits] PRIMARY KEY CLUSTERED
(
[hit_id]
) ON [PRIMARY]
) ON [PRIMARY]
GO
CREATE TABLE [stat_hit_pages] (
[shp_id] [int] (1, 1) NOT NULL ,
[shp_url] [varchar] (1000) NULL ,
[shp_count] [int] NULL ,
CONSTRAINT [PK_stat_hit_pages] PRIMARY KEY CLUSTERED
(
[shp_id]
) ON [PRIMARY]
) ON [PRIMARY]
GO
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37878,'2005-06-01 16:07:35','ADMIN','0.0.0.0',7323)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37877,'2005-06-01 16:07:13','ADMIN','0.0.0.0',7323)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37876,'2005-06-01 15:41:17','ADMIN','0.0.0.0',7339)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37875,'2005-06-01 15:41:03','ADMIN','0.0.0.0',7323)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37874,'2005-06-01 15:20:31','ADMIN','0.0.0.0',7330)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37873,'2005-06-01 15:20:28','ADMIN','0.0.0.0',7338)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37872,'2005-06-01 14:45:46','ADMIN','0.0.0.0',7338)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37871,'2005-06-01 14:35:51','ADMIN','0.0.0.0',7338)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37870,'2005-06-01 14:30:25','ADMIN','0.0.0.0',7338)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37869,'2005-06-01 14:28:28','ADMIN','0.0.0.0',7338)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37868,'2005-06-01 14:28:23','ADMIN','0.0.0.0',7325)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37867,'2005-06-01 14:28:17','ADMIN','0.0.0.0',7322)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37866,'2005-06-01 14:28:15','ADMIN','0.0.0.0',7321)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37861,'2005-06-01 14:27:09','ADMIN','0.0.0.0',7339)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37860,'2005-06-01 14:27:05','ADMIN','0.0.0.0',7323)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37859,'2005-06-01 14:26:59','ADMIN','0.0.0.0',7322)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37858,'2005-06-01 14:26:58','ADMIN','0.0.0.0',7321)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37853,'2005-06-01 14:25:59','ADMIN','0.0.0.0',7338)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37852,'2005-06-01 14:23:51','ADMIN','0.0.0.0',7338)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37851,'2005-06-01 13:58:49','ADMIN','0.0.0.0',7338)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37850,'2005-06-01 13:44:06','ADMIN','0.0.0.0',7330)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37849,'2005-06-01 13:44:04','ADMIN','0.0.0.0',7321)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37848,'2005-06-01 13:44:04','ADMIN','0.0.0.0',7340)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37847,'2005-06-01 13:43:58','ADMIN','0.0.0.0',7330)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37846,'2005-06-01 13:43:53','ADMIN','0.0.0.0',7338)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37845,'2005-06-01 13:26:29','ADMIN','0.0.0.0',7325)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37844,'2005-06-01 13:22:34','ADMIN','0.0.0.0',7338)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37843,'2005-06-01 13:22:29','ADMIN','0.0.0.0',7325)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37842,'2005-06-01 13:21:15','ADMIN','0.0.0.0',7338)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37841,'2005-06-01 13:19:17','ADMIN','0.0.0.0',7338)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37840,'2005-06-01 13:17:20','ADMIN','0.0.0.0',7321)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37839,'2005-06-01 13:17:20','ADMIN','0.0.0.0',7320)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37838,'2005-06-01 11:55:15','ADMIN','0.0.0.0',7339)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37837,'2005-06-01 11:55:09','ADMIN','0.0.0.0',7323)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37836,'2005-06-01 11:53:08','ADMIN','0.0.0.0',7338)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37835,'2005-06-01 11:53:01','ADMIN','0.0.0.0',7325)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37834,'2005-06-01 11:34:34','ADMIN','0.0.0.0',7337)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37833,'2005-06-01 11:34:24','ADMIN','0.0.0.0',7336)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37832,'2005-06-01 11:02:59','ADMIN','0.0.0.0',7335)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37831,'2005-06-01 11:02:53','ADMIN','0.0.0.0',7334)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37830,'2005-06-01 11:02:46','ADMIN','0.0.0.0',7324)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37829,'2005-06-01 11:02:40','ADMIN','0.0.0.0',7333)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37828,'2005-06-01 11:02:31','ADMIN','0.0.0.0',7332)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37827,'2005-06-01 11:02:25','ADMIN','0.0.0.0',7323)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37826,'2005-06-01 11:02:21','ADMIN','0.0.0.0',7331)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37825,'2005-06-01 11:02:12','ADMIN','0.0.0.0',7323)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37824,'2005-06-01 11:01:23','ADMIN','0.0.0.0',7330)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37823,'2005-06-01 11:01:21','ADMIN','0.0.0.0',7328)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37822,'2005-06-01 11:01:20','ADMIN','0.0.0.0',7327)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37821,'2005-06-01 10:58:23','ADMIN','0.0.0.0',7330)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37820,'2005-06-01 10:58:10','ADMIN','0.0.0.0',7328)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37819,'2005-06-01 10:58:09','ADMIN','0.0.0.0',7327)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37818,'2005-06-01 10:55:27','ADMIN','0.0.0.0',7326)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37817,'2005-06-01 10:55:23','ADMIN','0.0.0.0',7325)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37816,'2005-06-01 10:55:17','ADMIN','0.0.0.0',7322)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37815,'2005-06-01 10:55:16','ADMIN','0.0.0.0',7321)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37810,'2005-06-01 10:54:20','ADMIN','0.0.0.0',7330)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37809,'2005-06-01 10:54:12','ADMIN','0.0.0.0',7329)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37808,'2005-06-01 10:51:30','ADMIN','0.0.0.0',7328)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37807,'2005-06-01 10:51:29','ADMIN','0.0.0.0',7327)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37806,'2005-06-01 10:51:10','ADMIN','0.0.0.0',7328)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37805,'2005-06-01 10:51:09','ADMIN','0.0.0.0',7327)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37804,'2005-06-01 10:35:46','ADMIN','0.0.0.0',7326)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37803,'2005-06-01 10:35:41','ADMIN','0.0.0.0',7325)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37802,'2005-06-01 10:35:29','ADMIN','0.0.0.0',7323)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37801,'2005-06-01 10:35:21','ADMIN','0.0.0.0',7321)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37800,'2005-06-01 10:35:20','ADMIN','0.0.0.0',7320)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37799,'2005-06-01 10:33:58','ADMIN','0.0.0.0',7321)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37798,'2005-06-01 10:33:50','ADMIN','0.0.0.0',7328)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37797,'2005-06-01 10:33:50','ADMIN','0.0.0.0',7327)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37796,'2005-06-01 10:33:09','ADMIN','0.0.0.0',7326)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37795,'2005-06-01 10:33:05','ADMIN','0.0.0.0',7325)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37794,'2005-06-01 10:32:45','ADMIN','0.0.0.0',7324)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37793,'2005-06-01 10:32:18','ADMIN','0.0.0.0',7323)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37792,'2005-06-01 10:31:47','ADMIN','0.0.0.0',7322)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37791,'2005-06-01 10:31:31','ADMIN','0.0.0.0',7321)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37790,'2005-06-01 10:31:31','ADMIN','0.0.0.0',7320)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37789,'2005-06-01 10:30:04','ADMIN','0.0.0.0',7320)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37788,'2005-05-31 20:49:56','ADMIN','0.0.0.0',7311)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37787,'2005-05-31 20:49:54','ADMIN','0.0.0.0',5942)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37786,'2005-05-31 20:49:54','ADMIN','0.0.0.0',31)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37785,'2005-05-31 20:49:02','ADMIN','0.0.0.0',5942)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37784,'2005-05-31 20:48:54','ADMIN','0.0.0.0',7311)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37783,'2005-05-31 20:48:53','ADMIN','0.0.0.0',5942)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37782,'2005-05-31 20:48:52','ADMIN','0.0.0.0',31)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37781,'2005-05-31 20:48:41','ADMIN','0.0.0.0',5941)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37780,'2005-05-31 20:48:37','ADMIN','0.0.0.0',215)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37779,'2005-05-31 20:48:30','ADMIN','0.0.0.0',4)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37775,'2005-05-31 20:46:44','ADMIN','0.0.0.0',7311)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37774,'2005-05-31 20:46:40','ADMIN','0.0.0.0',7319)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37773,'2005-05-31 20:46:39','ADMIN','0.0.0.0',31)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37772,'2005-05-31 20:46:12','ADMIN','0.0.0.0',7311)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37771,'2005-05-31 20:46:09','ADMIN','0.0.0.0',7319)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37770,'2005-05-31 20:46:08','ADMIN','0.0.0.0',31)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37769,'2005-05-31 20:45:55','ADMIN','0.0.0.0',7311)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37768,'2005-05-31 20:45:52','ADMIN','0.0.0.0',7319)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37767,'2005-05-31 20:45:51','ADMIN','0.0.0.0',31)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37766,'2005-05-31 20:45:33','ADMIN','0.0.0.0',7311)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37765,'2005-05-31 20:45:29','ADMIN','0.0.0.0',7319)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37764,'2005-05-31 20:45:29','ADMIN','0.0.0.0',31)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37763,'2005-05-31 20:45:28','ADMIN','0.0.0.0',31)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37762,'2005-05-31 20:44:52','ADMIN','0.0.0.0',7311)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37761,'2005-05-31 20:44:48','ADMIN','0.0.0.0',7319)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37760,'2005-05-31 20:44:47','ADMIN','0.0.0.0',31)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37759,'2005-05-31 20:44:23','ADMIN','0.0.0.0',7311)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37758,'2005-05-31 20:44:18','ADMIN','0.0.0.0',7319)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37757,'2005-05-31 20:44:18','ADMIN','0.0.0.0',31)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37756,'2005-05-31 20:43:50','ADMIN','0.0.0.0',6258)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37755,'2005-05-31 20:43:41','ADMIN','0.0.0.0',7311)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37754,'2005-05-31 20:43:37','ADMIN','0.0.0.0',7318)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37753,'2005-05-31 20:43:36','ADMIN','0.0.0.0',31)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37752,'2005-05-31 20:43:31','ADMIN','0.0.0.0',7317)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37751,'2005-05-31 20:43:16','ADMIN','0.0.0.0',7311)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37750,'2005-05-31 20:43:10','ADMIN','0.0.0.0',6684)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37749,'2005-05-31 20:43:10','ADMIN','0.0.0.0',31)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37748,'2005-05-31 20:40:04','ADMIN','0.0.0.0',7318)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37747,'2005-05-31 20:40:00','ADMIN','0.0.0.0',31)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37746,'2005-05-31 20:39:52','ADMIN','0.0.0.0',7317)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37745,'2005-05-31 20:39:24','ADMIN','0.0.0.0',7316)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37744,'2005-05-31 20:39:23','ADMIN','0.0.0.0',31)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37743,'2005-05-31 20:35:56','ADMIN','0.0.0.0',7315)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37742,'2005-05-31 20:35:43','ADMIN','0.0.0.0',7311)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37741,'2005-05-31 20:34:17','ADMIN','0.0.0.0',7314)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37740,'2005-05-31 20:34:17','ADMIN','0.0.0.0',1449)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37739,'2005-05-31 20:34:01','ADMIN','0.0.0.0',7313)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37738,'2005-05-31 20:33:54','ADMIN','0.0.0.0',7312)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37737,'2005-05-31 20:12:57','ADMIN','0.0.0.0',6681)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37736,'2005-05-31 20:09:40','ADMIN','0.0.0.0',6681)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37735,'2005-05-31 20:09:33','ADMIN','0.0.0.0',6258)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37734,'2005-05-31 20:09:03','ADMIN','0.0.0.0',6681)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37733,'2005-05-31 20:08:49','ADMIN','0.0.0.0',7289)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37732,'2005-05-31 20:08:44','ADMIN','0.0.0.0',6254)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37731,'2005-05-31 20:08:42','ADMIN','0.0.0.0',3443)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37730,'2005-05-31 20:08:40','ADMIN','0.0.0.0',7282)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37729,'2005-05-31 20:08:32','ADMIN','0.0.0.0',5983)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37728,'2005-05-31 20:08:24','ADMIN','0.0.0.0',6960)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37727,'2005-05-31 20:08:22','ADMIN','0.0.0.0',5918)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37726,'2005-05-31 20:08:18','ADMIN','0.0.0.0',25)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37725,'2005-05-31 20:08:15','ADMIN','0.0.0.0',5740)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37724,'2005-05-31 20:08:11','ADMIN','0.0.0.0',4)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37723,'2005-05-31 20:08:09','ADMIN','0.0.0.0',3)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37720,'2005-05-31 20:08:03','ADMIN','0.0.0.0',4)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37617,'2005-05-31 18:51:08','ADMIN','0.0.0.0',7290)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37615,'2005-05-31 18:51:00','ADMIN','0.0.0.0',7289)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37598,'2005-05-31 18:48:08','ADMIN','0.0.0.0',7282)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37597,'2005-05-31 18:48:04','ADMIN','0.0.0.0',6103)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37596,'2005-05-31 18:48:03','ADMIN','0.0.0.0',31)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37595,'2005-05-31 18:47:21','ADMIN','0.0.0.0',7282)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37594,'2005-05-31 18:47:12','ADMIN','0.0.0.0',6960)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37593,'2005-05-31 18:47:09','ADMIN','0.0.0.0',5918)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37592,'2005-05-31 18:47:02','ADMIN','0.0.0.0',5740)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37590,'2005-05-31 18:46:59','ADMIN','0.0.0.0',6587)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37583,'2005-05-31 18:46:40','ADMIN','0.0.0.0',9)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37582,'2005-05-31 18:46:31','ADMIN','0.0.0.0',1691)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37580,'2005-05-31 18:46:18','ADMIN','0.0.0.0',9)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37576,'2005-05-31 18:46:04','ADMIN','0.0.0.0',6979)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37575,'2005-05-31 18:46:02','ADMIN','0.0.0.0',5942)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37574,'2005-05-31 18:46:01','ADMIN','0.0.0.0',31)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37569,'2005-05-31 18:45:24','ADMIN','0.0.0.0',6979)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37568,'2005-05-31 18:45:16','ADMIN','0.0.0.0',6103)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37567,'2005-05-31 18:45:16','ADMIN','0.0.0.0',31)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37563,'2005-05-31 18:44:07','ADMIN','0.0.0.0',6979)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37562,'2005-05-31 18:44:05','ADMIN','0.0.0.0',6103)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37561,'2005-05-31 18:44:04','ADMIN','0.0.0.0',31)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37545,'2005-05-31 18:40:30','ADMIN','0.0.0.0',6979)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37544,'2005-05-31 18:40:30','ADMIN','0.0.0.0',6103)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37543,'2005-05-31 18:40:12','ADMIN','0.0.0.0',31)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37536,'2005-05-31 18:34:19','ADMIN','0.0.0.0',6979)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37535,'2005-05-31 18:34:15','ADMIN','0.0.0.0',6103)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37534,'2005-05-31 18:34:14','ADMIN','0.0.0.0',31)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37532,'2005-05-31 18:27:02','ADMIN','0.0.0.0',6979)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37531,'2005-05-31 18:27:00','ADMIN','0.0.0.0',6103)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37530,'2005-05-31 18:27:00','ADMIN','0.0.0.0',31)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37518,'2005-05-31 18:00:34','ADMIN','0.0.0.0',6979)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37517,'2005-05-31 18:00:31','ADMIN','0.0.0.0',6103)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37516,'2005-05-31 18:00:31','ADMIN','0.0.0.0',31)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37515,'2005-05-31 17:59:41','ADMIN','0.0.0.0',6979)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37514,'2005-05-31 17:59:37','ADMIN','0.0.0.0',6103)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37513,'2005-05-31 17:59:37','ADMIN','0.0.0.0',31)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37512,'2005-05-31 17:59:01','ADMIN','0.0.0.0',6979)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37511,'2005-05-31 17:58:58','ADMIN','0.0.0.0',6103)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37510,'2005-05-31 17:58:57','ADMIN','0.0.0.0',31)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37509,'2005-05-31 17:56:16','ADMIN','0.0.0.0',6610)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37508,'2005-05-31 17:56:07','ADMIN','0.0.0.0',6989)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37507,'2005-05-31 17:56:01','ADMIN','0.0.0.0',6610)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37506,'2005-05-31 17:55:56','ADMIN','0.0.0.0',7271)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37505,'2005-05-31 17:55:52','ADMIN','0.0.0.0',7199)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37504,'2005-05-31 17:55:43','ADMIN','0.0.0.0',7271)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37503,'2005-05-31 17:55:41','ADMIN','0.0.0.0',7199)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37502,'2005-05-31 17:53:57','ADMIN','0.0.0.0',7269)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37501,'2005-05-31 17:53:44','ADMIN','0.0.0.0',6979)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37500,'2005-05-31 17:53:40','ADMIN','0.0.0.0',6103)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37499,'2005-05-31 17:53:40','ADMIN','0.0.0.0',31)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37498,'2005-05-31 17:52:18','ADMIN','0.0.0.0',7269)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37497,'2005-05-31 17:52:06','ADMIN','0.0.0.0',7271)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37496,'2005-05-31 17:51:28','ADMIN','0.0.0.0',6979)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37495,'2005-05-31 17:51:22','ADMIN','0.0.0.0',6103)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37494,'2005-05-31 17:51:22','ADMIN','0.0.0.0',31)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37493,'2005-05-31 17:51:01','ADMIN','0.0.0.0',6979)
INSERT INTO [stat_hits]
([hit_id],[hit_date],[user_id],[hit_ip],[shp_id]) VALUES
(37492,'2005-05-31 17:50:57','ADMIN','0.0.0.0',6103)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(3,'/scripts/iMenu.asp?_Ref=450493&_XID=40000000&ParentID=',224 5)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(4,'/scripts/objects/MyZBF.asp?_XID=19999900&_Ref=450493&_Ref2=',2917)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7329,'/scripts/objects/list.asp?_XID=70000005&_Ref=1398186089&_reset=true &_table=2002000&|MenuID=40000000',0)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7330,'/scripts/objects/edit.asp?_XID=70000005&_Ref=1398186089&_table=2002 000&_item=ADAMDOUG',5)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7331,'/scripts/objects/edit.asp?_XID=70000028&_Ref=1398186089&_table=1002 009&_item=225000000',0)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7332,'/scripts/objects/edit.asp?_XID=70000028&_Ref=1398186089&_table=1002 009&_item=215000000',0)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7333,'/scripts/objects/list.asp?_XID=70000028&_Ref=1398186089&_table=1002 009&',0)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7334,'/scripts/objects/list.asp?_XID=70000028&_Ref=1398186089&_table=1001 000&_parenturl=1',0)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7335,'/scripts/objects/edit.asp?_XID=70000028&_Ref=1398186089&_table=1001 000&_item=1002009&_parenturl=1',0)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7336,'/scripts/objects/edit.asp?_XID=70000028&_Ref=1398186089&_table=1001 054&_item=1000006&_parenturl=3',0)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7337,'/scripts/objects/edit.asp?_xid=70000028&_ref=1398186089&_table=1001 054&&_parenturl=3',0)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7338,'/scripts/objects/navigator.asp?_xid=70000030&_ref=1398186089',12)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7339,'/scripts/objects/navigator.asp?_xid=70000028&_ref=1398186089',2)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7340,'/scripts/iKnow.asp?_ref=1398186089&_deep=http%3A//ZBFw2kdev01/scripts/objects/edit.asp%3F_XID%3D70000005%26_Ref%3D1398186089%26_ table%3D2002000%26_item%3DADAMDOUG',0)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(9,'/scripts/objects/list.asp?_XID=70000052&_Ref=450493&_reset=true&_ta ble=215000001&|MenuID=40000000',1532)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(25,'/scripts/objects/list.asp?_XID=70000028&_Ref=450493&_reset=true&_ta ble=1002009&|MenuID=40000000',144)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(31,'/scripts/objects/save.asp?',3986)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(215,'/scripts/objects/list.asp?_XID=70000030&_Ref=450493&_reset=true&_ta ble=3001062&|MenuID=40000000',138)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(1449,'/scripts/objects/mappings.asp?',17)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(1691,'/scripts/objects/edit.asp?_XID=70000052&_Ref=450493&_table=21500000 1&_item=11',26)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(3443,'/scripts/objects/list.asp?_XID=70000028&_Ref=450493&_table=1001000& _parenturl=2',16)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(5740,'/scripts/objects/consolemaster.asp?_XID=80000003&_Ref=450493&_reset =true&showall=false&page_id=215000002&|MenuID=4000 0000',177)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(5918,'/scripts/objects/consolemaster.asp?_XID=80000003&_Ref=450493&showal l=false&mode=listitself&item=215000006&page_id=215 000002',15)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(5941,'/scripts/objects/edit.asp?_XID=70000030&_Ref=450493&_table=3001062& _item=12',9)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(5942,'/scripts/objects/edit.asp?_XID=70000030&_Ref=450493&_table=3001062& _item=12&_formtab=&process=&step=&elem=',62)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(5983,'/scripts/objects/edit.asp?_XID=70000028&_Ref=450493&_table=1002009& _item=225000000',15)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(6103,'/scripts/objects/edit.asp?_XID=70000028&_Ref=450493&_table=1001002& _parenturl=3&_item=215000018&_formtab=&process=&st ep=&elem=',21)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(6254,'/scripts/objects/edit.asp?_XID=70000028&_Ref=450493&_table=1001000& _item=225000001&_parenturl=2',4)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(6258,'/scripts/objects/edit.asp?_XID=70000028&_Ref=450493&_table=1001000& _item=225000001&_parenturl=2&',4)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(6587,'/scripts/objects/consolemaster.asp?_XID=80000004&_Ref=450493&_reset =true&showall=false&page_id=215000003&|MenuID=4000 0000',81)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(6610,'/scripts/objects/consolemaster.asp?_XID=80000004&_Ref=450493&showal l=false&page_id=215000003',88)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(6681,'/scripts/objects/edit.asp?_XID=70000028&_Ref=450493&_table=1001054& _item=225000175&_parenturl=4',3)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(6684,'/scripts/objects/edit.asp?_XID=70000028&_Ref=450493&_table=1001054& _parenturl=4&_item=225000175&_formtab=&process=&st ep=&elem=',7)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(6960,'/scripts/objects/edit.asp?_XID=80000003&_Ref=450493&_table=21500000 1&_item=68',3)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(6979,'/scripts/objects/edit.asp?_XID=70000052&_Ref=450493&_table=21500000 1&_item=161&process=215000001&step=215000003&elem= 215000018',25)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(6989,'/scripts/objects/consolemaster.asp?_XID=80000004&_Ref=450493&showal l=false&mode=drill&item=215000120&drill_id=2150000 05&page_id=215000003&group=1&desc=BTFG',54)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7199,'/scripts/objects/consolemaster.asp?_XID=80000004&_Ref=450493&showal l=false&page_id=215000006',24)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7269,'/scripts/objects/consolemaster.asp?_XID=80000004&_Ref=450493&showal l=false&page_id=215000010',3)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7271,'/scripts/objects/consolemaster.asp?_XID=80000004&_Ref=450493&showal l=false&mode=listitself&item=215000200&page_id=215 000006&group=1&desc=Operations%20Executive',3)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7282,'/scripts/objects/edit.asp?_XID=80000003&_Ref=450493&_table=21500000 1&_item=68&process=215000001&step=215000003&elem=2 15000018',2)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7289,'/scripts/objects/edit.asp?_xid=80000003&_ref=450493&_table=22500000 1&_item=75&_parenturl=1',1)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7290,'/scripts/objects/edit.asp?_xid=80000003&_ref=450493&_table=21500001 6&_item=86&_parenturl=1',0)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7311,'/scripts/objects/edit.asp?_XID=80000003&_Ref=450493&_table=22500000 1&_item=75',11)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7312,'/scripts/objects/showpopup.asp?_XID=80000003&_Ref=450493&_table=225 000001&_item=75&destable=225000001&_mode=mappings& _seed=72528.66',0)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7313,'/scripts/objects/mappings.asp?_XID=80000003&_Ref=450493&_table=2250 00001&_item=75&destable=225000001&_mode=mappings&_ seed=72528.66&_popup=true',0)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7314,'/scripts/objects/edit.asp?_XID=80000003&_Ref=450493&_table=22500000 1&_item=90&process=&step=&elem=',0)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7315,'/scripts/objects/edit.asp?_xid=80000003&_ref=450493&_table=22500000 1&_item=90',0)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7316,'/scripts/objects/edit.asp?_xid=80000003&_ref=450493&_table=22500000 1&_item=90&_formtab=0&process=&step=&elem=',0)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7317,'/scripts/objects/edit.asp?_xid=80000003&_ref=450493&_table=21500001 6&_item=86',1)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7318,'/scripts/objects/edit.asp?_xid=80000003&_ref=450493&_table=21500001 6&_item=86&_formtab=&process=&step=&elem=',1)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7319,'/scripts/objects/edit.asp?_XID=70000028&_Ref=450493&_table=1001000& _parenturl=2&_item=225000001&_formtab=&process=&st ep=&elem=',5)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7320,'/scripts/iknow.asp?_Ref=1398186089',6)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7321,'/scripts/iMenu.asp?_Ref=1398186089&_XID=40000000&ParentID=' ,10)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7322,'/scripts/objects/MyZBF.asp?_XID=19999900&_Ref=1398186089&_Ref2=',9)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7323,'/scripts/objects/list.asp?_XID=70000028&_Ref=1398186089&_reset=true &_table=1002009&|MenuID=40000000',8)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7324,'/scripts/objects/edit.asp?_XID=70000028&_Ref=1398186089&_table=1002 009&_item=1000001',1)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7325,'/scripts/objects/list.asp?_XID=70000030&_Ref=1398186089&_reset=true &_table=3001062&|MenuID=40000000',6)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7326,'/scripts/objects/edit.asp?_XID=70000030&_Ref=1398186089&_table=3001 062&_item=12',2)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7327,'/scripts/objects/save.asp?',4)
INSERT INTO [stat_hit_pages] ([shp_id],[shp_url],[shp_count]) VALUES
(7328,'/scripts/objects/edit.asp?_XID=70000030&_Ref=1398186089&_table=3001 062&_item=12&_formtab=&process=&step=&elem=',4)

Jul 23 '05 #1
2 4351
Thanks for the DDL and data (although you need to check your syntax for
the hit_id and shp_id columns - I guess you removed an IDENTITY
defintion?). Assuming that you can join the tables on shp_id (there's
no foreign key in your DDL), then this should do what you want:

select
shp.shp_url,
max(sh.hit_date)
from
dbo.stat_hits sh
join dbo.stat_hit_pages shp
on sh.shp_id = shp.shp_id
group by
shp.shp_url

Simon

Jul 23 '05 #2
Thanks simon.

Spot on in everything u said, I feel silly now cos it was so obvious...
I started creating derived tables.

R.

Jul 23 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

11 posts views Thread by Eugenio | last post: by
4 posts views Thread by remote89 | last post: by
4 posts views Thread by Raj | last post: by
reply views Thread by leo001 | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.