Viewing a MDF database in Access 2010


I have a database, Northwind.mdf.

I want to view it in Access 2010 or any other Database Programs like Microsoft SQL Server 2012.

Could someone help me through the steps to do this
Posted On: Monday 31st of December 2012 01:05:43 AM Total Views:  383
View Complete with Replies

RELATED TOPICS OF MYSQL PROGRAMMING LANGUAGE




A Problem to access MySQL in Python

Here are the softwares that I use: MySQL : 3.23.54 Python : 2.3.4 GCC : 3.2.2 MySQL-python-0.9.1-6.i386.rpm when I type in "import _mysql" in a python shell,an error occurs and I have spent a lot of time handling with it but it didn't make any sense.Would anybody help me a hand I will be very grateful :-) Thank you! The message is as follows: [root@Qiuping backup]# python Python 2.3.4 (#1, Mar 30 2006, 14:18:07) [GCC 3.2.2 20030222 (Red Hat Linux 3.2.2-5)] on linux2 >>> import _mysql Traceback (most recent call last): File "", line 1, in ImportError: /usr/local/lib/python2.3/site-packages/_mysql.so: undefined symbol: mysql_set_character_set
VIEWS ON THIS POST

125

Posted on:

Monday 29th October 2012
View Replies!

Looking for an sql programmer

Looking for a sql programmer for a project I am involved with please contact me for more information i will need a phone number to call
VIEWS ON THIS POST

46

Posted on:

Wednesday 7th November 2012
View Replies!

top 6 records?

Hi I have a hockey pool I am running. The teams consist of 7 players, however only the top 6 players of their team counts toward their score. the query I have now calculates all 7, is there a way to only get the top 6
VIEWS ON THIS POST

93

Posted on:

Saturday 10th November 2012
View Replies!

Combining SQL queries

I have two queries that I would like to join. The first query matches a model_id from one table to get the model_name The second query is a count of rows in a model name both work seperately but I would like to have all the info in the same result set. Here are examples of both queries The two tables are stats and manufacturer Code: SELECT DISTINCT stats.manufacturer_id, manufacturer.name as make FROM stats, manufacturer WHERE stats.manufacturer_id = manufacturer.id Code: manufacturer_id make 2 BMW 3 Daihatsu 5 Honda 10 LandRover Code: SELECT stats.manufacturer_id, count(stats.model_id) as model_count FROM stats GROUP By stats.manufacturer_id Code: manufacturer_id model_count 2 7 3 1 5 1 10 1 What I am loking for in the second table is to have the manufacturers name as well or instead of the manufacturer_id as it is in the first table. Cheers, Degs
VIEWS ON THIS POST

117

Posted on:

Saturday 10th November 2012
View Replies!

Dropdown adding to list (text field)

Right. I'm designing a literature request page. There are 4 catergories of literature. Each with seperate items in each. I want users to be able to request quanities of item/s ergo. 1 Red Pack, 9 Green Packs in one request I need this to take up as little space as possible on the page and have concluded a method, currenty, out of my skills. I figure 4 radio buttons indicating the 4 catergories. Each button changes the content of a single dropdown menu coupled with a text box for inputing the quantity required. Once quantity and item has been slected, I want an "Add" button to combine the quantity and item picked and place it into a Text field were the list will be stored and added to until the request is complete. Can anyone help my fumberling brain. Thankyou for you anticipated help peeps.
VIEWS ON THIS POST

154

Posted on:

Saturday 10th November 2012
View Replies!

current remote user

Originally posted by : charles denequolo (charles.denequolo@percepta-crm.com)is there anyway to default a table column to a remote user
VIEWS ON THIS POST

260

Posted on:

Saturday 10th November 2012
View Replies!

DB setup help please.

, I have had some help developing a database for tracking a hockey teams stats. With this help I have been able to enter and track, Win/Loss record as well as individual game scores. ie on october 5th Home team lost to visiting team 4-3. Entering the Team details was also simple for my little brain. For tracking specific seasons. Do I just filter by the season_has_games.Season_id field so if the season has 18 games I just track the first 18 records in that table I am having difficulty figuring out how to input specific game details. Who scored and who assisted, and who got penalties. I am not sure which field I should enter them in. When I play around with it I get no results. The Assist table specifically seems to be a bugger. The DB is setup like this : Code: CREATE TABLE Assists ( Stat_ID INTEGER UNSIGNED NOT NULL AUTO_INCREMENT, Goals_Stat_ID INTEGER UNSIGNED NOT NULL, Games_Game_ID INTEGER UNSIGNED NOT NULL, Players_Player_ID INTEGER UNSIGNED NOT NULL, Time TIME NULL, PRIMARY KEY(Stat_ID), INDEX Assists_FKIndex1(Players_Player_ID), INDEX Assists_FKIndex2(Games_Game_ID), INDEX Assists_FKIndex3(Goals_Stat_ID) ); CREATE TABLE Games ( Game_ID INTEGER UNSIGNED NOT NULL AUTO_INCREMENT, Assists_Stat_ID INTEGER UNSIGNED NOT NULL, PIM_stat_id INTEGER UNSIGNED NOT NULL, Players_Player_ID INTEGER UNSIGNED NOT NULL, Goals_Stat_ID INTEGER UNSIGNED NOT NULL, Teams_Team_ID INTEGER UNSIGNED NOT NULL, Home_team TEXT NULL, Away_team TEXT NULL, GF INTEGER UNSIGNED NULL, GA INTEGER UNSIGNED NULL, Date DATE NULL, Time TIME NULL, PRIMARY KEY(Game_ID), INDEX Games_FKIndex1(Teams_Team_ID), INDEX Games_FKIndex2(Goals_Stat_ID), INDEX Games_FKIndex3(Players_Player_ID), INDEX Games_FKIndex4(PIM_stat_id), INDEX Games_FKIndex5(Assists_Stat_ID) ); CREATE TABLE Goals ( Stat_ID INTEGER UNSIGNED NOT NULL AUTO_INCREMENT, Games_Game_ID INTEGER UNSIGNED NOT NULL, Players_Player_ID INTEGER UNSIGNED NOT NULL, Time TIME NULL, PRIMARY KEY(Stat_ID), INDEX Goals_FKIndex1(Players_Player_ID), INDEX Goals_FKIndex2(Games_Game_ID) ); CREATE TABLE PIM ( stat_id INTEGER UNSIGNED NOT NULL AUTO_INCREMENT, Games_Game_ID INTEGER UNSIGNED NOT NULL, Players_Player_ID INTEGER UNSIGNED NOT NULL, Minutes INTEGER UNSIGNED NULL, Infraction TEXT NULL, PRIMARY KEY(stat_id), INDEX PIM_FKIndex1(Players_Player_ID), INDEX PIM_FKIndex2(Games_Game_ID) ); CREATE TABLE Players ( Player_ID INTEGER UNSIGNED NOT NULL AUTO_INCREMENT, Name TEXT NULL, Number INTEGER UNSIGNED NULL, Email TEXT NULL, Position TEXT NULL, PRIMARY KEY(Player_ID) ); CREATE TABLE Season ( Season_ID INTEGER UNSIGNED NOT NULL AUTO_INCREMENT, PRIMARY KEY(Season_ID) ); CREATE TABLE Season_has_games ( SeasonID INTEGER UNSIGNED NOT NULL AUTO_INCREMENT, GameID INTEGER UNSIGNED NOT NULL, Games_Game_ID INTEGER UNSIGNED NOT NULL, Season_ID INTEGER UNSIGNED NOT NULL, PRIMARY KEY(SeasonID, GameID), INDEX Season_has_games_FKIndex1(Season_ID), INDEX Season_has_games_FKIndex2(Games_Game_ID) ); CREATE TABLE Teams ( Team_ID INTEGER UNSIGNED NOT NULL AUTO_INCREMENT, Team_Name TEXT NULL, PRIMARY KEY(Team_ID) );
VIEWS ON THIS POST

