Home | Advertising Info1 USERS CURRENTLY ONLINE   
PowerASP
   Site Search Contact Us Wednesday, May 15, 2024  

  Active InfoActive Info  Display List of Info MembersMemberlist  Search The InfoSearch  HelpHelp
  RegisterRegister  LoginLogin
Classic ASP - Database Issues
 PowerASP Code Help Area : Classic ASP - Database Issues
Subject Info: table with broken name A d d  -  P o s tAdd P o s t
Author
Message << Prev Info | Next Info >>
holdenfj55
Newbie
Newbie


Joined: December/28/2005
Online Status: Offline
Info: 1
Added: December/28/2005 at 4:07am | IP Logged Quote holdenfj55

HI,

Trying to connect to a Point of Sale Retail system for our company, so to create a couple of reports.

The problem is that the table within the database we want to access uses a name of "POS HISTORY HEADER". As a result, there is a syntex error in the from clause.  How do I overcome this issue? Theres Not a hope of editing any names in the table.

Below is what I have to start with:

<%

FileName="Connection_ado_conn_string.htm"

 ' Type="ADO" ' DesigntimeType="ADO"

' HTTP="false" ' Catalog="" ' Schema="" Dim MM_classifieds_STRING 'MM_classifieds_STRING = "Driver={Microsoft Access Driver (*.mdb)};DBQ=f:\data2000R.mdb"

MM_classifieds_STRING = "Driver={Microsoft Access Driver (*.mdb)};DBQ=f:\data2000R.mdb"

'MM_classifieds_STRING = "dsn=classifieds411;"

%>

<%

set rsResult = Server.CreateObject("ADODB.Recordset") rsResult.ActiveConnection = MM_classifieds_STRING rsResult.Source = "SELECT * FROM POS HISTORY HEADER"

rsResult.CursorType = 0

rsResult.CursorLocation = 2 rsResult.LockType = 3

rsResult.Open()

rsResult_numRows = 0

%>

Back to Top View holdenfj55's Profile Search for other info by holdenfj55
 
cwilliams
Admin Group
Admin Group
Avatar

Joined: April/26/2004
Location: United States
Online Status: Offline
Info: 137
Added: December/28/2005 at 8:18pm | IP Logged Quote cwilliams

bad database design whoever did that...

basically in your sql statement POS HISTORY HEADER has to be surrounded by something... brackets maybe [] ? quotes '' ?

I forget but something like that

Doing a google search on sql statements and table names with spaces should bring up something on it...

or any good SQL book/documentation



__________________


Chris Williams
http://www.PowerASP.com
Back to Top View cwilliams's Profile Search for other info by cwilliams
 

If you wish to make a comment to this info you must first login
If you are not already registered you must first register

  A d d  -  P o s tAdd P o s t
Printable version Printable version

Info Jump
You cannot add new info in this area
You cannot add to info in this area
You cannot delete your info in this area
You cannot edit your info in this area
You cannot create polls in this area
You cannot vote in polls in this area

   Active Server Pages Rule The World
Contact Us  
All artwork, design & content contained in this site are Copyright © 1998 - 2024 PowerASP.com and Christopher J. Williams
Banner ads ,other site logos, etc are copyright of their respective companies.
STATS Unless otherwise noted - All Rights Reserved.

Active Server Pages ASP control controls class classes module script Scripts applet CJWSoft ASPProtect ASPBanner ASPClassifieds www.aspprotect.com, www.cjwsoft.com,www.aspclassifieds.com,www.aspphotogallery.com