Solved

SQL Statements for excel sheets via ADO

Posted on 2003-11-04
1
817 Views
Last Modified: 2007-12-19
Hi all,
I have a problem in accessing the excel sheets via ADO using SQL command. If I access the excel sheets using a single word field (e.g. PartNo), I can retrieve the data without problem but if I try to retrieve data using a two word field (e.g. First Name), I will have an exception. Does anyone have any idea how to solve this problem.

select * from pract$ where PartNo is 'A1234'   // this can work

select * from pract$ where First Name is 'John'   // this cannot work

A billion thanks
Rice Cake.

0
Comment
Question by:antioch_75
1 Comment
 
LVL 27

Accepted Solution

by:
kretzschmar earned 125 total points
ID: 9684871
usual you do doublequote the field

select * from pract$ where "First Name" is 'John'  

but it could only be that you must use brackets

select * from pract$ where [First Name] is 'John'  

must test mySelf First

meikl ;-)
0

Featured Post

Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Objective: - This article will help user in how to convert their numeric value become words. How to use 1. You can copy this code in your Unit as function 2. than you can perform your function by type this code The Code   (CODE) The Im…
Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
This tutorial gives a high-level tour of the interface of Marketo (a marketing automation tool to help businesses track and engage prospective customers and drive them to purchase). You will see the main areas including Marketing Activities, Design …
Established in 1997, Technology Architects has become one of the most reputable technology solutions companies in the country. TA have been providing businesses with cost effective state-of-the-art solutions and unparalleled service that is designed…

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question