171

Posted on:

Sunday 11th November 2012
View Replies!

Gallery database

averybody I would like to know your opinion how do you design a database that will works as photo gallery, let's count there will be a lot of pictures. Do you save the pictures on the disk or directly on the database Write please your ideas and reasons why exactly that way. One way how I should do it is to make the following tables usertable gallerytable phototable may be others in the the phototable will be info just as text with path to pictures wich will be save it on the disk. But in this case I'm worring to lose for any possible error any picture and also the mantinience or backup is more easy to make it by database then by system for the files. Other way is to save it to the database but if I save all pictures to one table phototable the select queries will take a lot of time. So I'm not sure it is the best. Other idea is to dinamically create a table for any user and on that table save the pictures for respective user. Write please your opinions or ideas. Thank you in advance. GyManual
VIEWS ON THIS POST

172

Posted on:

Sunday 11th November 2012
View Replies!

Creating A List Based on Related Records in Multiple Tables

2 Questions (SQL Server 2k, ASP.NET): #1. I need to retrieve a list of records. For each record I need to know if it has data in related table. The end result should be a list of records & the table names that contain data, multiple rows for each record if needed. (example below) #2.Also - I'd like a list of records and how many tables (a number) have data, one row per record. (example below) I'm guessing it's a going to require a combination of stored procedures that use IF EXISTS statements, inserts into a temporary table and then return the temp. table as the deed result set. I have a table structure like this: tblCust = Main Table pk = Cust_Id tblPrograms tblERDResults tblATCData Those three tables have data about records in tblCust. They may have no related records (to tblCust) or they may have 1 or more related records. Example for Question #1: Cust_id 1 has data in tblPrograms and tblATCData - no data in tblERDResults Example deed return data for Question #1: Code: Row_Id | Cust_Id | Table_Name | Querystring --------------------------------------------- 1 | 1 | tblPrograms | programs 2 | 1 | tblATCData | atcdata I'd use this data for my navigation form. I'd build the navigation links dynamically so that if there was no related info for a particular "section", then the link would not show. If I can return that type of data I could plug it right into my stuff now, as I currently build navigation from a 2 dimensional array containing a list of all tables (the link text) and the querystring value for my viewing page that shows details for a cust_id and "action" (like: view.aspxcust_id=1&type=programs). I would do this my doing an IF EXISTS for each table. If a record exists, I'd UPDATE a temp table with the values of Cust_ID, Table_Name and QueryString. I'd do 14 IF EXISTS, one for each table. The SP would return a recordset that looks like the example above - it would be a SELECT FROM the temporary table I'd create in the SP. Example for Question #2: Cust_id 1 has data in tblPrograms and tblATCData - no data in tblERDResults Cust_id 2 had data in tblATCData only Cust_id 3 has no data in any related table Example deed return data for Question #2: Code: Cust_Id | Table_Count ----------------------- 1 | 2 2 | 1 3 | 0 I'd use that result set to limit my lists to only people that have X number of tables. I have no clue how to do this. That seems very complex to me @ this time. I'm learning very quickly, but my limited SQL knowledge lets me know it's possible, but not how. You can post pseudo-code and I can flesh it out. I'm really looking for "strategies" here, rather than exact code. I appreciate your time, so no need to get really detailed - something like a workflow would be great, specifying the operations in pseudo english/SQL.
VIEWS ON THIS POST

109

Posted on:

Sunday 11th November 2012
View Replies!

Simple question....

I have a web site that uses a mysql database. What is the best/easiest way to update records in the remote database Stupid question I know, but I have to start somewhere!
VIEWS ON THIS POST

126

Posted on:

Sunday 11th November 2012
View Replies!

Sql Between Using Dates

Guys, I really need your help. I am running a query from an ASP page as shown below "SELECT * FROM Appointments WHERE GPID = '" & this_GP & "' AND Date BETWEEN '" & start_date & "' AND '" & End_date & "' " Now it does retrieve the information held between the dates on the database (ACCESS) although my problem is this If I am querying between 31/3/04 and 6/4/04 it retrieves all the records up to the 31rst of the 4th ! ! The data is held on the database in dd/mm/yy format and I have set the Server.LCID on my page to dd/mm/yy. I have even tried changing the ' for # in the sql statement. Please help - its part of my final year project for uni and I am
VIEWS ON THIS POST

140

Posted on:

Sunday 11th November 2012
View Replies!

inserting pictures into a table

Originally posted by : venkat (venkat_karnati@hotmail.com)I want to insert n number of pictures(photos) into a database table field.Next i want to retrieve the same and display on the browser.can some body help me!
VIEWS ON THIS POST

257

Posted on:

Sunday 11th November 2012
View Replies!

SQL: get data in a different way

I have the below table in Oracle 11g database. Product Status Source Destination --------------------------------------- P1, In, Null, US P1, In, India, US P1, In, China, US P1, In, China, US P1, Out, US, India P1, Out, US, India P1, Out, US, India P1, Out, US, India I need to write a SQL Select query to display the information from table in below format. Status(In) Status(Out) ------------------------------------------------ From-China 2 To-China 0 From-India 1 To-India 4 If the source is non-US (India or China) and Status is In, get the counts of India and China from Source Column (From India, From China). If the source is US and Status is Out, get the counts of India and China from Destination Column (To India, To China). I know its easier done by writing a PL SQL code but I dont have rights to create the procedures. I have only SELECT privileges to the database, therefore the need to write a SELECT SQL Query.
VIEWS ON THIS POST

146

Posted on:

Monday 12th November 2012
View Replies!

Complex Query

Hi We are attempting to edit a SQL Qeury within an Excel spreadsheet in order to extract the requried information. We have very limited expierence in writing SQL queries and we have had quite a bit of assistance in writing the correct query. We originally drafted a query which returned us the correct information however the following problem occurred. As you can see below, the incorrect fields relate to the customer ABC on the first and last line. As you can see the columns Scheduled Start 1 and Scheduled Start 2 need to be sorted correctly. Cust1 schstart1 schend1 Cust2 schstart2 schend2 ABC 09/10/2009 09/10/2011 Inte 04/05/2007 18/10/2008 Walkers 06/05/2005 09/04/2006 Pack 15/04/2006 11/05/2007 Smith 11/12/2005 15/03/2006 Brown 11/12/2006 08/09/2007 James 05/06/2006 08/04/2007 Marine 04/06/2007 05/05/2008 RC 10/10/2006 08/06/2007 Wright 07/08/2007 07/06/2008 Associate17/07/2008 18/09/200 ABC 04/11/2005 06/07/2006 The Scheduled Start 1 column should include all the activities which were scheduled in the past and Scheduled Start 2 should include all the activities that have been scheduled for the future. To be more correct, Customer 1, Scheduled Start 1, Scheduled End 1 should all include the past activities and Customer 2, Scheduled Start 2, Scheduled End 2 should include the future activities. We received the following query as a proposed solution: Select a.*, case when a.scheduledstart = b.scheduledstart then '' else b.partyidname end, case when a.scheduledstart = b.scheduledstart then '' else b.scheduledstart end, case when a.scheduledstart = b.scheduledstart then '' else b.scheduledend end FROM ( SELECT equipment.name , equipment.new_modelno, equipment.new_serialno , equipment.new_type , equipment.new_make, equipment.new_mast, equipment.new_capacity, activitypartycustomer.partyidname, serviceappointment.scheduledstart, serviceappointment.scheduledend FROM FilteredEquipment AS equipment INNER JOIN FilteredActivityParty AS activityparty ON equipment.equipmentid = partyid INNER JOIN FilteredServiceAppointment AS serviceappointment ON serviceappointment.activityid = activityparty.activityid INNER JOIN FilteredActivityParty AS activitypartycustomer ON serviceappointment.activityid = activitypartycustomer.activityid AND activitypartycustomer.participationtypemask = 11 WHERE (serviceappointment.statecode = 0) and serviceappointment.scheduledstart = (select max(serviceappointment.scheduledstart) FROM FilteredEquipment AS e INNER JOIN FilteredActivityParty AS activityparty ON e.equipmentid = partyid INNER JOIN FilteredServiceAppointment AS serviceappointment ON serviceappointment.activityid = activityparty.activityid INNER JOIN FilteredActivityParty AS activitypartycustomer ON serviceappointment.activityid = activitypartycustomer.activityid AND activitypartycustomer.participationtypemask = 11 where e.name = equipment.name and e.new_modelno = equipment.new_modelno and e.new_serialno = equipment.new_serialno and e.new_type = equipment.new_type and e.new_make = equipment.new_make and e.new_mast = equipment.new_mast and e.new_capacity = equipment.new_capacity ) ) a JOIN ( SELECT equipment.name , equipment.new_modelno, equipment.new_serialno , equipment.new_type , equipment.new_make, equipment.new_mast, equipment.new_capacity, activitypartycustomer.partyidname, serviceappointment.scheduledstart, serviceappointment.scheduledend FROM FilteredEquipment AS equipment INNER JOIN FilteredActivityParty AS activityparty ON equipment.equipmentid = partyid INNER JOIN FilteredServiceAppointment AS serviceappointment ON serviceappointment.activityid = activityparty.activityid INNER JOIN FilteredActivityParty AS activitypartycustomer ON serviceappointment.activityid = activitypartycustomer.activityid AND activitypartycustomer.participationtypemask = 11 WHERE (serviceappointment.statecode = 0) and serviceappointment.scheduledstart = (select min(serviceappointment.scheduledstart) FROM FilteredEquipment AS e INNER JOIN FilteredActivityParty AS activityparty ON e.equipmentid = partyid INNER JOIN FilteredServiceAppointment AS serviceappointment ON serviceappointment.activityid = activityparty.activityid INNER JOIN FilteredActivityParty AS activitypartycustomer ON serviceappointment.activityid = activitypartycustomer.activityid AND activitypartycustomer.participationtypemask = 11 where e.name = equipment.name and e.new_modelno = equipment.new_modelno and e.new_serialno = equipment.new_serialno and e.new_type = equipment.new_type and e.new_make = equipment.new_make and e.new_mast = equipment.new_mast and e.new_capacity = equipment.new_capacity ) ) b on a.name = b.name and a.new_modelno = b.new_modelno and a.new_serialno = b.new_serialno and a.new_type = b.new_type and a.new_make = b.new_make and a.new_mast = b.new_mast and a.new_capacity = b.new_capacity ORDER BY equipment.name When we tested this query we received an error: Could not add the table '(' I did not realize that such a complex query would be required and I am unsure where to make the adjustment.
VIEWS ON THIS POST

130

Posted on:

Monday 12th November 2012
View Replies!

Updating help

hEYA all, Im doing an asp page which can run an update command. Now im getting the values from the pervious page which are fine- but i want to update that record in ms access using update- but i keep getting this error Error Type: Microsoft OLE DB Provider for ODBC Drivers (0x8007000E) [Microsoft][ODBC Microsoft Access Driver] Too many fields defined. I cant seem to find out a way around this- as i need all the fields updated. Im not to concerned about creating a loop- but i have an array- which stores the inforamtion of each field please any suggestions or code heres my update code Code: sub UpdateCmd( ) '========================================================================================= SET objRs = SERVER.createObject( "ADODB.recordSet" ) dim sqlStatment sqlStatment = "UPDATE Members SET " 'sqlStatment = sqlStatment & "( " sqlStatment = sqlStatment & "[Managing Director] = '"&FieldsArray(1)&"', [Title] = '"&FieldsArray(2)&"', " sqlStatment = sqlStatment & "[Buying Group Member] = '"&FieldsArray(3)&"',[M D Sal] = '"&FieldsArray(4)&"', " sqlStatment = sqlStatment & "[Rebate Contact] = '"&FieldsArray(5)&"', [Rebate Title] = '"&FieldsArray(6)&"', " sqlStatment = sqlStatment & "[Rebate Sal]='"&FieldsArray(7)&"', [Replied]='"&FieldsArray(8)&"', " sqlStatment = sqlStatment & "[Member Name]='"&FieldsArray(9)&"', [S/Holder2]='"&FieldsArray(10)&"', " sqlStatment = sqlStatment & "[S/Holder]='"&FieldsArray(11)&"', [ALPHA TYPE]='"&FieldsArray(12)&"', " sqlStatment = sqlStatment & "[Member Type]='"&FieldsArray(13)&"', [Short Name]='"&FieldsArray(14)&"', " sqlStatment = sqlStatment & "[Address_1]='"&FieldsArray(15)&"', [Address_2]='"&FieldsArray(16)&"', " sqlStatment = sqlStatment & "[Address_3]='"&FieldsArray(17)&"', [Address_4]='"&FieldsArray(18)&"', " sqlStatment = sqlStatment & "[Postcode]='"&FieldsArray(19)&"', [Area]='"&FieldsArray(20)&"', " sqlStatment = sqlStatment & "[Area Code]='"&FieldsArray(21)&"', [Buying Centers]='"&FieldsArray(22)&"', " sqlStatment = sqlStatment & "[Showrooms]='"&FieldsArray(23)&"', [Bathroom]='"&FieldsArray(24)&"', " sqlStatment = sqlStatment & "[Kitchen]='"&FieldsArray(25)&"', [Heating]='"&FieldsArray(26)&"', " sqlStatment = sqlStatment & "[Security]='"&FieldsArray(27)&"', [ToolHire]='"&FieldsArray(28)&"', " sqlStatment = sqlStatment & "[Brick]='"&FieldsArray(29)&"', [Glass]='"&FieldsArray(30)&"', " sqlStatment = sqlStatment & "[Landscaping]='"&FieldsArray(31)&"', [Decking]='"&FieldsArray(32)&"', " sqlStatment = sqlStatment & "[Others]='"&FieldsArray(33)&"', [Telephone]='"&FieldsArray(34)&"', " sqlStatment = sqlStatment & "[Telephone1]='"&FieldsArray(35)&"', [Fax No]='"&FieldsArray(36)&"', " sqlStatment = sqlStatment & "[Fax No1]='"&FieldsArray(37)&"', [Email]='"&FieldsArray(38)&"', " sqlStatment = sqlStatment & "[MD Tel]='"&FieldsArray(39)&"',[MD Fax]='"&FieldsArray(40)&"', " sqlStatment = sqlStatment & "[FD Contact]='"&FieldsArray(41)&"', [FD Title]='"&FieldsArray(42)&"', " sqlStatment = sqlStatment & "[FD Salutation]='"&FieldsArray(43)&"', [Rebate Tel]='"&FieldsArray(44)&"', " sqlStatment = sqlStatment & "[Rebate Fax]='"&FieldsArray(45)&"', [Rebate Email]='"&FieldsArray(46)&"', " sqlStatment = sqlStatment & "[Accounts Contact]='"&FieldsArray(47)&"', [Accounts Title]='"&FieldsArray(48)&"', " sqlStatment = sqlStatment & "[Accounts Sal]='"&FieldsArray(49)&"', [FD Tel]='"&FieldsArray(50)&"', " sqlStatment = sqlStatment & "[FD Fax]='"&FieldsArray(51)&"', [BT Contact]='"&FieldsArray(52)&"', " sqlStatment = sqlStatment & "[BT Title]='"&FieldsArray(53)&"', [BT Salutation]='"&FieldsArray(54)&"', " sqlStatment = sqlStatment & "[Plumbing & Heating Contact]='"&FieldsArray(55)&"', [Accounts Tel]='"&FieldsArray(56)&"', " sqlStatment = sqlStatment & "[Accounts Fax]='"&FieldsArray(57)&"', [Plumbing & Heating Title]='"&FieldsArray(58)&"', " sqlStatment = sqlStatment & "[Plumbing & Heating Sal]='"&FieldsArray(59)&"', [Hardware & Ele Contact]='"&FieldsArray(60)&"', " sqlStatment = sqlStatment & "[HE Title]='"&FieldsArray(61)&"', [HE Salutation]='"&FieldsArray(62)&"', " sqlStatment = sqlStatment & "[Contact 1]='"&FieldsArray(63)&"', [XML Tel:]='"&FieldsArray(64)&"', " sqlStatment = sqlStatment & "[XML Fax:]='"&FieldsArray(65)&"',[TITLE 1]='"&FieldsArray(66)&"', " sqlStatment = sqlStatment & "[SALUTATION 1]='"&FieldsArray(67)&"', [General Lit 1]='"&FieldsArray(68)&"', " sqlStatment = sqlStatment & "[Contact 2]='"&FieldsArray(69)&"', [TITLE 2]='"&FieldsArray(70)&"', " sqlStatment = sqlStatment & "[B T Tel]='"&FieldsArray(71)&"', [B T Fax]='"&FieldsArray(72)&"', " sqlStatment = sqlStatment & "[Sal 2]='"&FieldsArray(73)&"', [General Lit 2]='"&FieldsArray(74)&"', " sqlStatment = sqlStatment & "[Contact 3]='"&FieldsArray(75)&"', [TITLE 3]='"&FieldsArray(76)&"', " sqlStatment = sqlStatment & "[P & H Tel]='"&FieldsArray(77)&"', [P & H Fax]='"&FieldsArray(78)&"', " sqlStatment = sqlStatment & "[SALUTATION 3]='"&FieldsArray(79)&"', [Email 1]='"&FieldsArray(80)&"', " sqlStatment = sqlStatment & "[B G 1]='"&FieldsArray(81)&"', [C D 1]='"&FieldsArray(82)&"', " sqlStatment = sqlStatment & "[HE Tel]='"&FieldsArray(83)&"', [HE Fax]='"&FieldsArray(84)&"', " sqlStatment = sqlStatment & "[Rebate 1]='"&FieldsArray(85)&"', [Phone 4]='"&FieldsArray(86)&"', " sqlStatment = sqlStatment & "[Fax4]='"&FieldsArray(87)&"', [General Lit 3]='"&FieldsArray(88)&"', " sqlStatment = sqlStatment & "[B G 2]='"&FieldsArray(89)&"', [Email 2]='"&FieldsArray(90)&"', " sqlStatment = sqlStatment & "[C D 2]='"&FieldsArray(91)&"', [Rebate 2]='"&FieldsArray(92)&"', " sqlStatment = sqlStatment & "[B G 3]='"&FieldsArray(93)&"', [C D 3]='"&FieldsArray(94)&"', " sqlStatment = sqlStatment & "[Rebate 3]='"&FieldsArray(95)&"', [Contact 4]='"&FieldsArray(96)&"', " sqlStatment = sqlStatment & "[TITLE 4]='"&FieldsArray(97)&"', [SAL 4]='"&FieldsArray(98)&"', " sqlStatment = sqlStatment & "[B S 1]='"&FieldsArray(99)&"', [Email 3]='"&FieldsArray(100)&"', " sqlStatment = sqlStatment & "[Contact 5]='"&FieldsArray(101)&"', [TITLE 5]='"&FieldsArray(102)&"', " sqlStatment = sqlStatment & "[SAL 5]='"&FieldsArray(103)&"', [General Lit 5]='"&FieldsArray(104)&"', " sqlStatment = sqlStatment & "[Queries]='"&FieldsArray(105)&"', [Website]='"&FieldsArray(106)&"', " sqlStatment = sqlStatment & "[MD Email]='"&FieldsArray(107)&"', [B G 4]='"&FieldsArray(108)&"', " sqlStatment = sqlStatment & "[BS 2]='"&FieldsArray(109)&"', [Email 4]='"&FieldsArray(110)&"', " sqlStatment = sqlStatment & "[C D 4] ='"&FieldsArray(111)&"', [Rebate 4]='"&FieldsArray(112)&"', " sqlStatment = sqlStatment & "[General Lit 4]='"&FieldsArray(113)&"', [FD Email]='"&FieldsArray(114)&"', " sqlStatment = sqlStatment & "[Accounts Email]='"&FieldsArray(115)&"', [Building & Timber Email]='"&FieldsArray(116)&"', " sqlStatment = sqlStatment & "[HE Email]='"&FieldsArray(117)&"', [B G 5]='"&FieldsArray(118)&"', " sqlStatment = sqlStatment & "[Email 5]='"&FieldsArray(119)&"', [BS 3]='"&FieldsArray(120)&"', " sqlStatment = sqlStatment & "[C D 5]='"&FieldsArray(121)&"', [Rebate 5]='"&FieldsArray(122)&"', " sqlStatment = sqlStatment & "[Spot Buy Fax]='"&FieldsArray(123)&"', [Spot Buy Contact]='"&FieldsArray(124)&"', " sqlStatment = sqlStatment & "[Lit]='"&FieldsArray(125)&"', [Spot Buy Email]='"&FieldsArray(126)&"', " sqlStatment = sqlStatment & "[Plumbing & Heating Email]='"&FieldsArray(127)&"', " sqlStatment = sqlStatment & "[XML]='"&FieldsArray(128)&"', [BS 4]='"&FieldsArray(129)&"', " sqlStatment = sqlStatment & "[XML Contact]='"&FieldsArray(130)&"', [XML Title]='"&FieldsArray(131)&"', " sqlStatment = sqlStatment & "[XML Sal]='"&FieldsArray(132)&"', [XML Email]='"&FieldsArray(133)&"', " sqlStatment = sqlStatment & "[Email 6]='"&FieldsArray(134)&"', [B G 6]='"&FieldsArray(135)&"', " sqlStatment = sqlStatment & "[B S 5]='"&FieldsArray(136)&"', [C D 6]='"&FieldsArray(137)&"'," sqlStatment = sqlStatment & "[B S Contact]='"&FieldsArray(138)&"', [B S Title]='"&FieldsArray(139)&"', " sqlStatment = sqlStatment & "[Contact 6]='"&FieldsArray(140)&"', [Title 6]='"&FieldsArray(141)&"', " sqlStatment = sqlStatment & "[Sal 6]='"&FieldsArray(142)&"', [Gen Lit 6]='"&FieldsArray(143)&"', " sqlStatment = sqlStatment & "[Rebate 6]='"&FieldsArray(144)&"', [B S Sal]='"&FieldsArray(145)&"', " sqlStatment = sqlStatment & "[B S 6]='"&FieldsArray(146)&"', [B S Tel]='"&FieldsArray(147)&"', " sqlStatment = sqlStatment & "[B S Fax]='"&FieldsArray(148)&"', [B S Email]='"&FieldsArray(149)&"', " sqlStatment = sqlStatment & "[Member A/C]='"&FieldsArray(150)&"' " 'sqlStatment = sqlStatment & ") " sqlStatment = sqlStatment + "Where [A/C no] = '"& No &"' And [Address_code] = '"& C &"'" 'Response.write(sqlStatment) 'Response.end objRs.OPEN sqlStatment, objConn,1,3 '========================================================================================= end sub
VIEWS ON THIS POST

173

Posted on:

Monday 12th November 2012
View Replies!

Adding set value to field

I have a simple table with two fields: Name and Money. I have a list of 20 people I want to add $50 each to whatever amount of money they have. How do I go about doing that I tried Update MyTable SET Money = (Money + 50) but the update set all values to 0. I'm sure this is a very newbie question coming from a noob, but I need help.
VIEWS ON THIS POST

150

Posted on:

Monday 12th November 2012
View Replies!

Moving data to new table then deleting from old

I want to move a record from one table to another using a button on an Access form page. Having moved the record I wish to delete the record from the first table. Can I use a nested query Delete From where (Insert into query) Or is there a better way to do this
VIEWS ON THIS POST

140

Posted on:

Monday 12th November 2012
View Replies!

How to increment value in asp

Hi Everyone, I have created a field which is in access database so user cant see on web page so whenever user submit their form I want to increment that field value by one .. NOTE: This is field is not primary key and its data type is "text" Pls help me asap....
VIEWS ON THIS POST

135

Posted on:

Monday 19th November 2012
View Replies!

ADODB.Parameter error '800a0d5d' Error? Please help

Ooops wrong place...please see it in the ASP development section.
VIEWS ON THIS POST

183

Posted on:

Monday 19th November 2012
View Replies!

Too few parameters. Expected 1. What does it mean?

I have a Access database on a tomcat server. Normal database operations works just perfect, so I don't think there is anything wrong with the connection. My problem is two sql querys that both give me the same error: Too few parameters. Expected 1. When i run them in Access alone, I get what I want... What is the problem SELECT Dep.DeptName, Dep.Owes, COUNT(Car.OutTo) AS CarsOut, SUM(Car.Cost*((Today.Date-Car.OutOn)+1)) AS Liability, Dep.Owes+Liability AS Total FROM Today, (Dep INNER JOIN Emp ON Dep.DeptName=Emp.DeptName) INNER JOIN Car ON Emp.Name=Car.OutTo GROUP BY Dep.DeptName, Dep.Owes HAVING ((Dep.DeptName)"It") SELECT Car.CarNr, Car.Make FROM (CanTake INNER JOIN Emp ON CanTake.Name = Emp.Name) INNER JOIN Car ON CanTake.Make = Car.Make WHERE (((Car.Make)=[CanTake].[Make]) AND ((CanTake.Name)=[Emp].[Name]) AND ((Car.OutTo) Is Null) AND ((Emp.Name)=[Jenny])); Just an other problem: When running the last query in access, why do i have to type in the Emp.Name in a "popup" form asking for parameter value Doesn't Emp.Name = Jenny do the trick When i remove that last criteria i get the whole list, so it got to do something right..
VIEWS ON THIS POST

146

Posted on:

Monday 19th November 2012
View Replies!

query date field

I have a table that is a log of user names with time and date fields of when they login. I'm wanting to display the first date and last date they loged in on all users in a table view. How would I SELECT DISTINCT Table2.fldUserName. and the fldDate
VIEWS ON THIS POST

138

Posted on:

Tuesday 20th November 2012
View Replies!

Date Format Problems

Originally posted by : David (davo__@hotmail.com)I have been having various problems with formating dates to the australian format (dd/mm/yyyy). I am using ACCESS, the query I am sending to the database is:UPDATE tailback SET tailback_status='In Progress', tailback_processdate=#01/10/2001#, tailback_processtime=#15:23:13#, tailback_processps='dr' WHERE tailback_refnumber=12313 In the field tailback_processdate (in table "tailback") I have set the custom format to dd/mm/yyyy.However in the database the field tailback_processdate is displayed as 10/01/2001.Why is this! The custom format should overide any regional settings, shouldn't it!
VIEWS ON THIS POST

136

Posted on:

Tuesday 20th November 2012
View Replies!

Can I create a single query for this?

Hi all (ASP -> MySQL FYI) Tables (simplified) ***newsarticles id (primary key) ***newsphotos id (primary key) ***newsarticlephotos id (primary key) newsarticleid (foreign key - newsarticles) newsphotoid(foreign key - newsphotos) Hopefully the above makes sense, there are tables of news articles and tables of photos, then a table linking photos to articles. I have a basic grasp of SQL, but in my attempts to further my understanding I was wondering if it was possible to retrieve my data using a single statement. Currently, to retrieve details of a news article (1) Retrieve required row from newsarticles Code: SELECT id FROM newsarticles WHERE id = 1 (2) Retrieve required rows from newsphotos using a nested select statement. Code: SELECT newsPhotoId FROM newsPhotos WHERE newsPhotoId IN (SELECT newsPhotoId FROM newsArticlePhotos WHERE newsArticleId = 1) My question: Is this a sensible approach to the situation, or is there a far more elegant way of implementing this Should I be using joins on the tables etc Many
VIEWS ON THIS POST

238

Posted on:

Tuesday 20th November 2012
View Replies!

Insert and select query

i want to insert records with the selcted values frm another eg table1: name, add, country, company, products, rates INSERT INTO TABLE1(name, add,country, company, products, rates) values(session("name"),session("add"),,session("co untry"),session("company")) SELECT products, rates from table1 where name='" & txtname.text & "' and country='" & txtcountry.text & "'" i want to insert values for name1 , add1, country1, company1 stored in session with product, rates of name2, country2. transferring product, rates values from name1 to name2
VIEWS ON THIS POST

143

Posted on:

Tuesday 20th November 2012
View Replies!

SQL initialization problem

OK - I've gone out to w3schools.com and took their crash courses on sql and ado, and I'm trying to mend my ways and stop snaching sql code and trying to make it work. At w3schools they consistantly use a connection routine like this: [highlight="ASP"]set conn=Server.CreateObject("ADODB.Connection") conn.Provider="Microsoft.Jet.OLEDB.4.0" conn.Open "MyDatabaseFile.mdb" set rs=Server.CreateObject("ADODB.Recordset") rs.open "SELECT * FROM MyTable WHERE field = '" & SearchString & "'",conn[/highlight] Here's how it looks in my app: [highlight="ASP"]If Request.Form("btnSave") = "Save" Then set conn=Server.CreateObject("ADODB.Connection") conn.Provider="Microsoft.Jet.OLEDB.4.0" conn.Open "../fpdb/counselors_expertise.mdb" set rs=Server.CreateObject("ADODB.Recordset") rs.open "SELECT * FROM email WHERE Name = '" & Request.Form("selCounselor") & "'",conn If rs.eof and rs.bof then sql = "INSERT INTO email(Name,Email) VALUES('" & Trim(Request.Form("selCounselor")) & "','" & Trim(Request.Form("selEmail")) & "')" on error resume next conn.Execute sql,recaffected if err0 then Response.Write("No update permissions!") else Response.Write("" & recaffected & " record added") end if conn.close End If End If[/highlight] When it runs, I get an error: [highlight="Error"]Error Type: Microsoft JET Database Engine (0x80004005) 'C:\WINDOWS\fpdb\counselors_expertise.mdb' is not a valid path. Make sure that the path name is spelled correctly and that you are connected to the server on which the file resides.[/highlight] The code resides in c:\inetpub\wwwroot\sbdc\intranet\add_expertise.asp and the database is in c:\inetpub\wwwroot\sbdc\fpdb The path from the app to the database should be as above: ../fpdb/counselors_expertise.mdb and that works for several other queries in this app. There's obviously something w3schools didn't tell me... joe
VIEWS ON THIS POST

169

Posted on:

Tuesday 20th November 2012
View Replies!

Joining tables

hi i have a doubt in joining three tables..... the three table structures are as follows 1) CREATE TABLE APPLICATION ( ID NUMBER NOT NULL, NAME VARCHAR2(50 BYTE) NOT NULL, CODE VARCHAR2(50 BYTE) NOT NULL, STATUS VARCHAR2(9 BYTE) NOT NULL, CLIENT_ID NUMBER NOT NULL, TYPE_ID NUMBER NOT NULL, REGISTRATION_RULE VARCHAR2(11 BYTE) NOT NULL, PASSWORD VARCHAR2(50 BYTE) NOT NULL, VALIDITY_PERIOD_ID NUMBER NOT NULL, TERMS VARCHAR2(4000 BYTE), DESCRIPTION VARCHAR2(1000 BYTE), URL VARCHAR2(200 BYTE), ENTRY_DATE DATE DEFAULT SYSDATE NOT NULL, ENTRY_USER_ID NUMBER NOT NULL, MODIFICATION_DATE DATE DEFAULT SYSDATE NOT NULL, MODIFICATION_USER_ID NUMBER NOT NULL ) 2) CREATE TABLE SUBSCRIBER ( ID NUMBER NOT NULL, USER_ID NUMBER NOT NULL, OPERATOR_SUBSCRIBER_ID VARCHAR2(50 BYTE), MSISDN VARCHAR2(50 BYTE) NOT NULL, STATUS VARCHAR2(15 BYTE) NOT NULL, NAME VARCHAR2(50 BYTE), SURNAME VARCHAR2(50 BYTE), DEVICE_ID NUMBER, ADDRESS_ID NUMBER, ENTRY_DATE DATE DEFAULT SYSDATE NOT NULL, ENTRY_USER_ID NUMBER NOT NULL, MODIFICATION_DATE DATE DEFAULT SYSDATE NOT NULL, MODIFICATION_USER_ID NUMBER NOT NULL, IMSI VARCHAR2(30 BYTE) ) 3) CREATE TABLE SUBSCRIBER_APPLICATION ( SUBSCRIBER_ID NUMBER NOT NULL, APPLICATION_ID NUMBER NOT NULL, MSID_ID NUMBER NOT NULL, CODEWORD_CHECK_ENABLED CHAR(1 BYTE) NOT NULL, VALIDITY_PERIOD_ID NUMBER NOT NULL, EXPIRE_DATE DATE, STATUS VARCHAR2(50 BYTE) DEFAULT 'ACTIVE' ) subscriber_id in table 3, id in table 2, id in table application are the same am interested in the name field in table 1 (application) the subscriber table will have single entry for each MSISDN which is also identified by ID column in the same table the subscriber_application table is having the info about the subscriber_id (id) i.e the number of application registered for. Now i want the query to give the result as name from application table, count (subscriber_id) from subscriber_application table between some Entry_date values (available in subscriber table) and grouped by name (i.e no of customers for each application between dates) i tried select a.application_id, count(a.subscriber_id) from prov.subscriber_application a group by a.application_id am getting the result correctly but here i want to enhance it with name instead of id and allowing the user to see for between dates example scenario: application table contains all the available application names refered by id subscriber table will have single entry for each mobile number (irrespective of how many application he has registered for) subscriber_application table will be having one entry for one application registration for each mobile number suppose am registering for 5 application then there will be 5 entries in the subscriber_application table . mobile number is identified by subscriber_id can any one hekp me out. with
VIEWS ON THIS POST

129

Posted on:

Tuesday 20th November 2012
View Replies!

create a DTS for two tables to combine

hi .. i am new to DTS's can someone tell me what i need to do in order to create a DTS so that i will be able to combine two tables together. I know i have to create a connection and i did that i just dont know what i need to choose to get the two tables..
VIEWS ON THIS POST

134

Posted on:

Tuesday 20th November 2012
View Replies!

How to open this database (urgent)

I am an Indian student working in Germany as a programmer. First time am dealing with SQL Server databases. And also first time posting a message in this SQL Team forums. Now I got a backup copy of SQL server database. I have to open this database and draw a data model diagram for that databse. but I don't have SQL server installed on my computer. what should I install on my computer to open this database. - This is a .bak file. 1. - How to open this backup database and look into the data I heared from some friends that it is possible to draw a data model isgram automatically with MS Visio. any one knows how to do it or any other way to do it 2. How to draw a data model diagram automatically for this SQL server database Kiran Karnati.
VIEWS ON THIS POST

173

Posted on:

Tuesday 20th November 2012
View Replies!

shorter query code

i trying to do this : id = integer field status=Yes/no (checkbox) field if Id 1-to-100's Status = Yes then Reset all Status = No Code: strSQL="Update RandQuestions SET Status = "& FALSE &" WHERE ID = "& 1 &" AND (studentID = '" & Session("StudID") & "') AND (Paper ='"& Session("Paper") &"' AND Status = TRUE)" objConn.Execute (strSQL)
VIEWS ON THIS POST

97

Posted on:

Tuesday 20th November 2012
View Replies!

Can this be done without using "NOT IN"

Hi , I have two tables with the same structure. I want to retrieve the records from one table which are not in the other table. I am achieving it through the following query. Code: SELECT ID, Name FROM tblShop1 WHERE Name NOT IN(SELECT Name FROM tblShop2) Is there some other way to do this..like using LEFT OUTER JOIN or so...
VIEWS ON THIS POST

120

Posted on:

Tuesday 20th November 2012
View Replies!

FoxPro SQL Problem

Can someone help me with the SET NEAR ON command. The following code works, but it will not return a record that has "Fred Flinstone" in the field, "task". The end result tells me that there are no records found. The index expression I used to create newkey tag is ALLTRIM(task)+DTOC(compdate) Here's the code for the Find button: SET NEAR ON IF m.find = 1 AND NOT EMPTY(m.findthis) SELECT * ; FROM bashproc ; WHERE bashproc.task = ALLTRIM(m.findthis) ; INTO CURSOR pickone IF _tally > 0 && I found at least one record that matched...... SELECT pickone BROWSE m.f1=pickone.task m.f2=pickone.compdate SELECT bashproc SET ORDER TO TAG newkey IF SEEK(ALLTRIM(pickone.task)+DTOC(pickone.compdate), "bashproc") SELECT bashproc SCATTER MEMVAR MEMO SET ORDER TO CLEAR READ RETURN ELSE WAIT WINDOW "Seek Into BASHProc Failed" ENDIF ELSE WAIT WINDOW "No Matching Record(s) found" ENDIF ELSE WAIT WINDOW "Search Canceled!" NOWAIT ENDIF CLEAR READ
VIEWS ON THIS POST

118

Posted on:

Tuesday 20th November 2012
View Replies!

Altering Column Names

I have table Employee. It contains the columns : name, phone, addr1 I would like to change the addr1 column to Address. How can I do this
VIEWS ON THIS POST

145

Posted on:

Tuesday 20th November 2012
View Replies!

SQL SELECT Query

Hi , I apologise if this is the wrong place to post this, but I couldn't see a forum for Oracle and I think this is a general SQL question!! I am currently building an application which will keep track of employees hours worked and calculate their pay. As part of this application the finance department thought it would be a good idea to be able to see how many days each employee has had off sick in the last year. (Big Brother is watching you!!!!) I am able to retrieve the amount of days that each employee has had sick by counting the amount of timesheet entries (each one represents one day!!) which have an absence of reason of S (sick). This is about the limit of my SQL knowledge unfortunately, but the following works fine: Code: SELECT NAME_LOOKUP.EMPLOYEE_ID, NAME_LOOKUP.EMPLOYEE_NAME, count(TIMESHEET.ABSENCE_REASON) AS "SICK" FROM NAME_LOOKUP, TIMESHEET WHERE (TIMESHEET.EMPLOYEE_ID = NAME_LOOKUP.EMPLOYEE_ID) AND (trim(TIMESHEET.ABSENCE_REASON) = 'S') and (trunc(TIMESHEET.WORKING_DATE) >= '01-Apr-2006') and (trunc(TIMESHEET.WORKING_DATE) < '01-Apr-2007') group by NAME_LOOKUP.EMPLOYEE_ID, NAME_LOOKUP.EMPLOYEE_NAME, TIMESHEET.ABSENCE_REASON In the application the dates are automatically generated depending on the current year, I have just hard-coded them in this example!! My question is, the above query returns the total amount of sick days for each employee who has had days off sick, can anybody tell me if it is possible to return the employee's name and a total of zero if they have not had any time off sick Sorry if this is a silly question or is not clear enough.
VIEWS ON THIS POST

110

Posted on:

Tuesday 20th November 2012
View Replies!

queries in asp

hello, i'm a new forum user. I want to ask something related to sql stament. like this.. strmonth=request("Bul") strunit=request("Unit") sql="select * from jualan where Bul='" & strmonth & "' and Unit ='" & strUnit & "' order by InvJ " what wrong with this statement. I want to display a list of jualan where match the two criteria, month and unit. can somebody help me with this.tq
VIEWS ON THIS POST

108

Posted on:

Tuesday 20th November 2012
View Replies!

sql access

hello i want to get access to my sql server. What kind of software to use Aff dan http://www.swiss-escorts.com
VIEWS ON THIS POST

127

Posted on:

Tuesday 20th November 2012
View Replies!

Before i get ahead of myself.. database design critque plllleeassee...

Scope of project:create simple browse down (+search) engine/site for various telecom and networking parts arranged by manufactuer then brand then part to show a list of vendors that carry said product arranged by price and reorderable.. In reading other posts, figure it might not be a bad idea to run down my little structure and some sample data.. ttProducts prodID (autonumber) item (m7310, Trunk Module) model (NT8B75, VB-44210) manuID (from ttManu, to identify manufacturer) catID (from ttCat, to identify category) photo (for addition of url to pic) ttManu manuID (autonumber) manu (Nortel Networks - Norstar) ttCategory catID (auto) category (category part may fit in, Phones, Cards, Voicemail..) ttVendors vendorID (auto) company address1 address2 city, state, zipcode, phone, phone800, fax, email, website, login, password, descrip, added_on, active ttInventory the table to tie em all together invID (auto) prodID (from ttProducts) vendorID (from ttVendors) newprice (price for part new, if any) refurbprice (price for part used, if any) oosprice (price for part out of service, if any) warranty venddescrip (short description from vendor for said part) ttFeedback feedID (auto) vendorID (identifies who feedback was left for) feedback (comments) dateleft leftby -------------------- whole point of project is simple easy browse down to part, then see list of vendors. User selects Maufacturer from home page, is presented with a list of categories for parts matching said manu. User selects cateogry and is presented with list of all parts matching manu and category. User clicks part and is presented with list of vendors, 1 to 3 prices (whatever vendor filled in for part when adding it to browse) plus shot descrip from vendor if they left one, if not, filled in with vendor main descrip, if none, call blank. List is presented with lowest NEW price first and may be reordered by lowest Refurb price and again by lowest OOS Price, but all data displayed remains the same. user may alternativly use a single serach text box to query db and pull anything that matches what they typed in in price order from the inventory table.. Will that data seem at first glance to fit together ok
VIEWS ON THIS POST

132

Posted on:

Tuesday 20th November 2012
View Replies!

MSSQL: Doing a MINUS

Dear all, How can I do a MINUS operation in MSSQL In fact the purpose is doing paging in a ASP.NET webpage, for example I want to display 10 records in a page, so the second page will be (select top 20 * in table1 where ...) MINUS (select top 10 * in table1 where ...) Anyone can suggest how to do a MINUS Or are thereany better methods to select a certain range of records in a recordset
VIEWS ON THIS POST

119

Posted on:

Tuesday 20th November 2012
View Replies!

Creating an EXCEL template to load data into SQL Database

Originally posted by : Kaarthik (kaarthik@singnet.com.sg)Hi I was wondering whether its possible to create an xls template in excel and allow users to upload that template into the web server and that will automatically fill up the SQL database accordingly..i hope you can help me in this..or is there any other solution...kaarthik
VIEWS ON THIS POST

120

Posted on:

Tuesday 20th November 2012
View Replies!

help ! ! ! sql problem ! ! !

Originally posted by : kiran (kiran@pl.jaring.my)What is wrong with the following code Your Record has been recorded
VIEWS ON THIS POST

122

Posted on:

Tuesday 20th November 2012
View Replies!

The operator of "between and "

hi, when i execute this qry ..., my result is not accurate. My result are: month year NoR GotR --------------------------------------- 11 07 0 24 12 07 12 12 1/ 08 222 219 The qry: select distinct mid(ReceiptDate,1,2) as month,right(ReceiptDate,2) as year,sum(case when rfqtype = 'No R' then 1 else 0 end) as NoR,sum(case when rfqtype = 'Got R' then 1 else 0 end) as GOTR from rfq_graph where ReceiptDate between '1/ % / 2008' and '3/ % / 2008' group by month,year order by year,month; Question: my datatype for ReceiptDate is VarChar. Why the result of 2007 also being display although i did not select it any help, i truly appreciated it ....
VIEWS ON THIS POST

150

Posted on:

Tuesday 20th November 2012
View Replies!

id-key, access

Originally posted by : chill (marek.soans@novobcs.ee)ok - heres the idea:Access database, HTML webcard, URLI want to make some kind on key (id) that is unique and that goes with URL like thishttp://webcard.com/picupid=Y7ks3872638mERE3But with access databaseI could do it like thishttp://webcard.com/picupid=01http://webcard.com/picupid=02 http://webcard.com/picupid=02 ...but it's too easy to hack Any hints - do I have to make some kind of Function that uses random... Thank U- chill -
VIEWS ON THIS POST

131

Posted on:

Tuesday 20th November 2012
View Replies!

General question

I need the third answer to the question. The code sql statement update to add new interested customer for Mark Toby. Assuming they are stored in a collection that you can access with the command "For each NewCust.Name." Artist.Name Artist.Nationality Transaction.purchaseDate Transaction.salesPrice... Customer.Name ustomer.Phone.Areacode Customer.Phone.Localnumber customer.Name... (the ellipses...refer to structures that can repeat)
VIEWS ON THIS POST

110

Posted on:

Monday 26th November 2012
View Replies!

Validating Phone Numbers

I have a phone field I need to validate. I need to remove periods, commas, dashes from the phone numbers. Does anyone know how to write this query
VIEWS ON THIS POST

145

Posted on:

Monday 26th November 2012
View Replies!

Search Problem

I'm producing a search that when a section is chosen from a drop down menu the search only searches the selected section. The problem is the code below searches others sections as well as the selected one. strSQL = "SELECT * FROM qry_Policies WHERE SectionID = " & request.Form("section") & " AND title like'" & txtSearch & "' or keywords like '%" & txtSearch & "' OR keywords like '" & txtSearch & "%' OR keywords like '%" & txtSearch & "%' AND '" & txtSearch & "' OR title like '%" & txtSearch & "' OR title like '" & txtSearch & "%' OR title like '%" & txtSearch & "%' ORDER by title"
VIEWS ON THIS POST

106

Posted on:

Monday 26th November 2012
View Replies!

How bad it is to insert a column into existing table?

I have to design a DB , I have same items in different languages. I want to store one record for each item with columns for every language like this : EN for English, FR for French ,SP for Spanish etc. If we are going to add a new language like Italian for example,I'll need to insert new column into my table -IT. How bad is it to insert a new column into an existing table with a lot of data How it influence on the table structure and it's performance
VIEWS ON THIS POST

135

Posted on:

Monday 26th November 2012
View Replies!

SQL Subqueries

Does anyone know of any good tutorial sites or have any sql subquery examples I've heard people refer to this type of a query as "in-line SQL". Is this correct I have a good understanding of basic SQL queries, I just want to expand my knowledge.
VIEWS ON THIS POST

104

Posted on:

Monday 26th November 2012
View Replies!

Expected end of statement

Can anyone help please. Using VBScript: Code: strSQL = "SELECT CustomerID, CustomerName FROM CustomerDetails "&_ "WHERE CustomerID=Session("asp_login_unique_id"); " Error: Microsoft VBScript compilation (0x800A0401) Expected end of statement /SMart/html/advert.asp, line 118, column 27 "WHERE CustomerID=Session("asp_login_unique_id"); " --------------------------^ Line 118, col 27 is immediately after the open bracket in the Where statement and before "asp Please help,
VIEWS ON THIS POST

126

Posted on:

Monday 26th November 2012
View Replies!

ADOxxx or SQLxxx objects?

Originally posted by : DevPro (mbsoftware@libero.it)I currently have a web site running on NT4 and linked to an Access database. If I want to upgrade to SQLServer I just need to update the connection string in one file.Now I want to rewrite my site with ASP.NET, but I have a big question. I know that I can use ADOConnection, ADOCommand, ADODataSetCommand etc. to use any OLEDB Provider to be able to change the connection string and pass from Access to SQLServer when I want.But if I want to take the maximum advantage of SQL Server I should use SQLConnection, SQLxxx ect, right This is quite difficult, because I still want to be able the Access database, so, do I need to write different code for ADOxxx and SQLxxx objects for Access and SQLServerA second question: put that I choose to use the ADOxxx objects for both Access and SQLServer, even if I'm not sure this is the best situation. How can I know if the connection string points to an Access or SQLserver database, in order to use a stored procedure instead of a simple queryI hope I've been clear enough in explaining myself...Thank you so much for the help you would like to offer.
VIEWS ON THIS POST

122

Posted on:

Monday 26th November 2012
View Replies!